From 82796d3e85a440e74afba3a50ab90779b28836c5 Mon Sep 17 00:00:00 2001 From: David Blaikie Date: Wed, 2 Apr 2014 06:18:49 +0000 Subject: [PATCH] Some more anonymous namespace diagnostics to switch to () git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@205400 91177308-0d34-0410-b5e6-96231b3b80d8 --- test/SemaCXX/dllexport.cpp | 6 +++--- test/SemaCXX/dllimport.cpp | 6 +++--- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/test/SemaCXX/dllexport.cpp b/test/SemaCXX/dllexport.cpp index 0f4cb5c246..3558eef8b8 100644 --- a/test/SemaCXX/dllexport.cpp +++ b/test/SemaCXX/dllexport.cpp @@ -58,7 +58,7 @@ __declspec(dllexport) extern int GlobalRedecl3; // expected-error{{redeclaration // External linkage is required. __declspec(dllexport) static int StaticGlobal; // expected-error{{'StaticGlobal' must have external linkage when declared 'dllexport'}} __declspec(dllexport) Internal InternalTypeGlobal; // expected-error{{'InternalTypeGlobal' must have external linkage when declared 'dllexport'}} -namespace { __declspec(dllexport) int InternalGlobal; } // expected-error{{'::InternalGlobal' must have external linkage when declared 'dllexport'}} +namespace { __declspec(dllexport) int InternalGlobal; } // expected-error{{'(anonymous namespace)::InternalGlobal' must have external linkage when declared 'dllexport'}} namespace ns { __declspec(dllexport) int ExternalGlobal; } __declspec(dllexport) auto InternalAutoTypeGlobal = Internal(); // expected-error{{'InternalAutoTypeGlobal' must have external linkage when declared 'dllexport'}} @@ -127,7 +127,7 @@ __declspec(dllexport) void* operator new(__SIZE_TYPE__ n); // External linkage is required. __declspec(dllexport) static int staticFunc(); // expected-error{{'staticFunc' must have external linkage when declared 'dllexport'}} __declspec(dllexport) Internal internalRetFunc(); // expected-error{{'internalRetFunc' must have external linkage when declared 'dllexport'}} -namespace { __declspec(dllexport) void internalFunc() {} } // expected-error{{'::internalFunc' must have external linkage when declared 'dllexport'}} +namespace { __declspec(dllexport) void internalFunc() {} } // expected-error{{'(anonymous namespace)::internalFunc' must have external linkage when declared 'dllexport'}} namespace ns { __declspec(dllexport) void externalFunc() {} } @@ -166,7 +166,7 @@ template __declspec(dllexport) void funcTmplFriend3() {} // expected // External linkage is required. template __declspec(dllexport) static int staticFuncTmpl(); // expected-error{{'staticFuncTmpl' must have external linkage when declared 'dllexport'}} template __declspec(dllexport) Internal internalRetFuncTmpl(); // expected-error{{'internalRetFuncTmpl' must have external linkage when declared 'dllexport'}} -namespace { template __declspec(dllexport) void internalFuncTmpl(); } // expected-error{{'::internalFuncTmpl' must have external linkage when declared 'dllexport'}} +namespace { template __declspec(dllexport) void internalFuncTmpl(); } // expected-error{{'(anonymous namespace)::internalFuncTmpl' must have external linkage when declared 'dllexport'}} namespace ns { template __declspec(dllexport) void externalFuncTmpl(); } diff --git a/test/SemaCXX/dllimport.cpp b/test/SemaCXX/dllimport.cpp index a96f18b239..95e9e7d053 100644 --- a/test/SemaCXX/dllimport.cpp +++ b/test/SemaCXX/dllimport.cpp @@ -80,7 +80,7 @@ __declspec(dllimport) extern int GlobalRedecl4; // expected-error{{redeclaration // External linkage is required. __declspec(dllimport) static int StaticGlobal; // expected-error{{'StaticGlobal' must have external linkage when declared 'dllimport'}} __declspec(dllimport) Internal InternalTypeGlobal; // expected-error{{'InternalTypeGlobal' must have external linkage when declared 'dllimport'}} -namespace { __declspec(dllimport) int InternalGlobal; } // expected-error{{'::InternalGlobal' must have external linkage when declared 'dllimport'}} +namespace { __declspec(dllimport) int InternalGlobal; } // expected-error{{'(anonymous namespace)::InternalGlobal' must have external linkage when declared 'dllimport'}} namespace ns { __declspec(dllimport) int ExternalGlobal; } __declspec(dllimport) auto InternalAutoTypeGlobal = Internal(); // expected-error{{'InternalAutoTypeGlobal' must have external linkage when declared 'dllimport'}} @@ -158,7 +158,7 @@ __declspec(dllimport) void* operator new(__SIZE_TYPE__ n); // External linkage is required. __declspec(dllimport) static int staticFunc(); // expected-error{{'staticFunc' must have external linkage when declared 'dllimport'}} __declspec(dllimport) Internal internalRetFunc(); // expected-error{{'internalRetFunc' must have external linkage when declared 'dllimport'}} -namespace { __declspec(dllimport) void internalFunc(); } // expected-error{{'::internalFunc' must have external linkage when declared 'dllimport'}} +namespace { __declspec(dllimport) void internalFunc(); } // expected-error{{'(anonymous namespace)::internalFunc' must have external linkage when declared 'dllimport'}} namespace ns { __declspec(dllimport) void externalFunc(); } @@ -199,7 +199,7 @@ template __declspec(dllimport) void funcTmplFriend4(); // expected-e // External linkage is required. template __declspec(dllimport) static int staticFuncTmpl(); // expected-error{{'staticFuncTmpl' must have external linkage when declared 'dllimport'}} template __declspec(dllimport) Internal internalRetFuncTmpl(); // expected-error{{'internalRetFuncTmpl' must have external linkage when declared 'dllimport'}} -namespace { template __declspec(dllimport) void internalFuncTmpl(); } // expected-error{{'::internalFuncTmpl' must have external linkage when declared 'dllimport'}} +namespace { template __declspec(dllimport) void internalFuncTmpl(); } // expected-error{{'(anonymous namespace)::internalFuncTmpl' must have external linkage when declared 'dllimport'}} namespace ns { template __declspec(dllimport) void externalFuncTmpl(); } -- 2.40.0