You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: compiler/src/dotty/tools/dotc/transform/InstrumentCoverage.scala
+3-1
Original file line number
Diff line number
Diff line change
@@ -97,7 +97,9 @@ class InstrumentCoverage extends MacroTransform with IdentityDenotTransformer:
97
97
id = id,
98
98
start = pos.start,
99
99
end = pos.end,
100
-
line = pos.line,
100
+
// +1 to account for the line number starting at 1
101
+
// the internal line number is 0-base https://github.com/lampepfl/dotty/blob/18ada516a85532524a39a962b2ddecb243c65376/compiler/src/dotty/tools/dotc/util/SourceFile.scala#L173-L176
0 commit comments