about summary refs log tree commit diff
path: root/compiler/rustc_ast
diff options
context:
space:
mode:
authorbors <bors@rust-lang.org>2025-07-24 20:38:53 +0000
committerbors <bors@rust-lang.org>2025-07-24 20:38:53 +0000
commitb56aaec52bc0fa35591a872fb4aac81f606e265c (patch)
tree6265c613fe25072d6dbe81c96c8421d7fe774bf5 /compiler/rustc_ast
parent246733a3d978de41c5b77b8120ba8f41592df9f1 (diff)
parent01524abb05a4a60d0015972811b8bbb9bd2a73d3 (diff)
downloadrust-b56aaec52bc0fa35591a872fb4aac81f606e265c.tar.gz
rust-b56aaec52bc0fa35591a872fb4aac81f606e265c.zip
Auto merge of #144389 - scottmcm:no-more-mir-cast-assume, r=davidtwco
MIR-build: No longer emit assumes in enum-as casting

This just uses the `valid_range` from the backend, so it's duplicating the range metadata that now we include on parameters and loads, and thus no longer seems to be useful -- notably there's no codegen test failures from removing it.

(Because it's using data from the same source as the backend annotations, it doesn't do anything to mitigate things like rust-lang/rust#144388 where the range in the layout is more permissive than the actual possible discriminants.  A variant of this that actually checked the discriminants more specifically might be useful, so could potentially be added in future, but I don't think the *current* checks are actually providing value.)

r? mir

Randomly turns out that this
Fixes https://github.com/rust-lang/rust/issues/121097
Diffstat (limited to 'compiler/rustc_ast')
0 files changed, 0 insertions, 0 deletions