diff options
author | Douglas Gregor <dgregor@apple.com> | 2010-05-06 23:31:27 +0000 |
---|---|---|
committer | Douglas Gregor <dgregor@apple.com> | 2010-05-06 23:31:27 +0000 |
commit | 4b718ee691f0f168021286f7ee75f52224cb8a1c (patch) | |
tree | d02eabe063d6924b5e861e7065480d9fa514ce81 /clang/test/CXX/dcl.dcl/basic.namespace/namespace.udecl/p8.cpp | |
parent | d8bb3aff76145e391a0df4be7591021d083bc258 (diff) | |
download | bcm5719-llvm-4b718ee691f0f168021286f7ee75f52224cb8a1c.tar.gz bcm5719-llvm-4b718ee691f0f168021286f7ee75f52224cb8a1c.zip |
It turns out that we should be allowing redeclarations within function
scope. Thanks to Steven Watanabe for correcting me.
llvm-svn: 103210
Diffstat (limited to 'clang/test/CXX/dcl.dcl/basic.namespace/namespace.udecl/p8.cpp')
-rw-r--r-- | clang/test/CXX/dcl.dcl/basic.namespace/namespace.udecl/p8.cpp | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/clang/test/CXX/dcl.dcl/basic.namespace/namespace.udecl/p8.cpp b/clang/test/CXX/dcl.dcl/basic.namespace/namespace.udecl/p8.cpp index fd2df010fc9..466097171c8 100644 --- a/clang/test/CXX/dcl.dcl/basic.namespace/namespace.udecl/p8.cpp +++ b/clang/test/CXX/dcl.dcl/basic.namespace/namespace.udecl/p8.cpp @@ -81,3 +81,18 @@ namespace test2 { template struct Derived<int>; // expected-note {{in instantiation of template class}} } + +// Redeclarations are okay in a function. +namespace test3 { + namespace N { + int f(int); + typedef int type; + } + + void g() { + using N::f; + using N::f; + using N::type; + using N::type; + } +} |