]> granicus.if.org Git - clang/commitdiff
restrict is not a keyword in gnu89 mode. Change TokenKinds.def to
authorEli Friedman <eli.friedman@gmail.com>
Wed, 27 May 2009 22:48:34 +0000 (22:48 +0000)
committerEli Friedman <eli.friedman@gmail.com>
Wed, 27 May 2009 22:48:34 +0000 (22:48 +0000)
reflect that.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@72500 91177308-0d34-0410-b5e6-96231b3b80d8

include/clang/Basic/TokenKinds.def
test/Sema/gnu89.c [new file with mode: 0644]

index d5575ca99ace1344763d1a847543e72c24c59a4b..9b65288f68e124f94325a5066c62a643307bf7d6 100644 (file)
@@ -203,7 +203,7 @@ KEYWORD(inline                      , KEYC99|KEYCXX|KEYGNU)
 KEYWORD(int                         , KEYALL)
 KEYWORD(long                        , KEYALL)
 KEYWORD(register                    , KEYALL)
-KEYWORD(restrict                    , KEYC99|KEYGNU)
+KEYWORD(restrict                    , KEYC99)
 KEYWORD(return                      , KEYALL)
 KEYWORD(short                       , KEYALL)
 KEYWORD(signed                      , KEYALL)
diff --git a/test/Sema/gnu89.c b/test/Sema/gnu89.c
new file mode 100644 (file)
index 0000000..4601cbe
--- /dev/null
@@ -0,0 +1,3 @@
+// RUN: clang-cc %s -std=gnu89 -pedantic -fsyntax-only -verify
+
+int f(int restrict);