Some name-lookup-related fixes, from Piotr Rak!

- Changes Lookup*Name functions to return NamedDecls, instead of
Decls. Unfortunately my recent statement that it will simplify lot of
code, was not quite right, but it simplifies some...
- Makes MergeLookupResult SmallPtrSet instead of vector, following
Douglas suggestions.
- Adds %qN format for printing qualified names to Diagnostic.
- Avoids searching for using-directives in Scopes, which are not
DeclScope, during unqualified name lookup.



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@63739 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/lib/Sema/SemaCXXScopeSpec.cpp b/lib/Sema/SemaCXXScopeSpec.cpp
index c77325f..8a257f7 100644
--- a/lib/Sema/SemaCXXScopeSpec.cpp
+++ b/lib/Sema/SemaCXXScopeSpec.cpp
@@ -36,7 +36,7 @@
                                                     SourceLocation IdLoc,

                                                     SourceLocation CCLoc,

                                                     IdentifierInfo &II) {

-  Decl *SD = LookupParsedName(S, &SS, &II, LookupNestedNameSpecifierName);

+  NamedDecl *SD = LookupParsedName(S, &SS, &II, LookupNestedNameSpecifierName);

 

   if (SD) {

     if (TypedefDecl *TD = dyn_cast<TypedefDecl>(SD)) {