(startLoc: Position, expression: N.Expression)
| 1908 | } |
| 1909 | |
| 1910 | wrapParenthesis(startLoc: Position, expression: N.Expression): N.Expression { |
| 1911 | if (!(this.optionFlags & OptionFlags.CreateParenthesizedExpressions)) { |
| 1912 | this.addExtra(expression, "parenthesized", true); |
| 1913 | this.addExtra(expression, "parenStart", startLoc.index); |
| 1914 | |
| 1915 | this.takeSurroundingComments( |
| 1916 | expression, |
| 1917 | startLoc.index, |
| 1918 | this.state.lastTokEndLoc!.index, |
| 1919 | ); |
| 1920 | |
| 1921 | return expression; |
| 1922 | } |
| 1923 | |
| 1924 | const parenExpression = |
| 1925 | this.startNodeAt<N.ParenthesizedExpression>(startLoc); |
| 1926 | parenExpression.expression = expression; |
| 1927 | return this.finishNode(parenExpression, "ParenthesizedExpression"); |
| 1928 | } |
| 1929 | |
| 1930 | // eslint-disable-next-line @typescript-eslint/no-unused-vars -- `params` is used in typescript plugin |
| 1931 | shouldParseArrow(params: N.Node[]): boolean { |
nothing calls this directly
no test coverage detected