Expand description
clear(&mut g) — empty the backing storage in place.
Mirrors boost::geometry::clear from
boost/geometry/algorithms/clear.hpp. Per-kind:
Linestring,Ring,MultiPoint→Vec::clearon the backing.Polygon→ clear the outer ring and drop every inner ring.MultiLinestring,MultiPolygon→Vec::clearon the member vector.Point,Box,Segment→ no impl (fixed-size storage — there is nothing to clear).
Boost ships the fixed-size case as a silent no-op fall-through
(clear.hpp); the Rust port instead simply provides no [Clear]
impl for Point / Box / Segment, so clear(&mut point) is a
compile error — the type system says “call this on something that
has clearable storage.”
Functions§
- clear
- Empty the backing storage of
gin place.