Join GitHub today
GitHub is home to over 31 million developers working together to host and review code, manage projects, and build software together.
Sign upBackward spans are displayed strangely #42104
Comments
This comment has been minimized.
This comment has been minimized.
|
cc @estebank who touched this code recently. |
This comment has been minimized.
This comment has been minimized.
|
Oh, beautiful... I'm seeing many problems with this output, beyond the obvious. I feel the proper output should either be: warning: struct is never used: `S`
--> src/main.rs:8:10
|
3 | $b $a;
| ^^^^^^ unused struct
...
8 | m!(S struct);
| ------------- in this macro invocation
|
= note: #[warn(dead_code)] on by defaultor warning: struct is never used: `S`
--> src/main.rs:8:10
|
8 | m!(S struct);
| ---^^^^^^^^-- in this macro invocation
| |
| unused struct
= note: #[warn(dead_code)] on by defaultI can make (or mentor) a small patch to either swap end and start if they are reversed or only point at the last end for that case, but I'd prefer to properly fix the spans generated in macro invocations in a better way regardless. |
This comment has been minimized.
This comment has been minimized.
|
This made it into 1.18.0. |
Mark-Simulacrum
added
regression-from-stable-to-beta
regression-from-stable-to-stable
and removed
regression-from-stable-to-beta
labels
Jun 17, 2017
brson
added
T-compiler
A-diagnostics
E-help-wanted
E-mentor
labels
Jul 13, 2017
Mark-Simulacrum
added
the
P-low
label
Jul 13, 2017
This comment has been minimized.
This comment has been minimized.
|
Help wanted. @estebank can mentor. |
estebank
referenced this issue
Jul 20, 2017
Merged
Use the macro structure spans instead of the invocation #43352
bors
added a commit
that referenced
this issue
Jul 22, 2017
bors
closed this
in
#43352
Jul 22, 2017
This comment has been minimized.
This comment has been minimized.
|
@brson should this be backported to 1.19? I don't feel there's a need to rush it. |
This comment has been minimized.
This comment has been minimized.
|
I'm going to suggest that we don't backport this; it's not high-impact enough. |
This comment has been minimized.
This comment has been minimized.
|
That's my thinking as well. |
dtolnay commentedMay 19, 2017
This is a regression in 1.18.0-beta but unclear whether it affects anything in practice. We encountered this in #rust-libs discussing #40939.