diff options
author | Douglas Gregor <dgregor@apple.com> | 2009-12-08 15:38:36 +0000 |
---|---|---|
committer | Douglas Gregor <dgregor@apple.com> | 2009-12-08 15:38:36 +0000 |
commit | a64c1e5452dea9d227276c21e5457ccd30a202c1 (patch) | |
tree | 98e3f70601b680795c005d0484e994fdf1370e3b /clang/test/SemaCXX/using-directive.cpp | |
parent | 24c0bb1ca1e9476cc98d79fb7ce06ca6710b63e6 (diff) | |
download | bcm5719-llvm-a64c1e5452dea9d227276c21e5457ccd30a202c1.tar.gz bcm5719-llvm-a64c1e5452dea9d227276c21e5457ccd30a202c1.zip |
When performing unqualified name lookup in C++, don't look directly
into transparent contexts; instead, we'll look into their nearest
enclosing non-transparent contexts further up the stack. Fixes PR5479.
llvm-svn: 90859
Diffstat (limited to 'clang/test/SemaCXX/using-directive.cpp')
-rw-r--r-- | clang/test/SemaCXX/using-directive.cpp | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/clang/test/SemaCXX/using-directive.cpp b/clang/test/SemaCXX/using-directive.cpp index 51f347dc7a7..b7583f27cb6 100644 --- a/clang/test/SemaCXX/using-directive.cpp +++ b/clang/test/SemaCXX/using-directive.cpp @@ -112,3 +112,12 @@ using namespace Alias; void testAlias() { inAliased(); } + +namespace N { void f2(int); } + +extern "C++" { + using namespace N; + void f3() { f2(1); } +} + +void f4() { f2(1); } |