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

Error in Appendix A - Smaller Changes - Unicode code point escapes #457

Open
ronen-e opened this issue Oct 28, 2020 · 0 comments
Open

Error in Appendix A - Smaller Changes - Unicode code point escapes #457

ronen-e opened this issue Oct 28, 2020 · 0 comments

Comments

@ronen-e
Copy link
Contributor

ronen-e commented Oct 28, 2020

Where:
Line 91 in Appendix A - Other changes

// Valid in ECMAScript 5 and 6
var \u{61} = "abc";

console.log(\u{61});      // "abc"

// equivalent to:
 console.log(a);          // "abc"

Reason:
the text "Valid in ECMAScript 5 and 6" is incorrect
Code point escapes were added to JavaScript in ECMAScript 2015 (ES6).
The example is not valid for ES5

Suggested Fix:

// Valid in ECMAScript 6
var \u{61} = "abc";

console.log(\u{61});      // "abc"

// equivalent to:
 console.log(a);          // "abc"
@ronen-e ronen-e changed the title Error in Appendix A - Other changes - Unicode code point escapes Error in Appendix A - Smaller Changes - Unicode code point escapes Oct 28, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant