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
In BSP, Bloop reports the following range position for the diagnostic
a/src/main/scala/A.scala:2:33:error: typemismatch;
found : Stringrequired: Int"".lengthCompare("1".substring(0))
^^^
I expected the range position to be the following
a/src/main/scala/A.scala:2:33:error: typemismatch;
found : Stringrequired: Int"".lengthCompare("1".substring(0))
^^^^^^^^^^^^^^^^
It looks like the start offset is using the Position.point offset from the compiler instead of Position.start. Here is how the error looks from scalac in the terminal with -Yrangepos enabled
err.scala:2:error: typemismatch;
found : Stringrequired: Intdefa="".lengthCompare("1".substring(1))
^
one error found
In mdoc, we use Position.{start,end} from the compiler diagnostics and the errors are published as expected.
info:Compiling1 file to /Users/olafurpg/dev/metals/target/out
error:/Users/olafurpg/dev/metals/target/docs/in.md:2:28:typemismatch;
found : Stringrequired: Intdefa="".lengthCompare("1".substring(1))
^^^^^^^^^^^^^^^^
info:Compiled in 1.28s (1 error)
The text was updated successfully, but these errors were encountered:
In BSP, Bloop reports the following range position for the diagnostic
I expected the range position to be the following
It looks like the start offset is using the
Position.point
offset from the compiler instead ofPosition.start
. Here is how the error looks fromscalac
in the terminal with-Yrangepos
enabledIn mdoc, we use
Position.{start,end}
from the compiler diagnostics and the errors are published as expected.The text was updated successfully, but these errors were encountered: