allowing 'debugger' ... it should never have been a reserved word.

This commit is contained in:
Jeremy Ashkenas 2010-04-12 21:23:01 -04:00
parent 92540d5e85
commit 4ced1d65b4
2 changed files with 2 additions and 2 deletions

View File

@ -621,7 +621,7 @@
// The list of keywords that are reserved by JavaScript, but not used, or are // The list of keywords that are reserved by JavaScript, but not used, or are
// used by CoffeeScript internally. We throw an error when these are encountered, // used by CoffeeScript internally. We throw an error when these are encountered,
// to avoid having a JavaScript error at runtime. // to avoid having a JavaScript error at runtime.
RESERVED = ["case", "default", "do", "function", "var", "void", "with", "const", "let", "debugger", "enum", "export", "import", "native"]; RESERVED = ["case", "default", "do", "function", "var", "void", "with", "const", "let", "enum", "export", "import", "native"];
// The superset of both JavaScript keywords and reserved words, none of which may // The superset of both JavaScript keywords and reserved words, none of which may
// be used as identifiers or properties. // be used as identifiers or properties.
JS_FORBIDDEN = JS_KEYWORDS.concat(RESERVED); JS_FORBIDDEN = JS_KEYWORDS.concat(RESERVED);

View File

@ -467,7 +467,7 @@ KEYWORDS: JS_KEYWORDS.concat COFFEE_KEYWORDS
# to avoid having a JavaScript error at runtime. # to avoid having a JavaScript error at runtime.
RESERVED: [ RESERVED: [
"case", "default", "do", "function", "var", "void", "with" "case", "default", "do", "function", "var", "void", "with"
"const", "let", "debugger", "enum", "export", "import", "native" "const", "let", "enum", "export", "import", "native"
] ]
# The superset of both JavaScript keywords and reserved words, none of which may # The superset of both JavaScript keywords and reserved words, none of which may