diff options
author | Douglas Gregor <dgregor@apple.com> | 2010-04-15 23:40:53 +0000 |
---|---|---|
committer | Douglas Gregor <dgregor@apple.com> | 2010-04-15 23:40:53 +0000 |
commit | b8eaf2944b83d06b276b587acf86ab1afec2304f (patch) | |
tree | ececcd43a6c6f55bd6680acf328d7633ef2e0cc0 /clang/test/SemaCXX | |
parent | 1d3ee607b35e8509a5cc5b0634ed9ae3a5531b2c (diff) | |
download | bcm5719-llvm-b8eaf2944b83d06b276b587acf86ab1afec2304f.tar.gz bcm5719-llvm-b8eaf2944b83d06b276b587acf86ab1afec2304f.zip |
Audit uses of Sema::LookupSingleName for those lookups that are
intended for redeclarations, fixing those that need it. Fixes PR6831.
This uncovered an issue where the C++ type-specifier-seq parsing logic
would try to perform name lookup on an identifier after it already had
a type-specifier, which could also lead to spurious ambiguity errors
(as in PR6831, but with a different test case).
llvm-svn: 101419
Diffstat (limited to 'clang/test/SemaCXX')
-rw-r--r-- | clang/test/SemaCXX/exceptions.cpp | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/clang/test/SemaCXX/exceptions.cpp b/clang/test/SemaCXX/exceptions.cpp index e009558ce3e..18349d10ef7 100644 --- a/clang/test/SemaCXX/exceptions.cpp +++ b/clang/test/SemaCXX/exceptions.cpp @@ -107,3 +107,16 @@ public: } virtual void test () = 0; // expected-note{{pure virtual function 'test'}} }; + +namespace PR6831 { + namespace NA { struct S; } + namespace NB { struct S; } + + void f() { + using namespace NA; + using namespace NB; + try { + } catch (int S) { + } + } +} |