make custom mir ICE a bit nicer

This commit is contained in:
Matthias Krüger 2023-06-25 23:16:00 +02:00
parent 0d03812e24
commit c6e6ceb078

View File

@ -118,7 +118,11 @@ fn parse_attribute(attr: &Attribute) -> MirPhase {
phase = Some(value); phase = Some(value);
} }
other => { other => {
panic!("Unexpected key {}", other); span_bug!(
nested.span(),
"Unexpected key while parsing custom_mir attribute: '{}'",
other
);
} }
} }
} }