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
The end Location for multiline doc comments seems incorrect by a few characters. This results in the underlining of multiline doc comments when reporting error/warning locations are slightly off.
Sample output :
warning [W001]: doc comment has a param tag for 'x', but there is no parameter by that name
--> test_slice/foo.slice:4:5
|
4 | /// @param x this is a x
5 | /// @param y this is a y
| ---------------------------- <---- too long
|
Slice to reproduce:
module Foo;
interface I {
/// @param x this is a x
/// @param y this is a y
op(y: int32, z: int32, a: int32);
}
The text was updated successfully, but these errors were encountered:
I suspect this is really just another facet of #240.
We don't keep spans for each line of a comment separately, there is 1 span for the entire comment.
If the comment is multiple lines (like here), it will have all the same issues other multi-line comments have.
You're right, this is unrelated. Pest greedily consume whitespace in some places, so with doc comments, it's incorrectly matching the newline and leading whitespace on the next line as part of the doc comment.
I'm going to ignore it for now. It should be fixed in my new parser.
The end
Location
for multiline doc comments seems incorrect by a few characters. This results in the underlining of multiline doc comments when reporting error/warning locations are slightly off.Sample output :
Slice to reproduce:
The text was updated successfully, but these errors were encountered: