]> git.lizzy.rs Git - rust.git/blob - tests/ui/crashes/ice-2865.rs
Merge pull request #3918 from matthiaskrgr/typos
[rust.git] / tests / ui / crashes / ice-2865.rs
1 // run-pass
2
3 #[allow(dead_code)]
4
5 /// Test for https://github.com/rust-lang/rust-clippy/issues/2865
6
7 struct Ice {
8     size: String,
9 }
10
11 impl<'a> From<String> for Ice {
12     fn from(_: String) -> Self {
13         let text = || "iceberg".to_string();
14         Self { size: text() }
15     }
16 }
17
18 fn main() {}