Turbofish triggers loss of spans #68489
Labels
A-diagnostics
Area: Messages for errors, warnings, and lints
A-macros
Area: All kinds of macros (custom derive, macro_rules!, proc macros, ..)
A-proc-macros
Area: Procedural macros
C-bug
Category: This is a bug.
T-compiler
Relevant to the compiler team, which will review and decide on the PR/issue.
This is a subissue of #43081 but likely fixable without fixing #43081 in full generality.
src/lib.rs
src/main.rs
When running
cargo check
, notice that all the spans in the output are#0 bytes(0..0)
(classic #43081) and therefore all error reporting within the function body is broken; there is no line number on the "cannot find function `f` in this scope" error.The following script reproduces the issue as of rustc 1.42.0-nightly (d1e594f 2020-01-22):
cc @petrochenkov who fixed a previous special case of #43081.
The text was updated successfully, but these errors were encountered: