topojson - remove 'invalid' geometry type to avoid default constructed geometries
This commit is contained in:
parent
12485b66ef
commit
8128a2b1ef
4 changed files with 2 additions and 17 deletions
|
@ -238,12 +238,6 @@ struct bounding_box_visitor
|
|||
}
|
||||
return bbox;
|
||||
}
|
||||
|
||||
box2d<double> operator() (mapnik::topojson::invalid const&) const
|
||||
{
|
||||
return box2d<double>();
|
||||
}
|
||||
|
||||
private:
|
||||
topology const& topo_;
|
||||
std::size_t num_arcs_;
|
||||
|
|
|
@ -86,10 +86,7 @@ struct multi_polygon
|
|||
boost::optional<properties> props;
|
||||
};
|
||||
|
||||
struct invalid {};
|
||||
|
||||
using geometry = util::variant<invalid,
|
||||
point,
|
||||
using geometry = util::variant<point,
|
||||
linestring,
|
||||
polygon,
|
||||
multi_point,
|
||||
|
|
|
@ -109,10 +109,6 @@ struct geometry_type_visitor
|
|||
{
|
||||
return static_cast<int>(mapnik::datasource_geometry_t::Polygon);
|
||||
}
|
||||
int operator() (mapnik::topojson::invalid const&) const
|
||||
{
|
||||
return -1;
|
||||
}
|
||||
};
|
||||
|
||||
struct collect_attributes_visitor
|
||||
|
@ -121,8 +117,6 @@ struct collect_attributes_visitor
|
|||
collect_attributes_visitor(mapnik::layer_descriptor & desc):
|
||||
desc_(desc) {}
|
||||
|
||||
void operator() (mapnik::topojson::invalid const&) {}
|
||||
|
||||
template <typename GeomType>
|
||||
void operator() (GeomType const& g)
|
||||
{
|
||||
|
|
Loading…
Reference in a new issue