rust/src/test/ui/issues/issue-11493.rs

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

8 lines
123 B
Rust
Raw Normal View History

2017-08-13 08:46:49 +00:00
fn id<T>(x: T) -> T { x }
2014-05-07 05:53:02 +00:00
fn main() {
2015-01-31 16:23:42 +00:00
let x = Some(3);
let y = x.as_ref().unwrap_or(&id(5)); //~ ERROR
&y;
}