Skip to content

Commit fde8699

Browse files
committed
Make '( and '{ tokens that can start an expression
Fixes a bug in parsing quotes.
1 parent 9d95115 commit fde8699

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

compiler/src/dotty/tools/dotc/parsing/Tokens.scala

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -211,7 +211,7 @@ object Tokens extends TokensCommon {
211211
USCORE, NULL, THIS, SUPER, TRUE, FALSE, RETURN, XMLSTART)
212212

213213
final val canStartExpressionTokens = atomicExprTokens | BitSet(
214-
LBRACE, LPAREN, IF, DO, WHILE, FOR, NEW, TRY, THROW)
214+
LBRACE, LPAREN, QBRACE, QPAREN, IF, DO, WHILE, FOR, NEW, TRY, THROW)
215215

216216
final val canStartTypeTokens = literalTokens | identifierTokens | BitSet(
217217
THIS, SUPER, USCORE, LPAREN, AT)

0 commit comments

Comments
 (0)