]> git.ipfire.org Git - thirdparty/autoconf.git/commitdiff
Fix AC_C_RESTRICT for Sun Studio 12 C++.
authorEric Blake <ebb9@byu.net>
Wed, 28 Jan 2009 16:57:08 +0000 (09:57 -0700)
committerEric Blake <ebb9@byu.net>
Wed, 28 Jan 2009 16:59:24 +0000 (09:59 -0700)
* lib/autoconf/c.m4 (AC_C_RESTRICT): Newer Sun Studio C provides
__restrict__ rather than _Restrict, which still trips up Sun
Studio 12 C++.
* THANKS: Update.
Reported by Rolf Vandevaart.

Signed-off-by: Eric Blake <ebb9@byu.net>
ChangeLog
THANKS
lib/autoconf/c.m4

index 2885f2789af6aaf5809f41c63c26727b96e8a6ba..44e147cd2acc0c1f1a347023ce166b19a9d45b03 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,12 @@
+2009-01-28  Eric Blake  <ebb9@byu.net>
+
+       Fix AC_C_RESTRICT for Sun Studio 12 C++.
+       * lib/autoconf/c.m4 (AC_C_RESTRICT): Newer Sun Studio C provides
+       __restrict__ rather than _Restrict, which still trips up Sun
+       Studio 12 C++.
+       * THANKS: Update.
+       Reported by Rolf Vandevaart.
+
 2009-01-28  Eric Blake  <ebb9@byu.net>
 
        Fix years in copyright notices.
diff --git a/THANKS b/THANKS
index 54310b5f32597ef4bd9416dc1fe174f6bd9799b3..74895cf3679d8c64af66e78a2c8c824f2ac28010 100644 (file)
--- a/THANKS
+++ b/THANKS
@@ -304,6 +304,7 @@ Roberto Bagnara             bagnara@cs.unipr.it
 Roger Leigh                 rleigh@whinlatter.ukfsn.org
 Roland McGrath              roland@gnu.org
 Rolf Ebert                  rolf.ebert.gcc@gmx.de
+Rolf Vandevaart             Rolf.Vandevaart@sun.com
 Romain Lenglet              rlenglet@users.forge.objectweb.org
 Ruediger Kuhlmann           info@ruediger-kuhlmann.de
 Russ Allbery                rra@stanford.edu
index beaf0b151396f0dbb4bfadf8099b06a36cc5e608..3fa9c04a84ab17e606296f197163d1526e39cdac 100644 (file)
@@ -1,7 +1,7 @@
 # This file is part of Autoconf.                       -*- Autoconf -*-
 # Programming languages support.
-# Copyright (C) 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008 Free
-# Software Foundation, Inc.
+# Copyright (C) 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009
+# Free Software Foundation, Inc.
 #
 # This program is free software: you can redistribute it and/or modify
 # it under the terms of the GNU General Public License as published by
@@ -1604,13 +1604,14 @@ AC_DEFUN([AC_C_RESTRICT],
    nothing if this is not supported.  Do not define if restrict is
    supported directly.  */
 #undef restrict
-/* Work around a bug in Sun C++: it does not support _Restrict, even
-   though the corresponding Sun C compiler does, which causes
-   "#define restrict _Restrict" in the previous line.  Perhaps some future
-   version of Sun C++ will work with _Restrict; if so, it'll probably
-   define __RESTRICT, just as Sun C does.  */
+/* Work around a bug in Sun C++: it does not support _Restrict or
+   __restrict__, even though the corresponding Sun C compiler ends up with
+   "#define restrict _Restrict" or "#define restrict __restrict__" in the
+   previous line.  Perhaps some future version of Sun C++ will work with
+   restrict; if so, hopefully it defines __RESTRICT like Sun C does.  */
 #if defined __SUNPRO_CC && !defined __RESTRICT
 # define _Restrict
+# define __restrict__
 #endif])
  case $ac_cv_c_restrict in
    restrict) ;;