rust/tests/ui/debuginfo/issue-105386-debuginfo-ub.rs
2023-01-11 09:32:08 +00:00

21 lines
352 B
Rust

// run-pass
// compile-flags: --edition 2021 -Copt-level=3 -Cdebuginfo=2 -Zmir-opt-level=3
fn main() {
TranslatorI.visit_pre();
}
impl TranslatorI {
fn visit_pre(self) {
Some(())
.map(|_| self.flags())
.unwrap_or_else(|| self.flags());
}
}
struct TranslatorI;
impl TranslatorI {
fn flags(&self) {}
}