Include typeParameter location in the arrow function expression (#126)
This commit is contained in:
parent
643d3f37a4
commit
f91da191a1
@ -1162,6 +1162,8 @@ export default function (instance) {
|
||||
|
||||
arrowExpression = inner.apply(this, args);
|
||||
arrowExpression.typeParameters = typeParameters;
|
||||
arrowExpression.start = typeParameters.start;
|
||||
arrowExpression.loc.start = typeParameters.loc.start;
|
||||
} catch (err) {
|
||||
throw jsxError || err;
|
||||
}
|
||||
|
||||
@ -44,12 +44,12 @@
|
||||
},
|
||||
"expression": {
|
||||
"type": "ArrowFunctionExpression",
|
||||
"start": 3,
|
||||
"start": 0,
|
||||
"end": 12,
|
||||
"loc": {
|
||||
"start": {
|
||||
"line": 1,
|
||||
"column": 3
|
||||
"column": 0
|
||||
},
|
||||
"end": {
|
||||
"line": 1,
|
||||
@ -132,12 +132,12 @@
|
||||
},
|
||||
"expression": {
|
||||
"type": "ArrowFunctionExpression",
|
||||
"start": 17,
|
||||
"start": 14,
|
||||
"end": 27,
|
||||
"loc": {
|
||||
"start": {
|
||||
"line": 2,
|
||||
"column": 3
|
||||
"column": 0
|
||||
},
|
||||
"end": {
|
||||
"line": 2,
|
||||
@ -237,12 +237,12 @@
|
||||
},
|
||||
"expression": {
|
||||
"type": "ArrowFunctionExpression",
|
||||
"start": 32,
|
||||
"start": 29,
|
||||
"end": 50,
|
||||
"loc": {
|
||||
"start": {
|
||||
"line": 3,
|
||||
"column": 3
|
||||
"column": 0
|
||||
},
|
||||
"end": {
|
||||
"line": 3,
|
||||
@ -372,12 +372,12 @@
|
||||
},
|
||||
"expression": {
|
||||
"type": "ArrowFunctionExpression",
|
||||
"start": 55,
|
||||
"start": 52,
|
||||
"end": 77,
|
||||
"loc": {
|
||||
"start": {
|
||||
"line": 4,
|
||||
"column": 3
|
||||
"column": 0
|
||||
},
|
||||
"end": {
|
||||
"line": 4,
|
||||
@ -527,4 +527,4 @@
|
||||
],
|
||||
"directives": []
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@ -44,12 +44,12 @@
|
||||
},
|
||||
"expression": {
|
||||
"type": "ArrowFunctionExpression",
|
||||
"start": 3,
|
||||
"start": 0,
|
||||
"end": 12,
|
||||
"loc": {
|
||||
"start": {
|
||||
"line": 1,
|
||||
"column": 3
|
||||
"column": 0
|
||||
},
|
||||
"end": {
|
||||
"line": 1,
|
||||
@ -132,12 +132,12 @@
|
||||
},
|
||||
"expression": {
|
||||
"type": "ArrowFunctionExpression",
|
||||
"start": 17,
|
||||
"start": 14,
|
||||
"end": 27,
|
||||
"loc": {
|
||||
"start": {
|
||||
"line": 2,
|
||||
"column": 3
|
||||
"column": 0
|
||||
},
|
||||
"end": {
|
||||
"line": 2,
|
||||
@ -237,12 +237,12 @@
|
||||
},
|
||||
"expression": {
|
||||
"type": "ArrowFunctionExpression",
|
||||
"start": 32,
|
||||
"start": 29,
|
||||
"end": 50,
|
||||
"loc": {
|
||||
"start": {
|
||||
"line": 3,
|
||||
"column": 3
|
||||
"column": 0
|
||||
},
|
||||
"end": {
|
||||
"line": 3,
|
||||
@ -372,12 +372,12 @@
|
||||
},
|
||||
"expression": {
|
||||
"type": "ArrowFunctionExpression",
|
||||
"start": 55,
|
||||
"start": 52,
|
||||
"end": 77,
|
||||
"loc": {
|
||||
"start": {
|
||||
"line": 4,
|
||||
"column": 3
|
||||
"column": 0
|
||||
},
|
||||
"end": {
|
||||
"line": 4,
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user