Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use Map object properly #23

Merged
merged 12 commits into from
Nov 15, 2017
Merged

Use Map object properly #23

merged 12 commits into from
Nov 15, 2017

Conversation

tiagoschenkel
Copy link
Member

The bracket notation in JavaScript have a different behavior than the one expected in Action Script 3:

JS evaluates the first complete expression with square brackets in a statement, runs toString() on it to convert it into a string and then uses that value for the next bracket expression, on down the line till it runs out of bracket expressions.

Reference: JS dot-notation vs. bracket notation

To avoid problems with the collision of keys, a Map object must be manipulated using all available methods provided by the official implementation instead.

See Map.

@tiagoschenkel tiagoschenkel self-assigned this Nov 15, 2017
@tiagoschenkel tiagoschenkel merged commit 485e4a4 into master Nov 15, 2017
@tiagoschenkel tiagoschenkel deleted the map branch November 15, 2017 01:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant