]> git.lizzy.rs Git - rust.git/blob - tests/run-pass/issue-825.rs
Adapt run-pass tests to the tool_lints
[rust.git] / tests / run-pass / issue-825.rs
1 #![allow(warnings)]
2
3 // this should compile in a reasonable amount of time
4 fn rust_type_id(name: &str) {
5     if "bool" == &name[..] || "uint" == &name[..] || "u8" == &name[..] || "u16" == &name[..] || "u32" == &name[..]
6         || "f32" == &name[..] || "f64" == &name[..] || "i8" == &name[..] || "i16" == &name[..]
7         || "i32" == &name[..] || "i64" == &name[..] || "Self" == &name[..] || "str" == &name[..]
8     {
9         unreachable!();
10     }
11 }
12
13 fn main() {}