Jeremy Martin (2013-07-15T15:01:01.000Z)
> s === Object(s)

This should throw a TypeError.  In the case of a Symbol, `Object(*value*)`
results in `ToObject(*value*)` [1].  And, in the case of Symbol, ToObject
should throw a TypeError [2].

[1] http://people.mozilla.org/~jorendorff/es6-draft.html#sec-15.2.1.1
[2] http://people.mozilla.org/~jorendorff/es6-draft.html#sec-9.1.9

On Mon, Jul 15, 2013 at 10:48 AM, Mark S. Miller <erights at google.com> wrote:

> Given that s is a Symbol and b is a Bignum, is
>
>     s === Object(s)
>
> ?
>
> Is
>
>     b === Object(b)
>
> ?
>
> The reason I ask is that x === Object(x) is often used to distinguish
> primitive values from objects. The other thing that's often used is typeof,
> but these uses of typeof usually assume that the full range of possible
> answers is already known. If we're going to be expanding the typeof
> answers, then we need guidance on how to write this test now (es5) such
> that it stays robust.
>
>
> --
>     Cheers,
>     --MarkM
>
> _______________________________________________
> es-discuss mailing list
> es-discuss at mozilla.org
> https://mail.mozilla.org/listinfo/es-discuss
>
>


-- 
Jeremy Martin
661.312.3853
http://devsmash.com
@jmar777
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.mozilla.org/pipermail/es-discuss/attachments/20130715/3e5e16fc/attachment.html>
domenic at domenicdenicola.com (2013-07-23T16:52:20.341Z)
> s === Object(s)

This should throw a TypeError.  In the case of a Symbol, `Object(*value*)`
results in `ToObject(*value*)` [1].  And, in the case of Symbol, ToObject
should throw a TypeError [2].

[1]: http://people.mozilla.org/~jorendorff/es6-draft.html#sec-15.2.1.1
[2]: http://people.mozilla.org/~jorendorff/es6-draft.html#sec-9.1.9