Skip to main content

Module assign

Module assign 

Source
Expand description

Write coordinates into a mutable geometry.

Mirrors boost::geometry::assign_values from boost/geometry/algorithms/assign.hpp. Boost exposes variadic overloads (assign_values(p, x, y), assign_values(p, x, y, z), …); the Rust port takes a slice so one signature covers every arity. The arity check that Boost gets for free from SFINAE (a two-argument call on a 3-D point fails to compile) becomes a runtime assert! on the slice length here.

Functions§

assign_values
Write values[D] to p.set::<D>(values[D]) for every dimension D in 0..P::DIM.