rust/tests/ui/parser/issues/issue-19096.rs

11 lines
386 B
Rust
Raw Normal View History

fn main() { // we don't complain about the return type being `{integer}`
2015-01-31 10:23:42 -06:00
let t = (42, 42);
t.0::<isize>; //~ ERROR expected one of `.`, `;`, `?`, `}`, or an operator, found `::`
}
fn foo() -> usize { // we don't complain about the return type being unit
let t = (42, 42);
t.0::<isize>; //~ ERROR expected one of `.`, `;`, `?`, `}`, or an operator, found `::`
42;
2014-11-23 05:27:10 -06:00
}