File tree Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -172,19 +172,19 @@ static bool scan_ternary_qmark(TSLexer *lexer) {
172
172
/* Optional chaining. */
173
173
if (lexer -> lookahead == '.' ) return false;
174
174
175
+ lexer -> mark_end (lexer );
176
+ lexer -> result_symbol = TERNARY_QMARK ;
177
+
175
178
/* TypeScript optional arguments contain the ?: sequence, possibly
176
179
with whitespace. */
177
180
for (;;) {
178
181
if (!iswspace (lexer -> lookahead )) break ;
179
- skip (lexer );
182
+ advance (lexer );
180
183
}
181
184
if (lexer -> lookahead == ':' ) return false;
182
185
if (lexer -> lookahead == ')' ) return false;
183
186
if (lexer -> lookahead == ',' ) return false;
184
187
185
- lexer -> mark_end (lexer );
186
- lexer -> result_symbol = TERNARY_QMARK ;
187
-
188
188
if (lexer -> lookahead == '.' ) {
189
189
advance (lexer );
190
190
if (iswdigit (lexer -> lookahead )) return true;
You can’t perform that action at this time.
0 commit comments