-
-
Notifications
You must be signed in to change notification settings - Fork 5.6k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
parser: Support percentage topic with v8intrinsics
- Loading branch information
Showing
32 changed files
with
510 additions
and
33 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
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
1 change: 1 addition & 0 deletions
1
...fixtures/experimental/pipeline-operator/hack-hash-proposal-v8intrinsic-with-hash/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 @@ | ||
input |> %GetOptimizationStatus(#); |
6 changes: 6 additions & 0 deletions
6
...ures/experimental/pipeline-operator/hack-hash-proposal-v8intrinsic-with-hash/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,6 @@ | ||
{ | ||
"plugins": [ | ||
["pipelineOperator", { "proposal": "hack", "topicToken": "#" }], | ||
"v8intrinsic" | ||
] | ||
} |
42 changes: 42 additions & 0 deletions
42
...tures/experimental/pipeline-operator/hack-hash-proposal-v8intrinsic-with-hash/output.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,42 @@ | ||
{ | ||
"type": "File", | ||
"start":0,"end":35,"loc":{"start":{"line":1,"column":0},"end":{"line":1,"column":35}}, | ||
"program": { | ||
"type": "Program", | ||
"start":0,"end":35,"loc":{"start":{"line":1,"column":0},"end":{"line":1,"column":35}}, | ||
"sourceType": "script", | ||
"interpreter": null, | ||
"body": [ | ||
{ | ||
"type": "ExpressionStatement", | ||
"start":0,"end":35,"loc":{"start":{"line":1,"column":0},"end":{"line":1,"column":35}}, | ||
"expression": { | ||
"type": "BinaryExpression", | ||
"start":0,"end":34,"loc":{"start":{"line":1,"column":0},"end":{"line":1,"column":34}}, | ||
"left": { | ||
"type": "Identifier", | ||
"start":0,"end":5,"loc":{"start":{"line":1,"column":0},"end":{"line":1,"column":5},"identifierName":"input"}, | ||
"name": "input" | ||
}, | ||
"operator": "|>", | ||
"right": { | ||
"type": "CallExpression", | ||
"start":9,"end":34,"loc":{"start":{"line":1,"column":9},"end":{"line":1,"column":34}}, | ||
"callee": { | ||
"type": "V8IntrinsicIdentifier", | ||
"start":9,"end":31,"loc":{"start":{"line":1,"column":9},"end":{"line":1,"column":31},"identifierName":"GetOptimizationStatus"}, | ||
"name": "GetOptimizationStatus" | ||
}, | ||
"arguments": [ | ||
{ | ||
"type": "TopicReference", | ||
"start":32,"end":33,"loc":{"start":{"line":1,"column":32},"end":{"line":1,"column":33}} | ||
} | ||
] | ||
} | ||
} | ||
} | ||
], | ||
"directives": [] | ||
} | ||
} |
1 change: 1 addition & 0 deletions
1
...tures/experimental/pipeline-operator/hack-hash-proposal-v8intrinsic-with-percent/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 @@ | ||
input |> %GetOptimizationStatus(%); |
7 changes: 7 additions & 0 deletions
7
...s/experimental/pipeline-operator/hack-hash-proposal-v8intrinsic-with-percent/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,7 @@ | ||
{ | ||
"plugins": [ | ||
["pipelineOperator", { "proposal": "hack", "topicToken": "#" }], | ||
"v8intrinsic" | ||
], | ||
"throws": "Invalid topic token %. In order to use % as a topic reference, the pipelineOperator plugin must be configured with { \"proposal\": \"hack\", \"topicToken\": \"%\" }. (1:32)" | ||
} |
1 change: 1 addition & 0 deletions
1
...ures/experimental/pipeline-operator/hack-hash-proposal-v8intrinsic-without-topic/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 @@ | ||
input |> %GetOptimizationStatus(f); |
6 changes: 6 additions & 0 deletions
6
.../experimental/pipeline-operator/hack-hash-proposal-v8intrinsic-without-topic/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,6 @@ | ||
{ | ||
"plugins": [ | ||
["pipelineOperator", { "proposal": "hack", "topicToken": "%" }], | ||
"v8intrinsic" | ||
] | ||
} |
46 changes: 46 additions & 0 deletions
46
...s/experimental/pipeline-operator/hack-hash-proposal-v8intrinsic-without-topic/output.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,46 @@ | ||
{ | ||
"type": "File", | ||
"start":0,"end":35,"loc":{"start":{"line":1,"column":0},"end":{"line":1,"column":35}}, | ||
"errors": [ | ||
"SyntaxError: Hack-style pipe body does not contain a topic reference; Hack-style pipes must use topic at least once. (1:9)" | ||
], | ||
"program": { | ||
"type": "Program", | ||
"start":0,"end":35,"loc":{"start":{"line":1,"column":0},"end":{"line":1,"column":35}}, | ||
"sourceType": "script", | ||
"interpreter": null, | ||
"body": [ | ||
{ | ||
"type": "ExpressionStatement", | ||
"start":0,"end":35,"loc":{"start":{"line":1,"column":0},"end":{"line":1,"column":35}}, | ||
"expression": { | ||
"type": "BinaryExpression", | ||
"start":0,"end":34,"loc":{"start":{"line":1,"column":0},"end":{"line":1,"column":34}}, | ||
"left": { | ||
"type": "Identifier", | ||
"start":0,"end":5,"loc":{"start":{"line":1,"column":0},"end":{"line":1,"column":5},"identifierName":"input"}, | ||
"name": "input" | ||
}, | ||
"operator": "|>", | ||
"right": { | ||
"type": "CallExpression", | ||
"start":9,"end":34,"loc":{"start":{"line":1,"column":9},"end":{"line":1,"column":34}}, | ||
"callee": { | ||
"type": "V8IntrinsicIdentifier", | ||
"start":9,"end":31,"loc":{"start":{"line":1,"column":9},"end":{"line":1,"column":31},"identifierName":"GetOptimizationStatus"}, | ||
"name": "GetOptimizationStatus" | ||
}, | ||
"arguments": [ | ||
{ | ||
"type": "Identifier", | ||
"start":32,"end":33,"loc":{"start":{"line":1,"column":32},"end":{"line":1,"column":33},"identifierName":"f"}, | ||
"name": "f" | ||
} | ||
] | ||
} | ||
} | ||
} | ||
], | ||
"directives": [] | ||
} | ||
} |
1 change: 1 addition & 0 deletions
1
...es/experimental/pipeline-operator/hack-percent-proposal-v8intrinsic-outside-pipe/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 @@ | ||
%GetOptimizationStatus(f); |
6 changes: 6 additions & 0 deletions
6
...xperimental/pipeline-operator/hack-percent-proposal-v8intrinsic-outside-pipe/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,6 @@ | ||
{ | ||
"plugins": [ | ||
["pipelineOperator", { "proposal": "hack", "topicToken": "%" }], | ||
"v8intrinsic" | ||
] | ||
} |
33 changes: 33 additions & 0 deletions
33
...experimental/pipeline-operator/hack-percent-proposal-v8intrinsic-outside-pipe/output.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,33 @@ | ||
{ | ||
"type": "File", | ||
"start":0,"end":26,"loc":{"start":{"line":1,"column":0},"end":{"line":1,"column":26}}, | ||
"program": { | ||
"type": "Program", | ||
"start":0,"end":26,"loc":{"start":{"line":1,"column":0},"end":{"line":1,"column":26}}, | ||
"sourceType": "script", | ||
"interpreter": null, | ||
"body": [ | ||
{ | ||
"type": "ExpressionStatement", | ||
"start":0,"end":26,"loc":{"start":{"line":1,"column":0},"end":{"line":1,"column":26}}, | ||
"expression": { | ||
"type": "CallExpression", | ||
"start":0,"end":25,"loc":{"start":{"line":1,"column":0},"end":{"line":1,"column":25}}, | ||
"callee": { | ||
"type": "V8IntrinsicIdentifier", | ||
"start":0,"end":22,"loc":{"start":{"line":1,"column":0},"end":{"line":1,"column":22},"identifierName":"GetOptimizationStatus"}, | ||
"name": "GetOptimizationStatus" | ||
}, | ||
"arguments": [ | ||
{ | ||
"type": "Identifier", | ||
"start":23,"end":24,"loc":{"start":{"line":1,"column":23},"end":{"line":1,"column":24},"identifierName":"f"}, | ||
"name": "f" | ||
} | ||
] | ||
} | ||
} | ||
], | ||
"directives": [] | ||
} | ||
} |
1 change: 1 addition & 0 deletions
1
...tures/experimental/pipeline-operator/hack-percent-proposal-v8intrinsic-with-hash/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 @@ | ||
input |> %GetOptimizationStatus(#); |
7 changes: 7 additions & 0 deletions
7
...s/experimental/pipeline-operator/hack-percent-proposal-v8intrinsic-with-hash/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,7 @@ | ||
{ | ||
"plugins": [ | ||
["pipelineOperator", { "proposal": "hack", "topicToken": "%" }], | ||
"v8intrinsic" | ||
], | ||
"throws": "Invalid topic token #. In order to use # as a topic reference, the pipelineOperator plugin must be configured with { \"proposal\": \"hack\", \"topicToken\": \"#\" }. (1:32)" | ||
} |
1 change: 1 addition & 0 deletions
1
...es/experimental/pipeline-operator/hack-percent-proposal-v8intrinsic-with-percent/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 @@ | ||
input |> %GetOptimizationStatus(%); |
6 changes: 6 additions & 0 deletions
6
...xperimental/pipeline-operator/hack-percent-proposal-v8intrinsic-with-percent/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,6 @@ | ||
{ | ||
"plugins": [ | ||
["pipelineOperator", { "proposal": "hack", "topicToken": "%" }], | ||
"v8intrinsic" | ||
] | ||
} |
Oops, something went wrong.