On Fri, Jan 8, 2016 at 9:45 AM, Alexander Jones wrote:
> const symbol mySym;
> const mySym = Symbol("mySym");
>
Nice, I like that one.
___
es-discuss mailing list
es-discuss@mozilla.org
https://mail.mozilla.org/listinfo/es-discuss
I love how ES6 automatically gives anonymous function definitions names (via
the variables they are assigned to etc.). Wouldn’t the same make sense for
symbols?
Hypothetical example:
```js
const foo = Symbol();
console.log(Symbol('foo').toString()); // Symbol(foo)
```
--
Dr. Axel Rauschmayer
Yup. Consider
const foo = x();
where x happens to have the original value of Symbol.
Or
const foo = Symbol()
where Symbol is not bound to the original value of Symbol.
On Wed, Jan 6, 2016 at 4:44 PM, Jordan Harband wrote:
> One difference is that functions are syntax
3 matches
Mail list logo