Macro geo_types::coord

source ·
macro_rules! coord {
    (x: $x:expr, y: $y:expr $(,)* ) => { ... };
}
Expand description

Creates a Coord from the given scalars.

coord! { x: <number>, y: <number> }

§Examples

Creating a Coord, supplying x/y values:

use geo_types::coord;

let c = coord! { x: 181.2, y: 51.79 };

assert_eq!(c, geo_types::coord! { x: 181.2, y: 51.79 });