Do not ICE when we have -Zunpretty=expand with invalid ABI
This commit is contained in:
parent
d5e7f4782e
commit
26ecd44160
5 changed files with 33 additions and 6 deletions
|
@ -274,10 +274,12 @@ impl<'a> PostExpansionVisitor<'a> {
|
|||
);
|
||||
}
|
||||
abi => {
|
||||
self.sess.parse_sess.span_diagnostic.delay_span_bug(
|
||||
span,
|
||||
&format!("unrecognized ABI not caught in lowering: {}", abi),
|
||||
);
|
||||
if self.sess.opts.pretty.map_or(true, |ppm| ppm.needs_hir()) {
|
||||
self.sess.parse_sess.span_diagnostic.delay_span_bug(
|
||||
span,
|
||||
&format!("unrecognized ABI not caught in lowering: {}", abi),
|
||||
);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue