Skip to content

Commit 928603f

Browse files
committed
Fix vs2015 workarounds #ifdefs to work with non-vc compilers properly.
1 parent 4789f03 commit 928603f

File tree

7 files changed

+8
-8
lines changed

7 files changed

+8
-8
lines changed

include/boost/geometry/algorithms/area_result.hpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,7 @@ struct default_area_result
7676
{};
7777

7878
// Workaround for VS2015
79-
#if (_MSC_VER < 1910)
79+
#if defined(_MSC_VER) && (_MSC_VER < 1910)
8080
template
8181
<
8282
typename Geometry,

include/boost/geometry/arithmetic/cross_product.hpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -138,7 +138,7 @@ template
138138
> = 0
139139
>
140140
// workaround for VS2015
141-
#if (_MSC_VER >= 1910)
141+
#if !defined(_MSC_VER) || (_MSC_VER >= 1910)
142142
constexpr
143143
#endif
144144
inline ResultP cross_product(P1 const& p1, P2 const& p2)
@@ -193,7 +193,7 @@ template
193193
> = 0
194194
>
195195
// workaround for VS2015
196-
#if (_MSC_VER >= 1910)
196+
#if !defined(_MSC_VER) || (_MSC_VER >= 1910)
197197
constexpr
198198
#endif
199199
inline P cross_product(P const& p1, P const& p2)

include/boost/geometry/arithmetic/dot_product.hpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -75,7 +75,7 @@ struct dot_product_maker<P1, P2, DimensionCount, DimensionCount>
7575
*/
7676
template <typename Point1, typename Point2>
7777
// workaround for VS2015
78-
#if (_MSC_VER >= 1910)
78+
#if !defined(_MSC_VER) || (_MSC_VER >= 1910)
7979
constexpr
8080
#endif
8181
inline typename select_coordinate_type<Point1, Point2>::type dot_product(

include/boost/geometry/geometries/point.hpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -112,7 +112,7 @@ class point
112112
/// \constructor_default_no_init
113113
constexpr point()
114114
// Workaround for VS2015
115-
#if (_MSC_VER < 1910)
115+
#if defined(_MSC_VER) && (_MSC_VER < 1910)
116116
: m_values{} {}
117117
#else
118118
= default;

include/boost/geometry/strategies/comparable_distance_result.hpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,7 @@ struct comparable_distance_result<Geometry1, Geometry2, default_strategy, AreGeo
6161
{};
6262

6363
// Workaround for VS2015
64-
#if (_MSC_VER < 1910)
64+
#if defined(_MSC_VER) && (_MSC_VER < 1910)
6565
template <typename Geometry1, typename Geometry2, typename Strategy>
6666
struct comparable_distance_result<Geometry1, Geometry2, Strategy, false>
6767
{

include/boost/geometry/strategies/default_length_result.hpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ namespace resolve_strategy
4242

4343

4444
// Workaround for VS2015
45-
#if (_MSC_VER < 1910)
45+
#if defined(_MSC_VER) && (_MSC_VER < 1910)
4646
template
4747
<
4848
typename Geometry,

include/boost/geometry/strategies/distance_result.hpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,7 @@ struct distance_result<Geometry1, Geometry2, default_strategy, AreGeometries>
6969

7070

7171
// Workaround for VS2015
72-
#if (_MSC_VER < 1910)
72+
#if defined(_MSC_VER) && (_MSC_VER < 1910)
7373
template <typename Geometry1, typename Geometry2, typename Strategy>
7474
struct distance_result<Geometry1, Geometry2, Strategy, false>
7575
{

0 commit comments

Comments
 (0)