macro_rules! point {
($($values:expr),+) => { ... };
}Expand description
Creates a single Point, where the dimension is determined from the number of values specified, and the values all must implement ExtendedNumOps and be of the same type.
ยงExample
use simplify_polyline::*;
// 2d point
let point2d: Point<2, i32> = point!(1, 2);
assert_eq!(point2d.vec.len(), 2);
// 8d point
let point8d: Point<8, i32> = point!(1, 2, 3, 4, 5, 6, 7, 8);
assert_eq!(point8d.vec.len(), 8);