name resolution 2.0 fails on impl function call
CohenArthur opened this issue · comments
I tried this code:
struct Foo;
impl Foo {
fn new() -> Foo {
Foo
}
}
fn main() {
let _ = Foo::new();
}
I expected to see this happen: no error.
Instead, this happened:
~/G/r/gccrs (master|✚2) $ build/gcc/crab1 test.rs -frust-name-resolution-2.0
test.rs:25:13: error: failed to resolve path segment ‘Foo’ [E0433]
25 | let _ = Foo::new();
| ^~~
Meta
- What version of Rust GCC were you using: 8a72566