Default function arguments not using current scope

Cyril Auburtin cyril.auburtin at gmail.com
Thu Apr 5 08:29:46 UTC 2018


I don't understand:

```js

var z=1; var fn = (z = z) => z; fn() // throws ReferenceError: z is not
defined
```
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.mozilla.org/pipermail/es-discuss/attachments/20180405/445216f8/attachment.html>


More information about the es-discuss mailing list