This repository has been archived by the owner on Aug 31, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 659
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
f5b2053
commit 5d3a82c
Showing
1 changed file
with
48 additions
and
47 deletions.
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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -3,39 +3,39 @@ JsModule { | |
directives: JsDirectiveList [], | ||
items: JsModuleItemList [ | ||
JsExpressionStatement { | ||
expression: JsBinaryExpression { | ||
left: JsBinaryExpression { | ||
left: JsNewExpression { | ||
expression: JsCallExpression { | ||
callee: JsStaticMemberExpression { | ||
object: JsNewExpression { | ||
new_token: [email protected] "new" [] [Whitespace(" ")], | ||
callee: JsIdentifierExpression { | ||
name: JsReferenceIdentifier { | ||
value_token: [email protected] "Test" [] [], | ||
}, | ||
}, | ||
type_arguments: missing (optional), | ||
type_arguments: TsTypeArguments { | ||
l_angle_token: [email protected] "<" [] [], | ||
ts_type_argument_list: TsTypeArgumentList [ | ||
TsStringType { | ||
string_token: [email protected] "string" [] [], | ||
}, | ||
], | ||
r_angle_token: [email protected] ">" [] [], | ||
}, | ||
arguments: missing (optional), | ||
}, | ||
operator_token: [email protected] "<" [] [], | ||
right: JsIdentifierExpression { | ||
name: JsReferenceIdentifier { | ||
value_token: [email protected] "string" [] [], | ||
}, | ||
operator_token: [email protected] "?." [] [], | ||
member: JsName { | ||
value_token: [email protected] "test" [] [], | ||
}, | ||
}, | ||
operator_token: [email protected] ">" [] [], | ||
right: missing (required), | ||
optional_chain_token: missing (optional), | ||
type_arguments: missing (optional), | ||
arguments: JsCallArguments { | ||
l_paren_token: [email protected] "(" [] [], | ||
args: JsCallArgumentList [], | ||
r_paren_token: [email protected] ")" [] [], | ||
}, | ||
}, | ||
semicolon_token: missing (optional), | ||
}, | ||
JsUnknownStatement { | ||
items: [ | ||
[email protected] "?." [] [], | ||
[email protected] "test" [] [], | ||
[email protected] "(" [] [], | ||
[email protected] ")" [] [], | ||
], | ||
}, | ||
JsEmptyStatement { | ||
semicolon_token: [email protected] ";" [] [], | ||
}, | ||
JsExpressionStatement { | ||
|
@@ -225,31 +225,32 @@ JsModule { | |
0: (empty) | ||
1: [email protected] | ||
2: [email protected] | ||
0: JS_EXPRESSION_STATEMENT@0..16 | ||
0: JS_BINARY_EXPRESSION@0..16 | ||
0: JS_BINARY_EXPRESSION@0..15 | ||
0: JS_NEW_EXPRESSION@0..8 | ||
0: JS_EXPRESSION_STATEMENT@0..25 | ||
0: JS_CALL_EXPRESSION@0..24 | ||
0: JS_STATIC_MEMBER_EXPRESSION@0..22 | ||
0: JS_NEW_EXPRESSION@0..16 | ||
0: [email protected] "new" [] [Whitespace(" ")] | ||
1: [email protected] | ||
0: [email protected] | ||
0: [email protected] "Test" [] [] | ||
2: (empty) | ||
2: [email protected] | ||
0: [email protected] "<" [] [] | ||
1: [email protected] | ||
0: [email protected] | ||
0: [email protected] "string" [] [] | ||
2: [email protected] ">" [] [] | ||
3: (empty) | ||
1: [email protected] "<" [] [] | ||
2: [email protected] | ||
0: [email protected] | ||
0: [email protected] "string" [] [] | ||
1: [email protected] ">" [] [] | ||
1: [email protected] "?." [] [] | ||
2: [email protected] | ||
0: [email protected] "test" [] [] | ||
1: (empty) | ||
2: (empty) | ||
1: (empty) | ||
1: [email protected] | ||
0: [email protected] "?." [] [] | ||
1: [email protected] "test" [] [] | ||
2: [email protected] "(" [] [] | ||
3: [email protected] ")" [] [] | ||
2: [email protected] | ||
0: [email protected] ";" [] [] | ||
3: [email protected] | ||
3: [email protected] | ||
0: [email protected] "(" [] [] | ||
1: [email protected] | ||
2: [email protected] ")" [] [] | ||
1: [email protected] ";" [] [] | ||
1: [email protected] | ||
0: [email protected] | ||
0: [email protected] | ||
0: [email protected] | ||
|
@@ -269,7 +270,7 @@ JsModule { | |
1: [email protected] | ||
2: [email protected] ")" [] [] | ||
1: [email protected] ";" [] [] | ||
4: [email protected] | ||
2: [email protected] | ||
0: [email protected] | ||
0: [email protected] | ||
0: [email protected] | ||
|
@@ -293,7 +294,7 @@ JsModule { | |
1: [email protected] | ||
2: [email protected] ")" [] [] | ||
1: (empty) | ||
5: [email protected] | ||
3: [email protected] | ||
0: [email protected] | ||
0: [email protected] | ||
0: [email protected] | ||
|
@@ -320,7 +321,7 @@ JsModule { | |
1: [email protected] | ||
2: [email protected] ")" [] [] | ||
1: (empty) | ||
6: [email protected] | ||
4: [email protected] | ||
0: [email protected] | ||
0: [email protected] "new" [Newline("\n")] [Whitespace(" ")] | ||
1: [email protected] | ||
|
@@ -350,7 +351,7 @@ JsModule { | |
1: [email protected] | ||
2: [email protected] ")" [] [] | ||
1: (empty) | ||
7: [email protected] | ||
5: [email protected] | ||
0: [email protected] | ||
0: [email protected] | ||
0: [email protected] | ||
|
@@ -379,11 +380,11 @@ JsModule { | |
1: (empty) | ||
3: [email protected] "" [Newline("\n")] [] | ||
-- | ||
error[SyntaxError]: expected an expression but instead found '?.' | ||
error[SyntaxError]: Invalid optional chain from new expression. | ||
┌─ invalid_optional_chain_from_new_expressions.ts:1:17 | ||
│ | ||
1 │ new Test<string>?.test(); | ||
│ ^^ Expected an expression here | ||
│ ^^ | ||
|
||
-- | ||
error[SyntaxError]: Invalid optional chain from new expression. | ||
|