# HG changeset patch # User Jonathan Kew # Date 1619706813 0 # Node ID e37242f1457e36d19c0a92bb47408d1920b7b70e # Parent 7821deb4d77b377be00e04dadc8351b35526954a Bug 739096 - Don't declare local var with 'register' in C++. r=jrmuizel Differential Revision: https://phabricator.services.mozilla.com/D112584 diff --git a/gfx/cairo/cairo/src/cairoint.h b/gfx/cairo/cairo/src/cairoint.h --- a/gfx/cairo/cairo/src/cairoint.h +++ b/gfx/cairo/cairo/src/cairoint.h @@ -176,17 +176,21 @@ do { \ * good as the open-coded solution below, (which is "HACKMEM 169"). */ static inline int cairo_const _cairo_popcount (uint32_t mask) { #if __GNUC__ > 3 || (__GNUC__ == 3 && __GNUC_MINOR__ >= 4) return __builtin_popcount (mask); #else +#ifdef __cplusplus + int y; +#else register int y; +#endif y = (mask >> 1) &033333333333; y = mask - y - ((y >>1) & 033333333333); return (((y + (y >> 3)) & 030707070707) % 077); #endif } #ifdef WORDS_BIGENDIAN