Skip to content

Commit 38c4ce7

Browse files
smarterallanrenucci
authored andcommitted
Fix position of parsed applications
The end position was correctly set but the start position was wrong: the start position of `fn(args)` should be the same as the start position of `fn` itself.
1 parent 9c8ed0b commit 38c4ce7

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

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

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1533,7 +1533,7 @@ object Parsers {
15331533
}
15341534
if (in.token == LPAREN && (!inClassConstrAnnots || isLegalAnnotArg))
15351535
parArgumentExprss(
1536-
atPos(in.offset) { Apply(fn, parArgumentExprs()) }
1536+
atPos(startOffset(fn)) { Apply(fn, parArgumentExprs()) }
15371537
)
15381538
else fn
15391539
}

0 commit comments

Comments
 (0)