WARNING: This server is unstable and will be retired in the next days. If you want to keep this forum available, please request immediately a migration on the Nabble Support forum. Forums that don't receive any migration request will be deleted forever.

 « Return to Thread: typeof null

Re: typeof null

by Rick Waldron :: Rate this Message:

| View in Thread



On Tue, May 8, 2012 at 12:52 PM, Herby Vojčík <herby@...> wrote:


Wes Garland wrote:
It looks to me like this code would work just fine by removing the word
'typeof'. What am I missing?

Cross-frame/cross-context, too?

I guess this answers my question, because if code can get from one frame to another, wherein the first has opted in, but the second has not, then there is breakage.

Thanks

Rick


 

On 8 May 2012 12:19, Rick Waldron <waldron.rick@...
<mailto:waldron.rick@...>> wrote:


   module Foo {
      export function create( options ) {

        if ( typeof options === "null" ) {
          return ... some default thing;
        }
      };
   }

   import create from Foo;

   let default = create( null );

--
Wesley W. Garland
Director, Product Development
PageMail, Inc.
+1 613 542 2787 x 102

Herby


_______________________________________________
es-discuss mailing list
es-discuss@...
https://mail.mozilla.org/listinfo/es-discuss

 « Return to Thread: typeof null