summaryrefslogtreecommitdiffstats
path: root/clang/test/Modules/cxx-lookup.cpp
diff options
context:
space:
mode:
authorRichard Smith <richard-llvm@metafoo.co.uk>2015-02-10 03:28:10 +0000
committerRichard Smith <richard-llvm@metafoo.co.uk>2015-02-10 03:28:10 +0000
commite8292b10a61adc03a8c0a3be47d3e39e0aa29b64 (patch)
tree223e8c3ae1aaa04b6f8c33b8d3940a1406a5533a /clang/test/Modules/cxx-lookup.cpp
parentc11b101fb64c621e6bc1a36904bc775ce6202beb (diff)
downloadbcm5719-llvm-e8292b10a61adc03a8c0a3be47d3e39e0aa29b64.tar.gz
bcm5719-llvm-e8292b10a61adc03a8c0a3be47d3e39e0aa29b64.zip
[modules] When determining whether a name from a module replaces a name we
already have, check whether the name from the module is actually newer than the existing declaration. If it isn't, we might (say) replace a visible declaration with an injected friend, and thus make it invisible (or lose a default argument or an array bound). llvm-svn: 228661
Diffstat (limited to 'clang/test/Modules/cxx-lookup.cpp')
-rw-r--r--clang/test/Modules/cxx-lookup.cpp5
1 files changed, 5 insertions, 0 deletions
diff --git a/clang/test/Modules/cxx-lookup.cpp b/clang/test/Modules/cxx-lookup.cpp
index 47c879dbb63..bd019c7f4ae 100644
--- a/clang/test/Modules/cxx-lookup.cpp
+++ b/clang/test/Modules/cxx-lookup.cpp
@@ -4,3 +4,8 @@
namespace llvm {}
#include "c2.h"
llvm::GlobalValue *p;
+
+#include "na.h"
+namespace N { struct foo; }
+#include "nb.h"
+N::foo *use_n_foo;
OpenPOWER on IntegriCloud