Skip to content
Permalink
Browse files
AGG headers: remove use of deprecated register keyword, that is forbi…
…dden in C++17
  • Loading branch information
rouault committed Jan 17, 2020
1 parent c16df18 commit 51581788919a52020c953dca50136d825b32ea1b
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 8 deletions.
@@ -211,7 +211,7 @@ namespace mapserver
{
AGG_INLINE static unsigned mul(unsigned a, unsigned b)
{
register unsigned q = a * b + (1 << (Shift-1));
const unsigned q = a * b + (1 << (Shift-1));
return (q + (q >> Shift)) >> Shift;
}
};
@@ -174,8 +174,8 @@ namespace mapserver
private:
AGG_INLINE const int8u* pixel() const
{
register int x = m_x;
register int y = m_y;
int x = m_x;
int y = m_y;
if(x < 0) x = 0;
if(y < 0) y = 0;
if(x >= (int)m_pixf->width()) x = m_pixf->width() - 1;
@@ -292,25 +292,25 @@ namespace mapserver
//------------------------------------------------------------------------
inline void trans_affine::transform(double* x, double* y) const
{
register double tmp = *x;
const double tmp = *x;
*x = tmp * sx + *y * shx + tx;
*y = tmp * shy + *y * sy + ty;
}

//------------------------------------------------------------------------
inline void trans_affine::transform_2x2(double* x, double* y) const
{
register double tmp = *x;
const double tmp = *x;
*x = tmp * sx + *y * shx;
*y = tmp * shy + *y * sy;
}

//------------------------------------------------------------------------
inline void trans_affine::inverse_transform(double* x, double* y) const
{
register double d = determinant_reciprocal();
register double a = (*x - tx) * d;
register double b = (*y - ty) * d;
const double d = determinant_reciprocal();
const double a = (*x - tx) * d;
const double b = (*y - ty) * d;
*x = a * sy - b * shx;
*y = b * sx - a * shy;
}

0 comments on commit 5158178

Please sign in to comment.