diff options
| author | David Majnemer <david.majnemer@gmail.com> | 2014-06-18 23:26:25 +0000 |
|---|---|---|
| committer | David Majnemer <david.majnemer@gmail.com> | 2014-06-18 23:26:25 +0000 |
| commit | 5b63fa02b2fa6e7981706cec53e8d725cbba0752 (patch) | |
| tree | cd8476ba7ce2e8792c7ed6a1c23aa792ccc05237 /clang/test/Sema/tentative-decls.c | |
| parent | 1ad83a35b1d5566bc633437dd17faba8af745627 (diff) | |
| download | bcm5719-llvm-5b63fa02b2fa6e7981706cec53e8d725cbba0752.tar.gz bcm5719-llvm-5b63fa02b2fa6e7981706cec53e8d725cbba0752.zip | |
Sema: Static redeclaration after extern declarations is a Microsoft Extension
CL permits static redeclarations to follow extern declarations. The
storage specifier on the latter declaration has no effect.
This fixes PR20034.
Differential Revision: http://reviews.llvm.org/D4149
llvm-svn: 211238
Diffstat (limited to 'clang/test/Sema/tentative-decls.c')
| -rw-r--r-- | clang/test/Sema/tentative-decls.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/clang/test/Sema/tentative-decls.c b/clang/test/Sema/tentative-decls.c index bf2b1e4ee6a..602624229d7 100644 --- a/clang/test/Sema/tentative-decls.c +++ b/clang/test/Sema/tentative-decls.c @@ -23,7 +23,7 @@ int i1 = 1; // expected-note {{previous definition is here}} int i1 = 2; // expected-error {{redefinition of 'i1'}} int i1; int i1; -extern int i5; // expected-note {{previous definition is here}} +extern int i5; // expected-note {{previous declaration is here}} static int i5; // expected-error{{static declaration of 'i5' follows non-static declaration}} static int i2 = 5; // expected-note 1 {{previous definition is here}} @@ -49,7 +49,7 @@ int redef[]; // expected-note {{previous definition is here}} int redef[11]; // expected-error{{redefinition of 'redef'}} void func() { - extern int i6; // expected-note {{previous definition is here}} + extern int i6; // expected-note {{previous declaration is here}} static int i6; // expected-error{{static declaration of 'i6' follows non-static declaration}} } |

