Lines Matching refs:ND
1334 if (NamedDecl *ND = R.getAcceptableDecl(*I)) { in CppLookupName() local
1356 R.addDecl(ND); in CppLookupName()
1398 if (NamedDecl *ND = R.getAcceptableDecl(Ivar)) { in CppLookupName() local
1399 R.addDecl(ND); in CppLookupName()
1487 if (NamedDecl *ND = R.getAcceptableDecl(*I)) { in CppLookupName() local
1493 R.addDecl(ND); in CppLookupName()
1541 void Sema::makeMergedDefinitionVisible(NamedDecl *ND) { in makeMergedDefinitionVisible() argument
1543 Context.mergeDefinitionIntoModule(ND, M); in makeMergedDefinitionVisible()
1546 ND->setVisibleDespiteOwningModule(); in makeMergedDefinitionVisible()
1550 if (auto *TD = dyn_cast<TemplateDecl>(ND)) in makeMergedDefinitionVisible()
2048 auto ND = cast<NamedDecl>(RD); in findAcceptableDecl() local
2052 if (ND->isInIdentifierNamespace(IDNS) && in findAcceptableDecl()
2053 LookupResult::isAvailableForLookup(SemaRef, ND)) in findAcceptableDecl()
2054 return ND; in findAcceptableDecl()
2077 if (auto *ND = dyn_cast<NamespaceDecl>(D)) { in getAcceptableDeclSlow() local
2084 auto *Key = ND->getCanonicalDecl(); in getAcceptableDeclSlow()
2115 bool LookupResult::isAvailableForLookup(Sema &SemaRef, NamedDecl *ND) { in isAvailableForLookup() argument
2117 if (isVisible(SemaRef, ND)) in isAvailableForLookup()
2124 if (auto *DeductionGuide = ND->getDeclName().getCXXDeductionGuideTemplate()) in isAvailableForLookup()
2139 if (auto *FD = dyn_cast<FunctionDecl>(ND); in isAvailableForLookup()
2143 auto *DC = ND->getDeclContext(); in isAvailableForLookup()
2328 NamespaceDecl *ND = I->getNominatedNamespace()->getFirstDecl(); in LookupQualifiedNameInUsingDirectives() local
2329 if (S.isVisible(I) && Visited.insert(ND).second) in LookupQualifiedNameInUsingDirectives()
2330 Queue.push_back(ND); in LookupQualifiedNameInUsingDirectives()
2344 NamespaceDecl *ND = Queue.pop_back_val(); in LookupQualifiedNameInUsingDirectives() local
2350 bool FoundDirect = LookupDirect(S, DirectR, ND); in LookupQualifiedNameInUsingDirectives()
2375 for (auto *I : ND->using_directives()) { in LookupQualifiedNameInUsingDirectives()
2541 NamedDecl *ND = *It++; in LookupQualifiedName() local
2542 if (!ND->isInIdentifierNamespace(IDNS)) in LookupQualifiedName()
2554 if (auto *TD = getAsTemplateNameDecl(ND)) in LookupQualifiedName()
2555 ND = TD; in LookupQualifiedName()
2560 if (const TypeDecl *TD = dyn_cast<TypeDecl>(ND->getUnderlyingDecl())) { in LookupQualifiedName()
2565 return ND->getUnderlyingDecl()->getCanonicalDecl(); in LookupQualifiedName()
2659 if (NamedDecl *ND = R.getAcceptableDecl(*I)) in LookupQualifiedName() local
2660 R.addDecl(ND, AS); in LookupQualifiedName()
3942 NamedDecl *checkHidden(NamedDecl *ND);
3945 void add(NamedDecl *ND) { in add() argument
3946 ShadowMaps.back()[ND->getDeclName()].push_back(ND); in add()
3968 NamedDecl *VisibleDeclsRecord::checkHidden(NamedDecl *ND) { in checkHidden() argument
3969 unsigned IDNS = ND->getIdentifierNamespace(); in checkHidden()
3973 ShadowMap::iterator Pos = SM->find(ND->getDeclName()); in checkHidden()
3994 ND->getUnderlyingDecl()->isFunctionOrFunctionTemplate() && in checkHidden()
4000 if (isa<UsingShadowDecl>(ND) && isa<UsingDecl>(D) && in checkHidden()
4001 cast<UsingShadowDecl>(ND)->getIntroducer() == D) in checkHidden()
4090 if (NamedDecl *ND = Result.getAcceptableDecl(*I)) { in lookupInDeclContext() local
4091 Consumer.FoundDecl(ND, Visited.checkHidden(ND), Ctx, InBaseClass); in lookupInDeclContext()
4092 Visited.add(ND); in lookupInDeclContext()
4121 if (auto *ND = Result.getAcceptableDecl(D)) { in lookupInDeclContext() local
4122 Consumer.FoundDecl(ND, Visited.checkHidden(ND), Ctx, InBaseClass); in lookupInDeclContext()
4123 Visited.add(ND); in lookupInDeclContext()
4265 if (NamedDecl *ND = dyn_cast<NamedDecl>(D)) in lookupInScope() local
4266 if ((ND = Result.getAcceptableDecl(ND))) { in lookupInScope()
4267 Consumer.FoundDecl(ND, Visited.checkHidden(ND), nullptr, false); in lookupInScope()
4268 Visited.add(ND); in lookupInScope()
4491 void TypoCorrectionConsumer::FoundDecl(NamedDecl *ND, NamedDecl *Hiding, in FoundDecl() argument
4500 IdentifierInfo *Name = ND->getIdentifier(); in FoundDecl()
4506 if (!LookupResult::isVisible(SemaRef, ND) && Name != Typo) in FoundDecl()
4524 void TypoCorrectionConsumer::addName(StringRef Name, NamedDecl *ND, in addName() argument
4539 TypoCorrection TC(&SemaRef.Context.Idents.get(Name), ND, NNS, ED); in addName()
4809 if (auto *ND = dyn_cast_or_null<NamespaceDecl>(C)) in NamespaceSpecifierSet() local
4810 CurContextIdentifiers.push_back(ND->getIdentifier()); in NamespaceSpecifierSet()
4825 NamespaceDecl *ND = dyn_cast_or_null<NamespaceDecl>(DC); in buildContextChain() local
4827 !(ND && ND->isAnonymousNamespace())) in buildContextChain()
4838 if (auto *ND = dyn_cast_or_null<NamespaceDecl>(C)) { in buildNestedNameSpecifier() local
4839 NNS = NestedNameSpecifier::Create(Context, NNS, ND); in buildNestedNameSpecifier()
4873 } else if (NamedDecl *ND = in addNameSpecifier() local
4875 IdentifierInfo *Name = ND->getIdentifier(); in addNameSpecifier()
5466 NamedDecl *ND = C->getUnderlyingDecl(); in ValidateCandidate() local
5467 if (FunctionTemplateDecl *FTD = dyn_cast<FunctionTemplateDecl>(ND)) in ValidateCandidate()
5470 if (!(FD = dyn_cast<FunctionDecl>(ND)) && isa<ValueDecl>(ND)) { in ValidateCandidate()
5474 QualType ValType = cast<ValueDecl>(ND)->getType(); in ValidateCandidate()
5486 if ((HasExplicitTemplateArgs ? getAsTypeTemplateDecl(ND) != nullptr in ValidateCandidate()
5487 : isa<TypeDecl>(ND)) && in ValidateCandidate()
5490 return NumArgs <= 1 || HasExplicitTemplateArgs || isa<CXXRecordDecl>(ND); in ValidateCandidate()