8149929: Nashorn Parser API needs to be updated for ES6
Reviewed-by: mhaupt, hannesw
[
{
"endPosition": "46",
"kind": "FUNCTION",
"name": {
"endPosition": "14",
"kind": "IDENTIFIER",
"name": "func",
"startPosition": "10"
},
"body": {
"endPosition": "44",
"kind": "BLOCK",
"statements": [
{
"expression": {
"leftOperand": {
"endPosition": "39",
"kind": "IDENTIFIER",
"name": "x",
"startPosition": "38"
},
"endPosition": "43",
"kind": "PLUS",
"rightOperand": {
"endPosition": "43",
"kind": "IDENTIFIER",
"name": "y",
"startPosition": "42"
},
"startPosition": "38"
},
"endPosition": "44",
"kind": "RETURN",
"startPosition": "31"
}
],
"startPosition": "25"
},
"strict": "false",
"startPosition": "1",
"parameters": [
{
"expression": {
"endPosition": "20",
"kind": "NUMBER_LITERAL",
"value": "3",
"startPosition": "19"
},
"endPosition": "20",
"kind": "ASSIGNMENT",
"variable": {
"endPosition": "16",
"kind": "IDENTIFIER",
"name": "x",
"startPosition": "15"
},
"startPosition": "15"
},
{
"endPosition": "23",
"kind": "IDENTIFIER",
"name": "y",
"startPosition": "22"
}
]
},
{
"endPosition": "96",
"kind": "VARIABLE",
"binding": {
"endPosition": "53",
"kind": "IDENTIFIER",
"name": "f",
"startPosition": "52"
},
"startPosition": "48",
"initializer": {
"endPosition": "80",
"kind": "FUNCTION_EXPRESSION",
"name": "null",
"body": {
"endPosition": "94",
"kind": "BLOCK",
"statements": [
{
"expression": {
"leftOperand": {
"endPosition": "90",
"kind": "IDENTIFIER",
"name": "x",
"startPosition": "89"
},
"endPosition": "94",
"kind": "MULTIPLY",
"rightOperand": {
"endPosition": "94",
"kind": "IDENTIFIER",
"name": "y",
"startPosition": "93"
},
"startPosition": "89"
},
"endPosition": "94",
"kind": "RETURN",
"startPosition": "82"
}
],
"startPosition": "80"
},
"strict": "false",
"startPosition": "80",
"parameters": [
{
"expression": {
"endPosition": "71",
"kind": "NUMBER_LITERAL",
"value": "4",
"startPosition": "70"
},
"endPosition": "71",
"kind": "ASSIGNMENT",
"variable": {
"endPosition": "67",
"kind": "IDENTIFIER",
"name": "x",
"startPosition": "66"
},
"startPosition": "66"
},
{
"expression": {
"endPosition": "78",
"kind": "NUMBER_LITERAL",
"value": "5",
"startPosition": "77"
},
"endPosition": "78",
"kind": "ASSIGNMENT",
"variable": {
"endPosition": "74",
"kind": "IDENTIFIER",
"name": "y",
"startPosition": "73"
},
"startPosition": "73"
}
]
}
}
]