typeof symbol (Was: Sept 19 TC39 Meeting Notes)

Axel Rauschmayer axel at rauschma.de
Mon Oct 1 05:50:23 PDT 2012


> However, this clearly is an issue beyond symbols alone. The same
> problem re-arises whenever we have to add new primitive types in the
> future. It doesn't seem like a sustainable strategy to fake any new
> type ever into an object. Perhaps it is less harmful on the long run
> if we took the chance to clarify _now_ that the set of strings
> returned by 'typeof' is not fixed, and should not be treated as such?


It would be great if there was a consistent vision as to where categorization of values should be headed:
What do we need? What is categorization currently used for in practice? How can we achieve it in a future-friendly way? How can we simplify things, long term?

At the moment, things are a mess (between typeof, instanceof, [[Class]], Array.isArray, cross-frame communication, etc.). And I wouldn’t want that mess to get even worse.

ECMAScript.next is shaping up to be a nice and clean language, except for this one area.

-- 
Dr. Axel Rauschmayer
axel at rauschma.de

home: rauschma.de
twitter: twitter.com/rauschma
blog: 2ality.com

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.mozilla.org/pipermail/es-discuss/attachments/20121001/f4144eee/attachment.html>


More information about the es-discuss mailing list