Skip to content

"0" and "@" hash value conflicted? #1209

@linfan68

Description

@linfan68

It seems like if I put "@" into an JSON object, it's hash value got conflicted with "0"? Very interesting

from helloworld project:

debugger;

let message = "Hello, world - sample";
const chMap = {
  "0": 48,
  "@": 64,
}
trace(message + "\n\n");
trace('[0] of chMap is :' + chMap['0'].toString() + '\n\n');

trace(chMap['@'].toString() + '\n'); // This crashes

Expected output is :

Hello, world - sample

[0] of chMap is :48

64

But I got

Hello, world - sample

[0] of chMap is :64

XS abort: unhandled exception

Metadata

Metadata

Assignees

No one assigned

    Labels

    fixed - please verifyIssue has been fixed. Please verify and close.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions