typeof symbol (Was: Sept 19 TC39 Meeting Notes)

Andreas Rossberg rossberg at google.com
Mon Oct 1 02:56:27 PDT 2012

On 29 September 2012 20:14, Rick Waldron <waldron.rick at gmail.com> wrote:
> Offline discussion with Dave that immediately identified a deal-breaker: if
> typeof symbol were "string", it would break ===.
> === for strings is based on their contents
> === for objects is based on their identity

Well, that's clearly up to interpretation. Instead of having
"identity", you can just as well view symbols as something with unique
abstract "content". That is, I disagree that this alone is a
deal-breaker of any kind.

But nevertheless, of course, using typeof symbol === "string" would be
bad for other reasons, some of which have been brought up in this


More information about the es-discuss mailing list