Lines Matching refs:Context

128   return &Context.Idents.get(OS.str());  in InventAbbreviatedTemplateParameterTypeName()
131 PrintingPolicy Sema::getPrintingPolicy(const ASTContext &Context, in getPrintingPolicy() argument
133 PrintingPolicy Policy = Context.getPrintingPolicy(); in getPrintingPolicy()
136 Policy.Bool = Context.getLangOpts().Bool; in getPrintingPolicy()
138 if (const MacroInfo *BoolMacro = PP.getMacroInfo(Context.getBoolName())) { in getPrintingPolicy()
153 PushDeclContext(S, Context.getTranslationUnitDecl()); in ActOnTranslationUnitScope()
218 Context(ctxt), Consumer(consumer), Diags(PP.getDiagnostics()), in Sema()
267 ArgumentPackSubstitutionIndex(-1), SatisfactionCache(Context) { in Sema()
276 ObjC().NSAPIObj.reset(new NSAPI(Context)); in Sema()
282 Diags.SetArgToStringFn(&FormatASTNodeDiagnosticArgument, &Context); in Sema()
307 DeclarationName DN = &Context.Idents.get(Name); in addImplicitTypedef()
309 PushOnScopeChains(Context.buildImplicitTypedef(T, Name), TUScope); in addImplicitTypedef()
318 = dyn_cast_or_null<ExternalSemaSource>(Context.getExternalSource())) in Initialize()
329 if (Context.getTargetInfo().hasInt128Type() || in Initialize()
330 (Context.getAuxTargetInfo() && in Initialize()
331 Context.getAuxTargetInfo()->hasInt128Type())) { in Initialize()
334 DeclarationName Int128 = &Context.Idents.get("__int128_t"); in Initialize()
336 PushOnScopeChains(Context.getInt128Decl(), TUScope); in Initialize()
338 DeclarationName UInt128 = &Context.Idents.get("__uint128_t"); in Initialize()
340 PushOnScopeChains(Context.getUInt128Decl(), TUScope); in Initialize()
348 DeclarationName SEL = &Context.Idents.get("SEL"); in Initialize()
350 PushOnScopeChains(Context.getObjCSelDecl(), TUScope); in Initialize()
354 DeclarationName Id = &Context.Idents.get("id"); in Initialize()
356 PushOnScopeChains(Context.getObjCIdDecl(), TUScope); in Initialize()
359 DeclarationName Class = &Context.Idents.get("Class"); in Initialize()
361 PushOnScopeChains(Context.getObjCClassDecl(), TUScope); in Initialize()
364 DeclarationName Protocol = &Context.Idents.get("Protocol"); in Initialize()
366 PushOnScopeChains(Context.getObjCProtocolDecl(), TUScope); in Initialize()
370 DeclarationName ConstantString = &Context.Idents.get("__NSConstantString"); in Initialize()
372 PushOnScopeChains(Context.getCFConstantStringDecl(), TUScope); in Initialize()
377 IdResolver.begin(&Context.Idents.get("type_info")) == IdResolver.end()) in Initialize()
379 Context.buildImplicitRecord("type_info", TagTypeKind::Class), in Initialize()
382 addImplicitTypedef("size_t", Context.getSizeType()); in Initialize()
389 Context.getTargetInfo().getSupportedOpenCLOpts(), getLangOpts()); in Initialize()
390 addImplicitTypedef("sampler_t", Context.OCLSamplerTy); in Initialize()
391 addImplicitTypedef("event_t", Context.OCLEventTy); in Initialize()
395 addImplicitTypedef("clk_event_t", Context.OCLClkEventTy); in Initialize()
396 addImplicitTypedef("queue_t", Context.OCLQueueTy); in Initialize()
399 addImplicitTypedef("reserve_id_t", Context.OCLReserveIDTy); in Initialize()
400 addImplicitTypedef("atomic_int", Context.getAtomicType(Context.IntTy)); in Initialize()
402 Context.getAtomicType(Context.UnsignedIntTy)); in Initialize()
404 Context.getAtomicType(Context.FloatTy)); in Initialize()
407 addImplicitTypedef("atomic_flag", Context.getAtomicType(Context.IntTy)); in Initialize()
423 auto AtomicSizeT = Context.getAtomicType(Context.getSizeType()); in Initialize()
424 auto AtomicIntPtrT = Context.getAtomicType(Context.getIntPtrType()); in Initialize()
425 auto AtomicUIntPtrT = Context.getAtomicType(Context.getUIntPtrType()); in Initialize()
427 Context.getAtomicType(Context.getPointerDiffType()); in Initialize()
434 if (Context.getTypeSize(Context.getSizeType()) == 32) { in Initialize()
439 auto AtomicHalfT = Context.getAtomicType(Context.HalfTy); in Initialize()
449 auto AtomicDoubleT = Context.getAtomicType(Context.DoubleTy); in Initialize()
453 auto AtomicLongT = Context.getAtomicType(Context.LongTy); in Initialize()
454 auto AtomicULongT = Context.getAtomicType(Context.UnsignedLongTy); in Initialize()
459 if (Context.getTypeSize(Context.getSizeType()) == 64) { in Initialize()
467 addImplicitTypedef(#ExtType, Context.Id##Ty); \ in Initialize()
472 if (Context.getTargetInfo().hasAArch64SVETypes() || in Initialize()
473 (Context.getAuxTargetInfo() && in Initialize()
474 Context.getAuxTargetInfo()->hasAArch64SVETypes())) { in Initialize()
476 addImplicitTypedef(Name, Context.SingletonId); in Initialize()
480 if (Context.getTargetInfo().getTriple().isPPC64()) { in Initialize()
482 addImplicitTypedef(#Name, Context.Id##Ty); in Initialize()
485 addImplicitTypedef(#Name, Context.Id##Ty); in Initialize()
489 if (Context.getTargetInfo().hasRISCVVTypes()) { in Initialize()
491 addImplicitTypedef(Name, Context.SingletonId); in Initialize()
495 if (Context.getTargetInfo().getTriple().isWasm() && in Initialize()
496 Context.getTargetInfo().hasFeature("reference-types")) { in Initialize()
498 addImplicitTypedef(Name, Context.SingletonId); in Initialize()
502 if (Context.getTargetInfo().getTriple().isAMDGPU() || in Initialize()
503 (Context.getAuxTargetInfo() && in Initialize()
504 Context.getAuxTargetInfo()->getTriple().isAMDGPU())) { in Initialize()
506 addImplicitTypedef(Name, Context.SingletonId); in Initialize()
510 if (Context.getTargetInfo().hasBuiltinMSVaList()) { in Initialize()
511 DeclarationName MSVaList = &Context.Idents.get("__builtin_ms_va_list"); in Initialize()
513 PushOnScopeChains(Context.getBuiltinMSVaListDecl(), TUScope); in Initialize()
516 DeclarationName BuiltinVaList = &Context.Idents.get("__builtin_va_list"); in Initialize()
518 PushOnScopeChains(Context.getBuiltinVaListDecl(), TUScope); in Initialize()
537 = dyn_cast_or_null<ExternalSemaSource>(Context.getExternalSource())) in ~Sema()
582 if (!Context.getSourceManager().isInSystemHeader(loc)) in makeUnavailableInSystemHeader()
588 fn->addAttr(UnavailableAttr::CreateImplicit(Context, "", reason, loc)); in makeUnavailableInSystemHeader()
723 if (Context.hasAnyFunctionEffects() && !isCast(CCK) && in ImpCastExprToType()
727 QualType ExprTy = Context.getCanonicalType(E->getType()); in ImpCastExprToType()
728 QualType TypeTy = Context.getCanonicalType(Ty); in ImpCastExprToType()
773 return ImplicitCastExpr::Create(Context, Ty, Kind, E, BasePath, VK, in ImpCastExprToType()
829 VD->mightBeUsableInConstantExpressions(SemaRef->Context)) in ShouldRemoveFromUnused()
1372 = Context.getAsIncompleteArrayType(VD->getType())) { in ActOnEndOfTranslationUnit()
1375 llvm::APInt One(Context.getTypeSize(Context.getSizeType()), true); in ActOnEndOfTranslationUnit()
1376 QualType T = Context.getConstantArrayType( in ActOnEndOfTranslationUnit()
1510 AnalysisWarnings.IssueWarnings(Context.getTranslationUnitDecl()); in ActOnEndOfTranslationUnit()
1597 PartialDiagnostic(DiagInfo, Context.getDiagAllocator())); in EmitCurrentDiagnostic()
1622 PartialDiagnostic(DiagInfo, Context.getDiagAllocator())); in EmitCurrentDiagnostic()
1644 PartialDiagnostic(DiagInfo, Context.getDiagAllocator())); in EmitCurrentDiagnostic()
1656 Context.setPrintingPolicy(getPrintingPolicy()); in EmitCurrentDiagnostic()
2002 if (!Context.getTargetInfo().hasBitIntType()) { in checkTypeSupport()
2010 << Ty << Context.getTargetInfo().getTriple().str(); in checkTypeSupport()
2018 if (Ty->isRealFloatingType() && Context.getTypeSize(Ty) == 128) { in checkTypeSupport()
2019 const llvm::fltSemantics &Sem = Context.getFloatTypeSemantics(Ty); in checkTypeSupport()
2021 !Context.getTargetInfo().hasFloat128Type()) || in checkTypeSupport()
2023 !Context.getTargetInfo().hasIbm128Type())) in checkTypeSupport()
2027 if ((Ty->isFloat16Type() && !Context.getTargetInfo().hasFloat16Type()) || in checkTypeSupport()
2028 (Ty->isFloat128Type() && !Context.getTargetInfo().hasFloat128Type()) || in checkTypeSupport()
2029 (Ty->isIbm128Type() && !Context.getTargetInfo().hasIbm128Type()) || in checkTypeSupport()
2030 (Ty->isIntegerType() && Context.getTypeSize(Ty) == 128 && in checkTypeSupport()
2031 !Context.getTargetInfo().hasInt128Type()) || in checkTypeSupport()
2032 (Ty->isBFloat16Type() && !Context.getTargetInfo().hasBFloat16Type() && in checkTypeSupport()
2043 << static_cast<unsigned>(Context.getTypeSize(Ty)) << Ty in checkTypeSupport()
2044 << false /*return*/ << Context.getTargetInfo().getTriple().str()) { in checkTypeSupport()
2060 const TargetInfo &TI = Context.getTargetInfo(); in checkTypeSupport()
2061 if (!TI.hasLongDoubleType() && UnqualTy == Context.LongDoubleTy) { in checkTypeSupport()
2078 bool IsDouble = UnqualTy == Context.DoubleTy; in checkTypeSupport()
2079 bool IsFloat = UnqualTy == Context.FloatTy; in checkTypeSupport()
2099 Context.getFunctionFeatureMap(CallerFeatureMap, FD); in checkTypeSupport()
2106 Context.getFunctionFeatureMap(CallerFeatureMap, FD); in checkTypeSupport()
2209 new (S.Context) DeclRefExpr(S.Context, VD, false, T, VK_LValue, Loc); in checkEscapingByref()
2213 auto *E = ImplicitCastExpr::Create(S.Context, T, CK_NoOp, VarRef, nullptr, in checkEscapingByref()
2225 S.Context.setBlockVarCopyInit(VD, Init, S.canThrow(Init)); in checkEscapingByref()
2451 Context.addComment(RC); in ActOnComment()
2478 if (E.getType() == Context.OverloadTy) { in tryExprAsCall()
2486 } else if (E.getType() == Context.BoundMemberTy) { in tryExprAsCall()
2700 Ident_super = &Context.Idents.get("super"); in getSuperIdentifier()
2713 CSI->ReturnType = Context.VoidTy; in PushCapturedRegionScope()