large_assignments
: Unactionable diagnostics with -Zinline-mir
#121672
Labels
A-diagnostics
Area: Messages for errors, warnings, and lints
A-lint
Area: Lints (warnings about flaws in source code) such as unused_mut.
A-mir-opt-inlining
Area: MIR inlining
C-bug
Category: This is a bug.
D-confusing
Diagnostics: Confusing error or lint that should be reworked.
L-large_assignments
Lint: large_assignments
requires-nightly
This issue requires a nightly compiler in some way.
T-compiler
Relevant to the compiler team, which will review and decide on the PR/issue.
Tracking issue #83518.
Doing
cargo build --release
will activate-Zinline-mir
under the hood (through-Copt-level=3
). But it makeslarge_assignments
diagnostics unhelpful, because it can make diagnostics point to library code that the user can't change.How to reproduce
src/main.rs
# One of: cargo +nightly build --release cargo +nightly rustc -- -Zmir-opt-level=1 -Zinline-mir
Actual
Expected
Remarks
The expected diagnostics is given with these commands. Note how
-Zinline-mir
is deactivated in both cases:# One of: cargo +nightly build cargo +nightly rustc -- -Zmir-opt-level=1
The above test case is ui-testified here.
CC E-mentor @oli-obk who maybe have an idea on how to fix this? (I currently don't.)
The text was updated successfully, but these errors were encountered: