Allows the interface to be used as an Identifier for flow plugin (#12254)

This commit is contained in:
Sosuke Suzuki
2020-10-26 22:50:57 +09:00
committed by GitHub
parent a967910b8b
commit f5bd9f2013
27 changed files with 531 additions and 11 deletions

View File

@@ -0,0 +1 @@
interface + 3;

View File

@@ -0,0 +1,39 @@
{
"type": "File",
"start":0,"end":14,"loc":{"start":{"line":1,"column":0},"end":{"line":1,"column":14}},
"errors": [
"SyntaxError: Unexpected reserved word 'interface' (1:0)"
],
"program": {
"type": "Program",
"start":0,"end":14,"loc":{"start":{"line":1,"column":0},"end":{"line":1,"column":14}},
"sourceType": "module",
"interpreter": null,
"body": [
{
"type": "ExpressionStatement",
"start":0,"end":14,"loc":{"start":{"line":1,"column":0},"end":{"line":1,"column":14}},
"expression": {
"type": "BinaryExpression",
"start":0,"end":13,"loc":{"start":{"line":1,"column":0},"end":{"line":1,"column":13}},
"left": {
"type": "Identifier",
"start":0,"end":9,"loc":{"start":{"line":1,"column":0},"end":{"line":1,"column":9},"identifierName":"interface"},
"name": "interface"
},
"operator": "+",
"right": {
"type": "NumericLiteral",
"start":12,"end":13,"loc":{"start":{"line":1,"column":12},"end":{"line":1,"column":13}},
"extra": {
"rawValue": 3,
"raw": "3"
},
"value": 3
}
}
}
],
"directives": []
}
}