1 2 3 4 5 6 7 8 9 10 11
#[derive(Debug, Clone, Copy, PartialEq)] pub struct Point { x: f32, y: f32, } impl Point { pub fn new(x: f32, y: f32) -> Self { Self { x, y } } }
1 2 3 4 5 6 7 8 9 10 11
#[derive(Debug, Clone, Copy, PartialEq)] pub struct Point { x: f32, y: f32, } impl Point { pub fn new(x: f32, y: f32) -> Self { Self { x, y } } }