rust/tests/ui/unwrap_or.rs
bootandy 941e062fd4 Fix: point to correct problem part of code
Fix span so it no longer contains the whole train-wreck of code and only
points to the problem function (for the unwrap_or lint).

https://github.com/rust-lang-nursery/rust-clippy/issues/2422

Update ui test methods - it had several cases where the error message
span is now shorter
2018-02-19 12:14:53 -05:00

6 lines
115 B
Rust

#![warn(clippy)]
fn main() {
let s = Some(String::from("test string")).unwrap_or("Fail".to_string()).len();
}