Lines Matching defs:SemaRef

93     Sema &SemaRef;
101 UnqualUsingDirectiveSet(Sema &SemaRef) : SemaRef(SemaRef) {}
120 if (SemaRef.isVisible(I))
160 if (SemaRef.isVisible(UD) && visited.insert(NS).second) {
1708 bool LookupResult::isVisibleSlow(Sema &SemaRef, NamedDecl *D) {
1711 Module *DeclModule = SemaRef.getOwningModule(D);
1715 if (SemaRef.isModuleVisible(DeclModule, D->isModulePrivate()))
1748 VisibleWithinParent = SemaRef.hasVisibleDefinition(cast<NamedDecl>(DC));
1750 VisibleWithinParent = isVisible(SemaRef, cast<NamedDecl>(DC));
1752 (isa<FunctionDecl>(DC) && !SemaRef.getLangOpts().CPlusPlus))
1753 VisibleWithinParent = isVisible(SemaRef, cast<NamedDecl>(DC));
1759 if (SemaRef.hasMergedDefinitionInCurrentModule(cast<NamedDecl>(DC))) {
1766 VisibleWithinParent = SemaRef.hasVisibleDefinition(cast<NamedDecl>(DC));
1769 if (VisibleWithinParent && SemaRef.CodeSynthesisContexts.empty() &&
1771 !SemaRef.getLangOpts().ModulesLocalVisibility) {
1864 static NamedDecl *findAcceptableDecl(Sema &SemaRef, NamedDecl *D,
1866 assert(!LookupResult::isVisible(SemaRef, D) && "not in slow case");
1878 LookupResult::isVisible(SemaRef, ND))
3746 void lookupVisibleDecls(Sema &SemaRef, Scope *S, Sema::LookupNameKind Kind,
3751 UnqualUsingDirectiveSet UDirs(SemaRef);
3752 if (SemaRef.getLangOpts().CPlusPlus) {
3762 LookupResult Result(SemaRef, DeclarationName(), SourceLocation(), Kind);
3765 Visited.visitedContext(SemaRef.getASTContext().getTranslationUnitDecl());
3770 void lookupVisibleDecls(Sema &SemaRef, DeclContext *Ctx,
3772 LookupResult Result(SemaRef, DeclarationName(), SourceLocation(), Kind);
3775 Visited.visitedContext(SemaRef.getASTContext().getTranslationUnitDecl());
4124 static void LookupPotentialTypoResult(Sema &SemaRef,
4136 static void checkCorrectionVisibility(Sema &SemaRef, TypoCorrection &TC) {
4140 if (!LookupResult::isVisible(SemaRef, *DI))
4152 if (LookupResult::isVisible(SemaRef, *DI)) {
4228 if (!LookupResult::isVisible(SemaRef, ND) && Name != Typo)
4261 TypoCorrection TC(&SemaRef.Context.Idents.get(Name), ND, NNS, ED);
4282 checkCorrectionVisibility(SemaRef, Correction);
4293 std::string CorrectionStr = Correction.getAsString(SemaRef.getLangOpts());
4301 if (CorrectionStr < RI->getAsString(SemaRef.getLangOpts()))
4330 auto &Types = SemaRef.getASTContext().getTypes();
4377 LookupPotentialTypoResult(SemaRef, Result, Name, S, TempSS, TempMemberContext,
4410 checkCorrectionVisibility(SemaRef, Candidate);
4455 if (!SemaRef.LookupQualifiedName(Result, Ctx))
4464 std::string NewQualified = TC.getAsString(SemaRef.getLangOpts());
4467 SS->getScopeRep()->print(OldOStream, SemaRef.getPrintingPolicy());
4477 if (SemaRef.CheckMemberAccess(TC.getCorrectionRange().getBegin(),
4619 static void LookupPotentialTypoResult(Sema &SemaRef,
4649 SemaRef.LookupQualifiedName(Res, MemberContext);
4653 SemaRef.LookupParsedName(Res, S, SS, /*AllowBuiltinCreation=*/false,
4658 if (ObjCMethodDecl *Method = SemaRef.getCurMethodDecl()) {
4673 static void AddKeywordsToConsumer(Sema &SemaRef,
4702 if (SemaRef.getLangOpts().C99)
4704 if (SemaRef.getLangOpts().Bool || SemaRef.getLangOpts().CPlusPlus)
4706 else if (SemaRef.getLangOpts().C99)
4709 if (SemaRef.getLangOpts().CPlusPlus) {
4714 if (SemaRef.getLangOpts().CPlusPlus11) {
4723 if (SemaRef.getLangOpts().GNUKeywords)
4734 if (CCC.WantCXXNamedCasts && SemaRef.getLangOpts().CPlusPlus) {
4743 if (SemaRef.getLangOpts().Bool || SemaRef.getLangOpts().CPlusPlus) {
4748 if (SemaRef.getLangOpts().CPlusPlus) {
4756 if (isa<CXXMethodDecl>(SemaRef.CurContext) &&
4757 cast<CXXMethodDecl>(SemaRef.CurContext)->isInstance())
4760 if (SemaRef.getLangOpts().CPlusPlus11) {
4766 if (SemaRef.getLangOpts().C11) {
4774 if (SemaRef.getCurFunctionOrMethodDecl() || SemaRef.getCurBlock()) {
4782 if (SemaRef.getLangOpts().CPlusPlus) {
4793 if (SemaRef.getCurFunction() &&
4794 !SemaRef.getCurFunction()->SwitchStack.empty()) {
4799 if (SemaRef.getLangOpts().CPlusPlus) {
4815 if (SemaRef.getLangOpts().CPlusPlus) {
4818 if (SemaRef.getLangOpts().CPlusPlus11)
5224 FunctionCallFilterCCC::FunctionCallFilterCCC(Sema &SemaRef, unsigned NumArgs,
5228 CurContext(SemaRef.CurContext), MemberFn(ME) {
5230 WantFunctionLikeCasts = SemaRef.getLangOpts().CPlusPlus &&