]> git.lizzy.rs Git - rust.git/blob - tests/ui/structs/rhs-type.rs
Auto merge of #106503 - cjgillot:remap-nofilter, r=oli-obk
[rust.git] / tests / ui / structs / rhs-type.rs
1 // Tests that codegen treats the rhs of pth's decl
2 // as a _|_-typed thing, not a str-typed thing
3
4 // run-fail
5 // error-pattern:bye
6 // ignore-emscripten no processes
7
8 #![allow(unreachable_code)]
9 #![allow(unused_variables)]
10
11 struct T {
12     t: String,
13 }
14
15 fn main() {
16     let pth = panic!("bye");
17     let _rs: T = T { t: pth };
18 }