62f98c8ff8
Maintain explicit "paren" nodes in the AST so we can pretty-print without having to guess where parens should go. We may revisit this in the future. r=graydon
12 lines
357 B
Rust
12 lines
357 B
Rust
trait foo<T> { }
|
|
|
|
fn bar(x: foo<uint>) -> foo<int> {
|
|
return (x as foo::<int>);
|
|
//~^ ERROR mismatched types: expected `@foo<int>` but found `@foo<uint>`
|
|
//~^^ ERROR mismatched types: expected `@foo<int>` but found `@foo<uint>`
|
|
// This is unfortunate -- new handling of parens means the error message
|
|
// gets printed twice
|
|
}
|
|
|
|
fn main() {}
|