]> git.ipfire.org Git - thirdparty/coreutils.git/commitdiff
Import from gnulib.
authorPaul Eggert <eggert@cs.ucla.edu>
Fri, 19 Aug 2005 21:14:12 +0000 (21:14 +0000)
committerPaul Eggert <eggert@cs.ucla.edu>
Fri, 19 Aug 2005 21:14:12 +0000 (21:14 +0000)
(__restrict_arr): Don't define to __restrict if __cplusplus is defined.

lib/regex.h

index 0a59c7be1ca24602a5828068822e1b98529d03ef..bdce605a3de5b6fa9ee35244b23001e674c29042 100644 (file)
@@ -552,9 +552,9 @@ extern int re_exec _RE_ARGS ((const char *));
 #  endif
 # endif
 #endif
-/* gcc 3.1 and up support the [restrict] syntax.  */
+/* gcc 3.1 and up support the [restrict] syntax, but g++ doesn't.  */
 #ifndef __restrict_arr
-# if __GNUC__ > 3 || (__GNUC__ == 3 && __GNUC_MINOR__ >= 1)
+# if (__GNUC__ > 3 || (__GNUC__ == 3 && __GNUC_MINOR__ >= 1)) && !defined __cplusplus
 #  define __restrict_arr __restrict
 # else
 #  define __restrict_arr