Skip to content

Commit

Permalink
polish: update error message
Browse files Browse the repository at this point in the history
  • Loading branch information
JLHwung committed Oct 6, 2020
1 parent 112b919 commit 51ff2e7
Show file tree
Hide file tree
Showing 5 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion packages/babel-parser/src/parser/error-message.js
Expand Up @@ -5,7 +5,7 @@
export const ErrorMessages = Object.freeze({
AccessorIsGenerator: "A %0ter cannot be a generator",
ArgumentsInClass:
"'arguments' is not allowed in class field initializer or static block",
"'arguments' is only allowed in functions and class methods",
AsyncFunctionInSingleStatementContext:
"Async functions can only be declared at the top level or inside a block",
AwaitBindingIdentifier:
Expand Down
Expand Up @@ -2,7 +2,7 @@
"type": "File",
"start":0,"end":60,"loc":{"start":{"line":1,"column":0},"end":{"line":5,"column":1}},
"errors": [
"SyntaxError: 'arguments' is not allowed in class field initializer or static block (3:16)"
"SyntaxError: 'arguments' is only allowed in functions and class methods (3:16)"
],
"program": {
"type": "Program",
Expand Down
Expand Up @@ -2,7 +2,7 @@
"type": "File",
"start":0,"end":76,"loc":{"start":{"line":1,"column":0},"end":{"line":5,"column":1}},
"errors": [
"SyntaxError: 'arguments' is not allowed in class field initializer or static block (3:25)"
"SyntaxError: 'arguments' is only allowed in functions and class methods (3:25)"
],
"program": {
"type": "Program",
Expand Down
Expand Up @@ -2,7 +2,7 @@
"type": "File",
"start":0,"end":54,"loc":{"start":{"line":1,"column":0},"end":{"line":5,"column":1}},
"errors": [
"SyntaxError: 'arguments' is not allowed in class field initializer or static block (3:10)"
"SyntaxError: 'arguments' is only allowed in functions and class methods (3:10)"
],
"program": {
"type": "Program",
Expand Down
Expand Up @@ -2,7 +2,7 @@
"type": "File",
"start":0,"end":52,"loc":{"start":{"line":1,"column":0},"end":{"line":5,"column":1}},
"errors": [
"SyntaxError: 'arguments' is not allowed in class field initializer or static block (3:15)"
"SyntaxError: 'arguments' is only allowed in functions and class methods (3:15)"
],
"program": {
"type": "Program",
Expand Down

0 comments on commit 51ff2e7

Please sign in to comment.