Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fixed missing errors on assignment pattern in object expression (#10607)
* 馃悰 fixed missing errors on assignment pattern in object expression * 鈾伙笍 remove a non-needed comment * 馃悰 missed adding comma in the test input * 馃悰 fixed the failing valid-property-initializer test
- Loading branch information
1 parent
198b4a0
commit 4b3a19e
Showing
7 changed files
with
447 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
4 changes: 4 additions & 0 deletions
4
packages/babel-parser/test/fixtures/core/object/invalid-property-initializer-1/input.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
const obj = { | ||
bar: x = 123, | ||
foo = 123 | ||
}; |
3 changes: 3 additions & 0 deletions
3
packages/babel-parser/test/fixtures/core/object/invalid-property-initializer-1/options.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
{ | ||
"throws": "Unexpected token (3:6)" | ||
} |
4 changes: 4 additions & 0 deletions
4
packages/babel-parser/test/fixtures/core/object/invalid-property-initializer/input.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
const obj = { | ||
foo = 123, | ||
bar: x = 123 | ||
}; |
3 changes: 3 additions & 0 deletions
3
packages/babel-parser/test/fixtures/core/object/invalid-property-initializer/options.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
{ | ||
"throws": "Unexpected token (2:6)" | ||
} |
4 changes: 4 additions & 0 deletions
4
packages/babel-parser/test/fixtures/core/object/valid-property-initializer/input.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
const obj = { | ||
foo = 123, | ||
bar: x = 123, | ||
} = { foo: 24, bar: 45 }; |
Oops, something went wrong.