]> git.proxmox.com Git - rustc.git/blame - src/test/ui/class-missing-self.rs
New upstream version 1.40.0+dfsg1
[rustc.git] / src / test / ui / class-missing-self.rs
CommitLineData
0731742a 1struct Cat {
1a4d82fc 2 meows : usize,
223e47cc
LB
3}
4
0731742a 5impl Cat {
223e47cc
LB
6 fn sleep(&self) { loop{} }
7 fn meow(&self) {
1a4d82fc 8 println!("Meow");
32a655c1 9 meows += 1; //~ ERROR cannot find value `meows` in this scope
e74abb32 10 sleep(); //~ ERROR cannot find function `sleep` in this
223e47cc
LB
11 }
12
13}
14
15
16 fn main() { }