Brendan Eich wrote:
Claude Pache wrote:
Fixing `typeof` of old (null) and new value types would be a
solution, but I'm rather definitely considering something like the
defunct `Object.isObject()`
I forgot to add that my patch for
https://bugzilla.mozilla.org/show_bug.cgi?id=749786 includes
Object.isObject(x) // false unless x is an object
Object.isValue(x) // true for primitives and value objects
The idea: isObject returns true for all the new value object types and
the reference-semantics objects found in JS today, while isValue returns
true for all compare-by-value types, whether the legacy primitives
(undefined, null, boolean, number, string) or the new-in-ES7 value objects.
/be
_______________________________________________
es-discuss mailing list
[email protected]
https://mail.mozilla.org/listinfo/es-discuss