I would add that in node.js it returns neither undefined nor window, but a timer object, which you can clear up with `clearInterval(this)` inside the callback.
 
 
07.09.2014, 21:30, "Andrea Giammarchi" <[email protected]>:
I know this is probably W3C land but the following code shows the global object in every JS engine I could test:
 
```js
(function () {
  'use strict';
  setTimeout(function () {
    'use strict';
    console.log(this);
    // [window/global Object]
  }, 0);
}());
```
 
This looks like a potential problem when possible passed methods are not bound + it looks inconsistent with *"use strict"* expectations.
 
Thoughts ?
 
Best Regards
,

_______________________________________________
es-discuss mailing list
[email protected]
https://mail.mozilla.org/listinfo/es-discuss

_______________________________________________
es-discuss mailing list
[email protected]
https://mail.mozilla.org/listinfo/es-discuss

Reply via email to