mirror of
https://github.com/boostorg/geometry.git
synced 2025-05-09 23:24:02 +00:00
[test] Use BOOST_GEOMETRY_CONDITION macro for constant conditions.
This commit is contained in:
parent
6b438738d8
commit
eceba44876
@ -242,8 +242,8 @@ void test_all()
|
||||
test_wrong_wkt<bg::model::box<P> >("BOX(1 1,2 2,3 3)", "box should have 2");
|
||||
test_wrong_wkt<bg::model::box<P> >("BOX(1 1,2 2) )", "too much tokens");
|
||||
|
||||
if (boost::is_floating_point<T>::type::value
|
||||
|| ! boost::is_fundamental<T>::type::value)
|
||||
if ( BOOST_GEOMETRY_CONDITION(boost::is_floating_point<T>::type::value
|
||||
|| ! boost::is_fundamental<T>::type::value ) )
|
||||
{
|
||||
test_wkt<P>("POINT(1.1 2.1)", 1);
|
||||
}
|
||||
|
@ -72,14 +72,7 @@ struct access<rw_lon_lat_point<CoordinateType, CoordinateSystem>, Dimension>
|
||||
void set(rw_lon_lat_point<CoordinateType, CoordinateSystem>& p,
|
||||
CoordinateType const& value)
|
||||
{
|
||||
if (Dimension == 0)
|
||||
{
|
||||
p.longitude = value;
|
||||
}
|
||||
else
|
||||
{
|
||||
p.latitude = value;
|
||||
}
|
||||
( Dimension == 0 ? p.longitude : p.latitude ) = value;
|
||||
}
|
||||
};
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user