Home
last modified time | relevance | path

Searched refs:CurContext (Results 1 – 25 of 42) sorted by relevance

12

/freebsd-14.2/contrib/llvm-project/clang/lib/Sema/
H A DSemaModule.cpp403 ImportDecl *Import = ImportDecl::Create(Context, CurContext, ModuleLoc, in ActOnModuleDecl()
405 CurContext->addDecl(Import); in ActOnModuleDecl()
559 checkModuleImportContext(*this, Mod, ImportLoc, CurContext); in ActOnModuleImport()
596 ImportDecl *Import = ImportDecl::Create(Context, CurContext, StartLoc, in ActOnModuleImport()
598 CurContext->addDecl(Import); in ActOnModuleImport()
629 checkModuleImportContext(*this, Mod, DirectiveLoc, CurContext, true); in ActOnModuleInclude()
668 checkModuleImportContext(*this, Mod, DirectiveLoc, CurContext, true); in ActOnModuleBegin()
681 for (auto *DC = CurContext; DC; DC = DC->getLexicalParent()) { in ActOnModuleBegin()
722 for (auto *DC = CurContext; DC; DC = DC->getLexicalParent()) { in ActOnModuleEnd()
754 ExportDecl *D = ExportDecl::Create(Context, CurContext, ExportLoc); in ActOnStartExportDecl()
[all …]
H A DSemaCodeComplete.cpp412 if (isa<BlockDecl>(S.CurContext)) { in enterReturn()
1126 MaybeAddResult(Result, CurContext); in MaybeAddResult()
1290 DeclContext *CurContext = SemaRef.CurContext; in canCxxMethodBeCalled() local
4258 if (S.CurContext->isFileContext()) in mapCodeCompletionContext()
4260 if (S.CurContext->isRecord()) in mapCodeCompletionContext()
4309 DeclContext *CurContext = S.CurContext; in MaybeAddOverrideCalls() local
4310 while (isa<BlockDecl>(CurContext)) in MaybeAddOverrideCalls()
4311 CurContext = CurContext->getParent(); in MaybeAddOverrideCalls()
6825 CurContext, nullptr, false); in CodeCompleteNamespaceDecl()
7234 if (isa<ObjCImplDecl>(CurContext)) in CodeCompleteObjCAtDirective()
[all …]
H A DSemaCXXScopeSpec.cpp28 DeclContext *CurContext) { in getCurrentInstantiationOf() argument
36 Record->isCurrentInstantiation(CurContext)) in getCurrentInstantiationOf()
58 return ::getCurrentInstantiationOf(T, CurContext); in computeDeclContext()
206 return ::getCurrentInstantiationOf(T, CurContext); in getCurrentInstantiationOf()
792 DeclContext *DC = LookupCtx ? LookupCtx : CurContext; in BuildCXXNestedNameSpecifier()
1022 if (isa<ObjCContainerDecl>(CurContext) || isa<ObjCMethodDecl>(CurContext)) in ShouldEnterDeclaratorScope()
1047 return CurContext->getRedeclContext()->isFileContext(); in ShouldEnterDeclaratorScope()
H A DSemaDeclCXX.cpp12513 CurContext, in CheckUsingShadowDecl()
12915 CurContext->addDecl(D); in BuildUsingDeclaration()
12925 CurContext->addDecl(UD); in BuildUsingDeclaration()
13119 CurContext->addDecl(UD); in BuildUsingEnumDeclaration()
13151 CurContext->addDecl(UPD); in BuildUsingPackDecl()
16842 CurContext->addDecl(D); in ActOnStartLinkageSpecification()
16879 CurContext->addDecl(ED); in ActOnEmptyDeclaration()
17827 CurContext->addDecl(D); in ActOnFriendTypeDecl()
17943 DC = CurContext; in ActOnFriendFunctionDecl()
17999 DC = CurContext; in ActOnFriendFunctionDecl()
[all …]
H A DSemaOpenMP.cpp1551 DeclContext *DC = SemaRef.CurContext; in buildVarDecl()
3181 CurContext->addDecl(D); in ActOnOpenMPThreadprivateDirective()
3478 if (!CurContext->isFileContext()) { in ActOnOpenMPRequiresDirective()
3483 CurContext->addDecl(D); in ActOnOpenMPRequiresDirective()
3518 auto *Ctx = CurContext; in ActOnOpenMPAssumesDirective()
4627 DSAStack->setContext(CurContext); in ActOnOpenMPRegionStart()
4666 CurContext->addHiddenDecl(CED); in buildCaptureDecl()
18700 CurContext->addDecl(VDPrivate); in ActOnOpenMPFirstprivateClause()
22589 CurContext = DRD; in ActOnOpenMPDeclareReductionCombinerStart()
22649 CurContext = DRD; in ActOnOpenMPDeclareReductionInitializerStart()
[all …]
H A DSemaDecl.cpp1372 CurContext = DC; in PushDeclContext()
1379 CurContext = CurContext->getLexicalParent(); in PopDeclContext()
1398 CurContext = static_cast<decltype(CurContext)>(Context); in ActOnTagFinishSkippedDefinition()
1429 CurContext = DC; in EnterDeclaratorContext()
1506 CurContext = FD; in ActOnReenterFunctionContext()
1507 S->setEntity(CurContext); in ActOnReenterFunctionContext()
1523 CurContext = CurContext->getLexicalParent(); in ActOnExitFunctionContext()
1573 CurContext->addDecl(D); in PushOnScopeChains()
6778 DC = CurContext; in ActOnTypedefDeclarator()
10536 CurContext->isRecord() && CurContext->isDependentContext(); in ActOnFunctionDeclarator()
[all …]
H A DSemaCoroutine.cpp192 auto *FD = dyn_cast<FunctionDecl>(S.CurContext); in isValidCoroutineContext()
194 S.Diag(Loc, isa<ObjCMethodDecl>(S.CurContext) in isValidCoroutineContext()
567 assert(isa<FunctionDecl>(CurContext) && "not in a function scope"); in buildCoroutinePromise()
568 auto *FD = cast<FunctionDecl>(CurContext); in buildCoroutinePromise()
676 assert(isa<FunctionDecl>(S.CurContext) && "not in a function scope"); in checkCoroutineContext()
723 S.Diag(cast<FunctionDecl>(S.CurContext)->getLocation(), in checkNoThrow()
792 auto *Fn = cast<FunctionDecl>(CurContext); in ActOnCoroutineBodyStart()
1947 VarDecl *Decl = VarDecl::Create(S.Context, S.CurContext, Loc, Loc, II, Type, in buildVarDecl()
1956 assert(isa<FunctionDecl>(CurContext) && "not in a function scope"); in buildCoroutineParameterMoves()
1957 auto *FD = cast<FunctionDecl>(CurContext); in buildCoroutineParameterMoves()
H A DSemaDeclObjC.cpp1036 CurContext, in ActOnStartClassInterface()
1799 = ObjCProtocolDecl::Create(Context, CurContext, Ident, in ActOnForwardProtocolDeclaration()
1841 CurContext->addDecl(CDecl); in ActOnStartCategoryInterface()
1889 CurContext->addDecl(CDecl); in ActOnStartCategoryInterface()
1951 CurContext->addDecl(CDecl); in ActOnStartCategoryImplementation()
3821 switch (CurContext->getDeclKind()) { in getObjCContainerKind()
3827 if (cast<ObjCCategoryDecl>(CurContext)->IsClassExtension()) in getObjCContainerKind()
3987 auto *OCD = cast<ObjCContainerDecl>(CurContext); in ActOnAtEnd()
4731 if (!CurContext->isObjCContainer()) { in ActOnMethodDeclaration()
4736 Decl *ClassDecl = cast<ObjCContainerDecl>(CurContext); in ActOnMethodDeclaration()
[all …]
H A DSemaStmt.cpp638 assert(!CurContext->isDependentContext() && in checkMustTailAttr()
704 if (isa<BlockDecl>(CurContext)) in checkMustTailAttr()
706 else if (isa<ObjCMethodDecl>(CurContext)) in checkMustTailAttr()
944 if (CurContext->isFunctionOrMethod()) { in ActOnIfStmt()
2417 SemaRef.CurContext->addHiddenDecl(Decl); in FinishForRangeVarDecl()
2458 DeclContext *DC = SemaRef.CurContext; in BuildForRangeVarDecl()
3643 if (!CurContext->isDependentContext()) in ActOnCapScopeReturnStmt()
4619 DeclContext *DC = CurContext; in ActOnSEHTryBlock()
4699 DeclContext *DC = CurContext; in CreateCapturedStmtRecordDecl()
4787 CurContext = CD; in ActOnCapturedRegionStart()
[all …]
H A DSemaTemplate.cpp1918 SemanticContext = CurContext; in CheckClassTemplate()
2210 CurContext->addDecl(Friend); in CheckClassTemplate()
4814 CurContext->addDecl(Specialization); in ActOnVarTemplateSpecialization()
9188 CurContext->addDecl(Friend); in ActOnClassTemplateSpecialization()
9193 CurContext->addDecl(Specialization); in ActOnClassTemplateSpecialization()
9214 DeclContext *DC = CurContext; in ActOnConceptDefinition()
10054 DeclContext *CurContext = S.CurContext->getRedeclContext(); in CheckExplicitInstantiationScope() local
10056 if (CurContext->isRecord()) { in CheckExplicitInstantiationScope()
10071 if (CurContext->Encloses(OrigContext)) in CheckExplicitInstantiationScope()
10378 CurContext->addDecl(Specialization); in ActOnExplicitInstantiation()
[all …]
H A DSemaLambda.cpp248 DeclContext *DC = CurContext; in createLambdaClosureType()
293 inTemplateInstantiation() || CurContext->isDependentContext(); in getCurrentMangleNumberContext()
330 isInInlineFunction(CurContext)) { in getCurrentMangleNumberContext()
1055 Method->setLexicalDeclContext(CurContext); in ActOnLambdaExpressionAfterIntroducer()
2068 if (!CurContext->isDependentContext() && !IsImplicit && in BuildLambdaExpr()
2193 if (!CurContext->isDependentContext()) { in BuildLambdaExpr()
2251 BlockDecl *Block = BlockDecl::Create(Context, CurContext, ConvLocation); in BuildBlockForLambdaConversion()
H A DSemaLookup.cpp4439 Res = LabelDecl::Create(Context, CurContext, Loc, II, GnuLabelLoc); in LookupOrCreateLabel()
4449 if (Res && Res->getDeclContext() != CurContext) in LookupOrCreateLabel()
4453 Res = LabelDecl::Create(Context, CurContext, Loc, II); in LookupOrCreateLabel()
4866 : Context(Context), CurContextChain(buildContextChain(CurContext)) { in NamespaceSpecifierSet()
5115 if (isa<CXXMethodDecl>(SemaRef.CurContext) && in AddKeywordsToConsumer()
5116 cast<CXXMethodDecl>(SemaRef.CurContext)->isInstance()) in AddKeywordsToConsumer()
5195 if (getLangOpts().MSVCCompat && CurContext->isDependentContext() && in makeTypoCorrectionConsumer()
5196 isa<CXXMethodDecl>(CurContext)) in makeTypoCorrectionConsumer()
5586 CurContext(SemaRef.CurContext), MemberFn(ME) { in FunctionCallFilterCCC()
5622 CurContext->getParentASTContext().getLangOpts().CPlusPlus) in ValidateCandidate()
[all …]
H A DSema.cpp195 CodeCompleter(CodeCompleter), CurContext(nullptr), in Sema()
523 FunctionDecl *fn = dyn_cast<FunctionDecl>(CurContext); in makeUnavailableInSystemHeader()
1482 DeclContext *DC = CurContext; in getFunctionLevelDeclContext()
1632 auto *FD = dyn_cast<FunctionDecl>(CurContext); in hasUncompilableErrorOccurred()
2349 !CurBSI->TheDecl->Encloses(CurContext)) { in getCurBlock()
2373 if (LSI->Lambda && !LSI->Lambda->Encloses(CurContext) && in getEnclosingLambda()
2401 !CurLSI->Lambda->Encloses(CurContext) && CurLSI->AfterParameterList) { in getCurLambda()
H A DSemaAttr.cpp554 !CurContext->getRedeclContext()->isFileContext()) { in ActOnPragmaFloatControl()
791 if (!CurContext->getRedeclContext()->isFileContext()) { in ActOnPragmaMSAllocText()
1147 if (!CurContext->getRedeclContext()->isFileContext()) { in ActOnPragmaMSOptimize()
1157 if (!CurContext->getRedeclContext()->isFileContext()) { in ActOnPragmaMSFunction()
H A DSemaAccess.cpp1483 EffectiveContext EC(S.CurContext); in CheckAccess()
1707 ObjectClass = cast<CXXConstructorDecl>(CurContext)->getParent(); in CheckConstructorAccess()
1841 EffectiveContext EC(CurContext); in CheckFriendAccess()
1954 EffectiveContext EC(CurContext); in IsSimplyAccessible()
H A DSemaExpr.cpp5670 CurContext->addDecl(VD); in ActOnOMPIteratorExpr()
5729 if (!CurContext->isDependentContext()) { in ActOnOMPIteratorExpr()
6294 CallLoc, Param, CurContext}; in BuildCXXDefaultArgExpr()
7110 } else if (S.CurContext->isDependentContext()) { in tryImplicitlyCaptureThisIfImplicitMemberFunctionAccessWithDependentArgs()
13339 DeclContext *DC = CurContext; in CheckCompareOperands()
14163 DeclContext *DC = S.CurContext, *Prev = nullptr; in isReferenceToNonConstCapture()
16954 CurContext->addDecl(Block); in ActOnBlockStart()
16958 CurContext = Block; in ActOnBlockStart()
18854 if (SemaRef.CurContext->isDependentContext()) in isOdrUseContext()
18880 bool IsRecursiveCall = CurContext == Func; in MarkFunctionReferenced()
[all …]
H A DSemaExprCXX.cpp1250 if (!ThisTy.isNull() && isLambdaCallOperator(CurContext)) in getCurrentThisType()
1252 CurContext, Context); in getCurrentThisType()
1425 if (isLambdaCallWithExplicitObjectParameter(CurContext)) in ActOnCXXThis()
7661 FunctionDecl *CurFD = dyn_cast<FunctionDecl>(CurContext); in ActOnStartCXXMemberReference()
8326 assert(S.CurContext->isDependentContext()); in CheckIfAnyEnclosingLambdasMustCaptureAnyPotentialCaptures()
8328 DeclContext *DC = S.CurContext; in CheckIfAnyEnclosingLambdasMustCaptureAnyPotentialCaptures()
8918 DeclContext *DC = CurContext; in ActOnFinishFullExpr()
9044 auto *TParam = TemplateTypeParmDecl::Create(Context, CurContext, in ActOnCompoundRequirement()
9197 assert(CurContext && "DeclContext imbalance!"); in ActOnFinishRequiresExpr()
9198 CurContext = CurContext->getLexicalParent(); in ActOnFinishRequiresExpr()
[all …]
H A DSemaObjCProperty.cpp193 ObjCContainerDecl *ClassDecl = cast<ObjCContainerDecl>(CurContext); in ActOnProperty()
419 ObjCCategoryDecl *CDecl = cast<ObjCCategoryDecl>(CurContext); in HandlePropertyInClassExtension()
421 DeclContext *DC = CurContext; in HandlePropertyInClassExtension()
1086 dyn_cast<ObjCContainerDecl>(CurContext); in ActOnPropertyImplDecl()
1423 ObjCPropertyImplDecl::Create(Context, CurContext, AtLoc, PropertyLoc, in ActOnPropertyImplDecl()
H A DSemaExprMember.cpp1889 auto *CurMethod = dyn_cast<CXXMethodDecl>(CurContext); in BuildFieldReferenceExpr()
1901 !CurContext->isDependentContext() && in BuildFieldReferenceExpr()
H A DSemaTemplateInstantiateDecl.cpp2184 LexicalDC = SemaRef.CurContext; in VisitFunctionDecl()
3317 if (auto *RD = dyn_cast<CXXRecordDecl>(SemaRef.CurContext)) in VisitUsingDecl()
5825 cast<CXXRecordDecl>(CurContext->getParent())); in InstantiateMemInitializers()
6208 Decl *Inst = SubstDecl(D, CurContext, TemplateArgs); in FindInstantiatedDecl()
6217 Decl *Inst = SubstDecl(D, CurContext, TemplateArgs); in FindInstantiatedDecl()
6239 DeclContext *DC = CurContext; in FindInstantiatedDecl()
H A DSemaStmtAsm.cpp131 FunctionDecl *Func = dyn_cast<FunctionDecl>(S.CurContext); in CheckNakedParmReference()
/freebsd-14.2/contrib/llvm-project/clang/lib/AST/
H A DCXXInheritance.cpp117 CXXRecordDecl::isCurrentInstantiation(const DeclContext *CurContext) const { in isCurrentInstantiation()
120 for (; !CurContext->isFileContext(); CurContext = CurContext->getParent()) in isCurrentInstantiation()
121 if (CurContext->Equals(this)) in isCurrentInstantiation()
/freebsd-14.2/contrib/llvm-project/clang/include/clang/Sema/
H A DSemaInternal.h103 Namespaces(SemaRef.Context, SemaRef.CurContext, SS), in TypoCorrectionConsumer()
238 NamespaceSpecifierSet(ASTContext &Context, DeclContext *CurContext,
H A DTypoCorrection.h397 DeclContext *CurContext; variable
/freebsd-14.2/contrib/llvm-project/clang/lib/Interpreter/
H A DIncrementalParser.cpp263 S.CurContext = nullptr; in ParseOrWrapTopLevelDecl()

12