rust/src/test/ui/issues/issue-21622.rs
2019-07-03 06:30:28 +09:00

22 lines
300 B
Rust

// build-pass (FIXME(62277): could be check-pass?)
#![allow(dead_code)]
#![allow(unused_variables)]
struct Index;
impl Index {
fn new() -> Self { Index }
}
fn user() {
let new = Index::new;
fn inner() {
let index = Index::new();
}
let index2 = new();
}
fn main() {}