rust/tests/ui/suggestions/suggest-assoc-fn-call-with-turbofish-through-deref.rs

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

14 lines
265 B
Rust
Raw Normal View History

use std::cell::RefCell;
struct HasAssocMethod;
impl HasAssocMethod {
fn hello() {}
}
fn main() {
let shared_state = RefCell::new(HasAssocMethod);
let state = shared_state.borrow_mut();
state.hello();
//~^ ERROR no method named `hello` found
}