Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Dont call method 'max' because its a reserved word / compiler macro o…
…n some platforms (MSVC) and causes build failures

git-svn-id: http://svn.osgeo.org/qgis/trunk@8141 c8812cc2-4d05-0410-92ff-de0c093fc19c
  • Loading branch information
timlinux committed Feb 12, 2008
1 parent d63cd64 commit 4fee6d8
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions src/core/qgspoint.cpp
Expand Up @@ -99,7 +99,7 @@ int QgsPoint::onSegment(const QgsPoint& a, const QgsPoint& b) const
//algorithm from 'graphics GEMS', A. Paeth: 'A Fast 2D Point-on-line test'
if(
fabs( (b.y() - a.y()) * (m_x - a.x()) - (m_y - a.y()) * (b.x() - a.x())) \
>= max( fabs(b.x() - a.x()), fabs(b.y() - a.y()))
>= maxValue( fabs(b.x() - a.x()), fabs(b.y() - a.y()))
)
{
return 0;
Expand All @@ -124,7 +124,7 @@ int QgsPoint::onSegment(const QgsPoint& a, const QgsPoint& b) const
return 2;
}

double QgsPoint::max(double a, double b) const
double QgsPoint::maxValue(double a, double b) const
{
if(b > a)
{
Expand Down
2 changes: 1 addition & 1 deletion src/core/qgspoint.h
Expand Up @@ -129,7 +129,7 @@ class CORE_EXPORT QgsPoint

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

}; // class QgsPOint

Expand Down

0 comments on commit 4fee6d8

Please sign in to comment.