diff --git a/clang/lib/Sema/SemaCXXScopeSpec.cpp b/clang/lib/Sema/SemaCXXScopeSpec.cpp index 8a74cd64be15d..f8e79c21766f4 100644 --- a/clang/lib/Sema/SemaCXXScopeSpec.cpp +++ b/clang/lib/Sema/SemaCXXScopeSpec.cpp @@ -685,16 +685,6 @@ bool Sema::BuildCXXNestedNameSpecifier(Scope *S, NestedNameSpecInfo &IdInfo, if (ErrorRecoveryLookup) return true; -#if 0 - // If we didn't find anything during our lookup, try again with - // ordinary name lookup, which can help us produce better error - // messages. - if (Found.empty()) { - Found.clear(LookupOrdinaryName); - LookupName(Found, S); - } -#endif - // In Microsoft mode, if we are within a templated function and we can't // resolve Identifier, then extend the SS with Identifier. This will have // the effect of resolving Identifier during template instantiation. @@ -735,7 +725,6 @@ bool Sema::BuildCXXNestedNameSpecifier(Scope *S, NestedNameSpecInfo &IdInfo, } } -#if 1 if (!Found.empty()) { if (TypeDecl *TD = Found.getAsSingle()) { Diag(IdInfo.IdentifierLoc, diag::err_expected_class_or_namespace) @@ -757,7 +746,6 @@ bool Sema::BuildCXXNestedNameSpecifier(Scope *S, NestedNameSpecInfo &IdInfo, else Diag(IdInfo.IdentifierLoc, diag::err_undeclared_var_use) << IdInfo.Identifier; -#endif return true; }