Rename util::begin/end -> xbegin/xend to prevent ambiguity via ADL
This commit is contained in:
parent
6368ca5e68
commit
82f7d5d429
5 changed files with 8 additions and 8 deletions
|
|
@ -20,7 +20,7 @@ namespace psemek::cg
|
||||||
template <typename Container>
|
template <typename Container>
|
||||||
auto bbox(Container const & container)
|
auto bbox(Container const & container)
|
||||||
{
|
{
|
||||||
return bbox(util::begin(container), util::end(container));
|
return bbox(util::xbegin(container), util::xend(container));
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -95,7 +95,7 @@ namespace psemek::geom
|
||||||
template <typename Polygon, typename T>
|
template <typename Polygon, typename T>
|
||||||
bool polygon_contains(Polygon const & polygon, point<T, 2> const & p)
|
bool polygon_contains(Polygon const & polygon, point<T, 2> const & p)
|
||||||
{
|
{
|
||||||
return polygon_contains(util::begin(polygon), util::end(polygon), p);
|
return polygon_contains(util::xbegin(polygon), util::xend(polygon), p);
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -134,7 +134,7 @@ namespace psemek::geom
|
||||||
template <typename T, typename Polygon>
|
template <typename T, typename Polygon>
|
||||||
std::pair<T, vector<T, 2>> signed_polygon_distance_direction(point<T, 2> const & p, Polygon const & polygon)
|
std::pair<T, vector<T, 2>> signed_polygon_distance_direction(point<T, 2> const & p, Polygon const & polygon)
|
||||||
{
|
{
|
||||||
return signed_polygon_distance_direction(p, util::begin(polygon), util::end(polygon));
|
return signed_polygon_distance_direction(p, util::xbegin(polygon), util::xend(polygon));
|
||||||
}
|
}
|
||||||
|
|
||||||
template <typename T, typename Iterator>
|
template <typename T, typename Iterator>
|
||||||
|
|
@ -146,7 +146,7 @@ namespace psemek::geom
|
||||||
template <typename T, typename Polygon>
|
template <typename T, typename Polygon>
|
||||||
T signed_polygon_distance(point<T, 2> const & p, Polygon const & polygon)
|
T signed_polygon_distance(point<T, 2> const & p, Polygon const & polygon)
|
||||||
{
|
{
|
||||||
return signed_polygon_distance(p, util::begin(polygon), util::end(polygon));
|
return signed_polygon_distance(p, util::xbegin(polygon), util::xend(polygon));
|
||||||
}
|
}
|
||||||
|
|
||||||
template <typename T, typename Iterator>
|
template <typename T, typename Iterator>
|
||||||
|
|
@ -158,7 +158,7 @@ namespace psemek::geom
|
||||||
template <typename T, typename Polygon>
|
template <typename T, typename Polygon>
|
||||||
T polygon_distance(point<T, 2> const & p, Polygon const & polygon)
|
T polygon_distance(point<T, 2> const & p, Polygon const & polygon)
|
||||||
{
|
{
|
||||||
return polygon_distance(p, util::begin(polygon), util::end(polygon));
|
return polygon_distance(p, util::xbegin(polygon), util::xend(polygon));
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -91,7 +91,7 @@ namespace psemek::util
|
||||||
template <typename Container>
|
template <typename Container>
|
||||||
auto make_cyclic_iterator(Container & container)
|
auto make_cyclic_iterator(Container & container)
|
||||||
{
|
{
|
||||||
return cyclic_iterator{util::begin(container), util::end(container)};
|
return cyclic_iterator{util::xbegin(container), util::xend(container)};
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -26,13 +26,13 @@ namespace psemek::util
|
||||||
}
|
}
|
||||||
|
|
||||||
template <typename Container>
|
template <typename Container>
|
||||||
auto begin(Container & x)
|
auto xbegin(Container & x)
|
||||||
{
|
{
|
||||||
return detail::begin_helper(x);
|
return detail::begin_helper(x);
|
||||||
}
|
}
|
||||||
|
|
||||||
template <typename Container>
|
template <typename Container>
|
||||||
auto end(Container & x)
|
auto xend(Container & x)
|
||||||
{
|
{
|
||||||
return detail::end_helper(x);
|
return detail::end_helper(x);
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue