You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This is sort of a child issue to #1367, but, because it's a bug, it seems worth it to track separately since it might be fixed independently from the more generic one.
While looking into #1087, I realised that #1367 is needed not only for prototype-less Objects and cross-realm interaction, but also for new primitives which don't have automatic boxing.
Currently these are:
Symbol
BigInt
and for both instanceof check will return false when used on a corresponding primitive, because they're not objects, and so dyn_ref and dyn_into fail to recognise them too.
>require('./pkg').symbol_to_string_1(Symbol('x'))'Symbol(x)'>require('./pkg').symbol_to_string_2(Symbol('x'))panickedat'called `Result::unwrap()` on an `Err` value: JsValue(Symbol(x))',src/libcore/result.rs:997:5>require('./pkg').symbol_to_string_3(Symbol('x'))'Symbol(x)'
The text was updated successfully, but these errors were encountered:
This is sort of a child issue to #1367, but, because it's a bug, it seems worth it to track separately since it might be fixed independently from the more generic one.
While looking into #1087, I realised that #1367 is needed not only for prototype-less
Object
s and cross-realm interaction, but also for new primitives which don't have automatic boxing.Currently these are:
Symbol
BigInt
and for both
instanceof
check will return false when used on a corresponding primitive, because they're not objects, and sodyn_ref
anddyn_into
fail to recognise them too.Example:
Results:
The text was updated successfully, but these errors were encountered: