Skip to content

Commit 4fee6d8

Browse files
author
timlinux
committed
Dont call method 'max' because its a reserved word / compiler macro on some platforms (MSVC) and causes build failures
git-svn-id: http://svn.osgeo.org/qgis/trunk@8141 c8812cc2-4d05-0410-92ff-de0c093fc19c
1 parent d63cd64 commit 4fee6d8

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

src/core/qgspoint.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -99,7 +99,7 @@ int QgsPoint::onSegment(const QgsPoint& a, const QgsPoint& b) const
9999
//algorithm from 'graphics GEMS', A. Paeth: 'A Fast 2D Point-on-line test'
100100
if(
101101
fabs( (b.y() - a.y()) * (m_x - a.x()) - (m_y - a.y()) * (b.x() - a.x())) \
102-
>= max( fabs(b.x() - a.x()), fabs(b.y() - a.y()))
102+
>= maxValue( fabs(b.x() - a.x()), fabs(b.y() - a.y()))
103103
)
104104
{
105105
return 0;
@@ -124,7 +124,7 @@ int QgsPoint::onSegment(const QgsPoint& a, const QgsPoint& b) const
124124
return 2;
125125
}
126126

127-
double QgsPoint::max(double a, double b) const
127+
double QgsPoint::maxValue(double a, double b) const
128128
{
129129
if(b > a)
130130
{

src/core/qgspoint.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -129,7 +129,7 @@ class CORE_EXPORT QgsPoint
129129

130130
//! little helper function that returns the maximum of
131131
//! two doubles (or a in case of equality)
132-
double max(double a, double b) const;
132+
double maxValue(double a, double b) const;
133133

134134
}; // class QgsPOint
135135

0 commit comments

Comments
 (0)