xref: /Universal-ctags/Units/parser-rust.r/rust-simple.d/input.rs (revision b036de7b9e493e4d9193d5bbdf21197ec57173b0)
1 //
2 // Taken from http://doc.rust-lang.org/guide.html
3 //
main()4 fn main() {
5 	println!("Hello, world!");
6 }
7 struct Circle {
8     x: f64,
9     y: f64,
10     radius: f64,
11 }
12 
13 impl Circle {
area(&self) -> f6414     fn area(&self) -> f64 {
15         std::f64::consts::PI * (self.radius * self.radius)
16     }
17 }
18