]> git.lizzy.rs Git - rust.git/blob - src/test/run-pass/class-attributes-1.rs
Remove struct ctors
[rust.git] / src / test / run-pass / class-attributes-1.rs
1 // pp-exact - Make sure we actually print the attributes
2
3 struct cat {
4     #[cat_dropper]
5     drop { error!("%s landed on hir feet",self.name); }
6     name: ~str,
7 }
8
9 #[cat_maker]
10 fn cat(name: ~str) -> cat { cat{name: name,} }
11
12 fn main() { let _kitty = cat(~"Spotty"); }