Lines Matching refs:Context
68 ASTContext *Context; member in __anonc09f721f0111::RewriteModernObjC
268 Diags.Report(Context->getFullLoc(Old->getBeginLoc()), RewriteFailedDiag) in ReplaceStmtWithRange()
284 Diags.Report(Context->getFullLoc(Old->getBeginLoc()), RewriteFailedDiag) in ReplaceStmtWithRange()
295 Diags.Report(Context->getFullLoc(Loc), RewriteFailedDiag); in InsertText()
305 Diags.Report(Context->getFullLoc(Start), RewriteFailedDiag); in ReplaceText()
509 T = Context->getPointerType(BPT->getPointeeType()); in convertBlockPointerToFunctionPointer()
525 T = isConst ? Context->getObjCIdType().withConst() in convertToUnqualifiedObjCType()
526 : Context->getObjCIdType(); in convertToUnqualifiedObjCType()
529 T = Context->getObjCClassType(); in convertToUnqualifiedObjCType()
536 T = Context->getPointerType(T); in convertToUnqualifiedObjCType()
546 QualType OCT = Context->getCanonicalType(T).getUnqualifiedType(); in isObjCType()
548 if (OCT == Context->getCanonicalType(Context->getObjCIdType()) || in isObjCType()
549 OCT == Context->getCanonicalType(Context->getObjCClassType())) in isObjCType()
577 if (result == Context->getObjCInstanceType()) in getSimpleFunctionType()
578 result = Context->getObjCIdType(); in getSimpleFunctionType()
581 return Context->getFunctionType(result, args, fpi); in getSimpleFunctionType()
594 const IdentifierInfo *II = &Context->Idents.get("load"); in ImplementationIsNonLazy()
595 Selector LoadSel = Context->Selectors.getSelector(0, &II); in ImplementationIsNonLazy()
600 QualType StrType = Context->getConstantArrayType( in getStringLiteral()
601 Context->CharTy, llvm::APInt(32, Str.size() + 1), nullptr, in getStringLiteral()
603 return StringLiteral::Create(*Context, Str, StringLiteralKind::Ordinary, in getStringLiteral()
673 Context = &context; in InitializeCommon()
674 SM = &Context->getSourceManager(); in InitializeCommon()
675 TUDecl = Context->getTranslationUnitDecl(); in InitializeCommon()
709 Rewrite.setSourceMgr(Context->getSourceManager(), Context->getLangOpts()); in InitializeCommon()
866 RecordDecl *RD = RecordDecl::Create(*Context, TagTypeKind::Struct, TUDecl, in getIvarAccessString()
868 &Context->Idents.get(RecName)); in getIvarAccessString()
869 QualType PtrStructIMPL = Context->getPointerType(Context->getTagDeclType(RD)); in getIvarAccessString()
871 static_cast<unsigned>(Context->getTypeSize(Context->UnsignedIntTy)); in getIvarAccessString()
872 Expr *Zero = IntegerLiteral::Create(*Context, in getIvarAccessString()
874 Context->UnsignedIntTy, SourceLocation()); in getIvarAccessString()
875 Zero = NoTypeInfoCStyleCastExpr(Context, PtrStructIMPL, CK_BitCast, Zero); in getIvarAccessString()
876 ParenExpr *PE = new (Context) ParenExpr(SourceLocation(), SourceLocation(), in getIvarAccessString()
878 FieldDecl *FD = FieldDecl::Create(*Context, nullptr, SourceLocation(), in getIvarAccessString()
880 &Context->Idents.get(D->getNameAsString()), in getIvarAccessString()
885 *Context, PE, true, FD, FD->getType(), VK_LValue, OK_Ordinary); in getIvarAccessString()
886 IvarT = Context->getDecltypeType(ME, ME->getType()); in getIvarAccessString()
890 QualType castT = Context->getPointerType(IvarT); in getIvarAccessString()
891 std::string TypeString(castT.getAsString(Context->getPrintingPolicy())); in getIvarAccessString()
977 FT->getParamType(i).getAsString(Context->getPrintingPolicy()); in RewritePropertyImplDecl()
1222 FPRetType->getReturnType().getAsString(Context->getPrintingPolicy()); in RewriteTypeIntoString()
1226 ResultStr += T.getAsString(Context->getPrintingPolicy()); in RewriteTypeIntoString()
1272 QualType selfTy = Context->getObjCInterfaceType(IDecl); in RewriteObjCMethodDecl()
1273 selfTy = Context->getPointerType(selfTy); in RewriteObjCMethodDecl()
1283 ResultStr += Context->getObjCClassType().getAsString( in RewriteObjCMethodDecl()
1284 Context->getPrintingPolicy()); in RewriteObjCMethodDecl()
1287 ResultStr += Context->getObjCSelType().getAsString(Context->getPrintingPolicy()); in RewriteObjCMethodDecl()
1301 QT.getAsStringInternal(Name, Context->getPrintingPolicy()); in RewriteObjCMethodDecl()
1318 FT->getParamType(i).getAsString(Context->getPrintingPolicy()); in RewriteObjCMethodDecl()
1455 NewMsg = ObjCMessageExpr::Create(*Context, OldMsg->getType(), in RewritePropertyOrImplicitSetter()
1468 NewMsg = ObjCMessageExpr::Create(*Context, OldMsg->getType(), in RewritePropertyOrImplicitSetter()
1482 NewMsg = ObjCMessageExpr::Create(*Context, OldMsg->getType(), in RewritePropertyOrImplicitSetter()
1538 NewMsg = ObjCMessageExpr::Create(*Context, OldMsg->getType(), in RewritePropertyOrImplicitGetter()
1551 NewMsg = ObjCMessageExpr::Create(*Context, OldMsg->getType(), in RewritePropertyOrImplicitGetter()
1565 NewMsg = ObjCMessageExpr::Create(*Context, OldMsg->getType(), in RewritePropertyOrImplicitGetter()
1710 elementTypeAsString = ElementType.getAsString(Context->getPrintingPolicy()); in RewriteObjCForCollectionStmt()
1726 elementTypeAsString = VD->getType().getAsString(Context->getPrintingPolicy()); in RewriteObjCForCollectionStmt()
1921 Diags.Report(Context->getFullLoc(S->getBeginLoc()), in WarnAboutReturnGotoStmts()
2071 Context->getObjCEncodingForType(Exp->getEncodedType(), StrEncoding); in RewriteAtEncode()
2103 DeclRefExpr *DRE = new (Context) DeclRefExpr(*Context, FD, false, msgSendType, in SynthesizeCallToFunctionDecl()
2107 QualType pToFunc = Context->getPointerType(msgSendType); in SynthesizeCallToFunctionDecl()
2109 ImplicitCastExpr::Create(*Context, pToFunc, CK_FunctionToPointerDecay, in SynthesizeCallToFunctionDecl()
2114 CallExpr::Create(*Context, ICE, Args, FT->getCallResultType(*Context), in SynthesizeCallToFunctionDecl()
2160 QualType ElemTy = Context->getBaseElementType(T); in needToScanForQualifiers()
2290 std::string TypeAsString(QT.getAsString(Context->getPrintingPolicy())); in RewriteTypeOfDecl()
2316 IdentifierInfo *SelGetUidIdent = &Context->Idents.get("sel_registerName"); in SynthSelGetUidFunctionDecl()
2318 ArgTys.push_back(Context->getPointerType(Context->CharTy.withConst())); in SynthSelGetUidFunctionDecl()
2320 getSimpleFunctionType(Context->getObjCSelType(), ArgTys); in SynthSelGetUidFunctionDecl()
2321 SelGetUidFunctionDecl = FunctionDecl::Create(*Context, TUDecl, in SynthSelGetUidFunctionDecl()
2339 std::string TypeString(Type.getAsString(Context->getPrintingPolicy())); in RewriteBlockPointerType()
2355 std::string TypeString(Type.getAsString(Context->getPrintingPolicy())); in RewriteBlockPointerTypeVariable()
2388 std::string FdStr = Type.getAsString(Context->getPrintingPolicy()); in RewriteBlockLiteralFunctionDecl()
2411 IdentifierInfo *msgSendIdent = &Context->Idents.get("__rw_objc_super"); in SynthSuperConstructorFunctionDecl()
2413 QualType argT = Context->getObjCIdType(); in SynthSuperConstructorFunctionDecl()
2417 QualType msgSendType = getSimpleFunctionType(Context->getObjCIdType(), in SynthSuperConstructorFunctionDecl()
2419 SuperConstructorFunctionDecl = FunctionDecl::Create(*Context, TUDecl, in SynthSuperConstructorFunctionDecl()
2428 IdentifierInfo *msgSendIdent = &Context->Idents.get("objc_msgSend"); in SynthMsgSendFunctionDecl()
2430 QualType argT = Context->getObjCIdType(); in SynthMsgSendFunctionDecl()
2433 argT = Context->getObjCSelType(); in SynthMsgSendFunctionDecl()
2436 QualType msgSendType = getSimpleFunctionType(Context->getObjCIdType(), in SynthMsgSendFunctionDecl()
2438 MsgSendFunctionDecl = FunctionDecl::Create(*Context, TUDecl, in SynthMsgSendFunctionDecl()
2447 IdentifierInfo *msgSendIdent = &Context->Idents.get("objc_msgSendSuper"); in SynthMsgSendSuperFunctionDecl()
2449 ArgTys.push_back(Context->VoidTy); in SynthMsgSendSuperFunctionDecl()
2450 QualType msgSendType = getSimpleFunctionType(Context->getObjCIdType(), in SynthMsgSendSuperFunctionDecl()
2452 MsgSendSuperFunctionDecl = FunctionDecl::Create(*Context, TUDecl, in SynthMsgSendSuperFunctionDecl()
2461 IdentifierInfo *msgSendIdent = &Context->Idents.get("objc_msgSend_stret"); in SynthMsgSendStretFunctionDecl()
2463 QualType argT = Context->getObjCIdType(); in SynthMsgSendStretFunctionDecl()
2466 argT = Context->getObjCSelType(); in SynthMsgSendStretFunctionDecl()
2469 QualType msgSendType = getSimpleFunctionType(Context->getObjCIdType(), in SynthMsgSendStretFunctionDecl()
2471 MsgSendStretFunctionDecl = FunctionDecl::Create(*Context, TUDecl, in SynthMsgSendStretFunctionDecl()
2482 &Context->Idents.get("objc_msgSendSuper_stret"); in SynthMsgSendSuperStretFunctionDecl()
2484 ArgTys.push_back(Context->VoidTy); in SynthMsgSendSuperStretFunctionDecl()
2485 QualType msgSendType = getSimpleFunctionType(Context->getObjCIdType(), in SynthMsgSendSuperStretFunctionDecl()
2487 MsgSendSuperStretFunctionDecl = FunctionDecl::Create(*Context, TUDecl, in SynthMsgSendSuperStretFunctionDecl()
2497 IdentifierInfo *msgSendIdent = &Context->Idents.get("objc_msgSend_fpret"); in SynthMsgSendFpretFunctionDecl()
2499 QualType argT = Context->getObjCIdType(); in SynthMsgSendFpretFunctionDecl()
2502 argT = Context->getObjCSelType(); in SynthMsgSendFpretFunctionDecl()
2505 QualType msgSendType = getSimpleFunctionType(Context->DoubleTy, in SynthMsgSendFpretFunctionDecl()
2507 MsgSendFpretFunctionDecl = FunctionDecl::Create(*Context, TUDecl, in SynthMsgSendFpretFunctionDecl()
2516 IdentifierInfo *getClassIdent = &Context->Idents.get("objc_getClass"); in SynthGetClassFunctionDecl()
2518 ArgTys.push_back(Context->getPointerType(Context->CharTy.withConst())); in SynthGetClassFunctionDecl()
2519 QualType getClassType = getSimpleFunctionType(Context->getObjCClassType(), in SynthGetClassFunctionDecl()
2521 GetClassFunctionDecl = FunctionDecl::Create(*Context, TUDecl, in SynthGetClassFunctionDecl()
2531 &Context->Idents.get("class_getSuperclass"); in SynthGetSuperClassFunctionDecl()
2533 ArgTys.push_back(Context->getObjCClassType()); in SynthGetSuperClassFunctionDecl()
2534 QualType getClassType = getSimpleFunctionType(Context->getObjCClassType(), in SynthGetSuperClassFunctionDecl()
2536 GetSuperClassFunctionDecl = FunctionDecl::Create(*Context, TUDecl, in SynthGetSuperClassFunctionDecl()
2546 IdentifierInfo *getClassIdent = &Context->Idents.get("objc_getMetaClass"); in SynthGetMetaClassFunctionDecl()
2548 ArgTys.push_back(Context->getPointerType(Context->CharTy.withConst())); in SynthGetMetaClassFunctionDecl()
2549 QualType getClassType = getSimpleFunctionType(Context->getObjCClassType(), in SynthGetMetaClassFunctionDecl()
2551 GetMetaClassFunctionDecl = FunctionDecl::Create(*Context, TUDecl, in SynthGetMetaClassFunctionDecl()
2587 VarDecl *NewVD = VarDecl::Create(*Context, TUDecl, SourceLocation(), in RewriteObjCStringLiteral()
2588 SourceLocation(), &Context->Idents.get(S), in RewriteObjCStringLiteral()
2590 DeclRefExpr *DRE = new (Context) in RewriteObjCStringLiteral()
2591 DeclRefExpr(*Context, NewVD, false, strType, VK_LValue, SourceLocation()); in RewriteObjCStringLiteral()
2593 const_cast<ASTContext &>(*Context), DRE, UO_AddrOf, in RewriteObjCStringLiteral()
2594 Context->getPointerType(DRE->getType()), VK_PRValue, OK_Ordinary, in RewriteObjCStringLiteral()
2597 CastExpr *cast = NoTypeInfoCStyleCastExpr(Context, Exp->getType(), in RewriteObjCStringLiteral()
2606 static_cast<unsigned>(Context->getTypeSize(Context->IntTy)); in RewriteObjCBoolLiteralExpr()
2608 Expr *FlagExp = IntegerLiteral::Create(*Context, in RewriteObjCBoolLiteralExpr()
2610 Context->IntTy, Exp->getLocation()); in RewriteObjCBoolLiteralExpr()
2611 CastExpr *cast = NoTypeInfoCStyleCastExpr(Context, Context->ObjCBuiltinBoolTy, in RewriteObjCBoolLiteralExpr()
2613 ParenExpr *PE = new (Context) ParenExpr(Exp->getLocation(), Exp->getExprLoc(), in RewriteObjCBoolLiteralExpr()
2662 if (SubExpr->getType()->isIntegralType(*Context) && type->isBooleanType()) in RewriteObjCBoxedExpr()
2664 subExpr = NoTypeInfoCStyleCastExpr(Context, type, CK, subExpr); in RewriteObjCBoxedExpr()
2669 ArgTypes.push_back(Context->getObjCClassType()); in RewriteObjCBoxedExpr()
2670 ArgTypes.push_back(Context->getObjCSelType()); in RewriteObjCBoxedExpr()
2679 DeclRefExpr *DRE = new (Context) DeclRefExpr( in RewriteObjCBoxedExpr()
2680 *Context, MsgSendFlavor, false, msgSendType, VK_LValue, SourceLocation()); in RewriteObjCBoxedExpr()
2683 Context, Context->getPointerType(Context->VoidTy), CK_BitCast, DRE); in RewriteObjCBoxedExpr()
2688 castType = Context->getPointerType(castType); in RewriteObjCBoxedExpr()
2689 cast = NoTypeInfoCStyleCastExpr(Context, castType, CK_BitCast, in RewriteObjCBoxedExpr()
2693 ParenExpr *PE = new (Context) ParenExpr(StartLoc, EndLoc, cast); in RewriteObjCBoxedExpr()
2696 CallExpr *CE = CallExpr::Create(*Context, PE, MsgExprs, FT->getReturnType(), in RewriteObjCBoxedExpr()
2717 QualType IntQT = Context->IntTy; in RewriteObjCArrayLiteralExpr()
2719 getSimpleFunctionType(Context->VoidTy, IntQT, true); in RewriteObjCArrayLiteralExpr()
2722 DeclRefExpr *NSArrayDRE = new (Context) DeclRefExpr( in RewriteObjCArrayLiteralExpr()
2723 *Context, NSArrayFD, false, NSArrayFType, VK_PRValue, SourceLocation()); in RewriteObjCArrayLiteralExpr()
2728 static_cast<unsigned>(Context->getTypeSize(Context->UnsignedIntTy)); in RewriteObjCArrayLiteralExpr()
2729 Expr *count = IntegerLiteral::Create(*Context, in RewriteObjCArrayLiteralExpr()
2731 Context->UnsignedIntTy, SourceLocation()); in RewriteObjCArrayLiteralExpr()
2736 CallExpr::Create(*Context, NSArrayDRE, InitExprs, NSArrayFType, VK_LValue, in RewriteObjCArrayLiteralExpr()
2739 FieldDecl *ARRFD = FieldDecl::Create(*Context, nullptr, SourceLocation(), in RewriteObjCArrayLiteralExpr()
2741 &Context->Idents.get("arr"), in RewriteObjCArrayLiteralExpr()
2742 Context->getPointerType(Context->VoidPtrTy), in RewriteObjCArrayLiteralExpr()
2746 MemberExpr::CreateImplicit(*Context, NSArrayCallExpr, false, ARRFD, in RewriteObjCArrayLiteralExpr()
2748 QualType ConstIdT = Context->getObjCIdType().withConst(); in RewriteObjCArrayLiteralExpr()
2750 NoTypeInfoCStyleCastExpr(Context, in RewriteObjCArrayLiteralExpr()
2751 Context->getPointerType(ConstIdT), in RewriteObjCArrayLiteralExpr()
2784 Expr *cnt = IntegerLiteral::Create(*Context, in RewriteObjCArrayLiteralExpr()
2786 Context->UnsignedIntTy, SourceLocation()); in RewriteObjCArrayLiteralExpr()
2790 ArgTypes.push_back(Context->getObjCClassType()); in RewriteObjCArrayLiteralExpr()
2791 ArgTypes.push_back(Context->getObjCSelType()); in RewriteObjCArrayLiteralExpr()
2800 DeclRefExpr *DRE = new (Context) DeclRefExpr( in RewriteObjCArrayLiteralExpr()
2801 *Context, MsgSendFlavor, false, msgSendType, VK_LValue, SourceLocation()); in RewriteObjCArrayLiteralExpr()
2804 Context, Context->getPointerType(Context->VoidTy), CK_BitCast, DRE); in RewriteObjCArrayLiteralExpr()
2809 castType = Context->getPointerType(castType); in RewriteObjCArrayLiteralExpr()
2810 cast = NoTypeInfoCStyleCastExpr(Context, castType, CK_BitCast, in RewriteObjCArrayLiteralExpr()
2814 ParenExpr *PE = new (Context) ParenExpr(StartLoc, EndLoc, cast); in RewriteObjCArrayLiteralExpr()
2817 CallExpr *CE = CallExpr::Create(*Context, PE, MsgExprs, FT->getReturnType(), in RewriteObjCArrayLiteralExpr()
2838 QualType IntQT = Context->IntTy; in RewriteObjCDictionaryLiteralExpr()
2840 getSimpleFunctionType(Context->VoidTy, IntQT, true); in RewriteObjCDictionaryLiteralExpr()
2843 DeclRefExpr *NSDictDRE = new (Context) DeclRefExpr( in RewriteObjCDictionaryLiteralExpr()
2844 *Context, NSDictFD, false, NSDictFType, VK_PRValue, SourceLocation()); in RewriteObjCDictionaryLiteralExpr()
2851 static_cast<unsigned>(Context->getTypeSize(Context->UnsignedIntTy)); in RewriteObjCDictionaryLiteralExpr()
2852 Expr *count = IntegerLiteral::Create(*Context, in RewriteObjCDictionaryLiteralExpr()
2854 Context->UnsignedIntTy, SourceLocation()); in RewriteObjCDictionaryLiteralExpr()
2865 CallExpr::Create(*Context, NSDictDRE, ValueExprs, NSDictFType, VK_LValue, in RewriteObjCDictionaryLiteralExpr()
2868 FieldDecl *ARRFD = FieldDecl::Create(*Context, nullptr, SourceLocation(), in RewriteObjCDictionaryLiteralExpr()
2870 &Context->Idents.get("arr"), in RewriteObjCDictionaryLiteralExpr()
2871 Context->getPointerType(Context->VoidPtrTy), in RewriteObjCDictionaryLiteralExpr()
2875 MemberExpr::CreateImplicit(*Context, NSValueCallExpr, false, ARRFD, in RewriteObjCDictionaryLiteralExpr()
2877 QualType ConstIdT = Context->getObjCIdType().withConst(); in RewriteObjCDictionaryLiteralExpr()
2879 NoTypeInfoCStyleCastExpr(Context, in RewriteObjCDictionaryLiteralExpr()
2880 Context->getPointerType(ConstIdT), in RewriteObjCDictionaryLiteralExpr()
2885 CallExpr::Create(*Context, NSDictDRE, KeyExprs, NSDictFType, VK_LValue, in RewriteObjCDictionaryLiteralExpr()
2889 MemberExpr::CreateImplicit(*Context, NSKeyCallExpr, false, ARRFD, in RewriteObjCDictionaryLiteralExpr()
2893 NoTypeInfoCStyleCastExpr(Context, in RewriteObjCDictionaryLiteralExpr()
2894 Context->getPointerType(ConstIdT), in RewriteObjCDictionaryLiteralExpr()
2929 Expr *cnt = IntegerLiteral::Create(*Context, in RewriteObjCDictionaryLiteralExpr()
2931 Context->UnsignedIntTy, SourceLocation()); in RewriteObjCDictionaryLiteralExpr()
2935 ArgTypes.push_back(Context->getObjCClassType()); in RewriteObjCDictionaryLiteralExpr()
2936 ArgTypes.push_back(Context->getObjCSelType()); in RewriteObjCDictionaryLiteralExpr()
2942 T = Context->getPointerType(PointeeTy); in RewriteObjCDictionaryLiteralExpr()
2952 DeclRefExpr *DRE = new (Context) DeclRefExpr( in RewriteObjCDictionaryLiteralExpr()
2953 *Context, MsgSendFlavor, false, msgSendType, VK_LValue, SourceLocation()); in RewriteObjCDictionaryLiteralExpr()
2956 Context, Context->getPointerType(Context->VoidTy), CK_BitCast, DRE); in RewriteObjCDictionaryLiteralExpr()
2961 castType = Context->getPointerType(castType); in RewriteObjCDictionaryLiteralExpr()
2962 cast = NoTypeInfoCStyleCastExpr(Context, castType, CK_BitCast, in RewriteObjCDictionaryLiteralExpr()
2966 ParenExpr *PE = new (Context) ParenExpr(StartLoc, EndLoc, cast); in RewriteObjCDictionaryLiteralExpr()
2969 CallExpr *CE = CallExpr::Create(*Context, PE, MsgExprs, FT->getReturnType(), in RewriteObjCDictionaryLiteralExpr()
2981 *Context, TagTypeKind::Struct, TUDecl, SourceLocation(), in getSuperStructType()
2982 SourceLocation(), &Context->Idents.get("__rw_objc_super")); in getSuperStructType()
2986 FieldTypes[0] = Context->getObjCIdType(); in getSuperStructType()
2988 FieldTypes[1] = Context->getObjCIdType(); in getSuperStructType()
2992 SuperStructDecl->addDecl(FieldDecl::Create(*Context, SuperStructDecl, in getSuperStructType()
3003 return Context->getTagDeclType(SuperStructDecl); in getSuperStructType()
3009 *Context, TagTypeKind::Struct, TUDecl, SourceLocation(), in getConstantStringStructType()
3010 SourceLocation(), &Context->Idents.get("__NSConstantStringImpl")); in getConstantStringStructType()
3014 FieldTypes[0] = Context->getObjCIdType(); in getConstantStringStructType()
3016 FieldTypes[1] = Context->IntTy; in getConstantStringStructType()
3018 FieldTypes[2] = Context->getPointerType(Context->CharTy); in getConstantStringStructType()
3020 FieldTypes[3] = Context->LongTy; in getConstantStringStructType()
3024 ConstantStringDecl->addDecl(FieldDecl::Create(*Context, in getConstantStringStructType()
3036 return Context->getTagDeclType(ConstantStringDecl); in getConstantStringStructType()
3102 QualType castType = Context->getPointerType(FuncType); in SynthMsgSendStretCallExpr()
3116 ArgTypes[i].getAsStringInternal(ArgName, Context->getPrintingPolicy()); in SynthMsgSendStretCallExpr()
3123 Context->getPrintingPolicy()); in SynthMsgSendStretCallExpr()
3129 str += returnType.getAsString(Context->getPrintingPolicy()); str += ");\n"; in SynthMsgSendStretCallExpr()
3133 str += "\t s = (("; str += castType.getAsString(Context->getPrintingPolicy()); in SynthMsgSendStretCallExpr()
3148 str += "\t s = (("; str += castType.getAsString(Context->getPrintingPolicy()); in SynthMsgSendStretCallExpr()
3160 str += "\t"; str += returnType.getAsString(Context->getPrintingPolicy()); in SynthMsgSendStretCallExpr()
3175 IdentifierInfo *ID = &Context->Idents.get(name); in SynthMsgSendStretCallExpr()
3177 FunctionDecl::Create(*Context, TUDecl, SourceLocation(), SourceLocation(), in SynthMsgSendStretCallExpr()
3179 DeclRefExpr *DRE = new (Context) in SynthMsgSendStretCallExpr()
3180 DeclRefExpr(*Context, FD, false, castType, VK_PRValue, SourceLocation()); in SynthMsgSendStretCallExpr()
3182 CallExpr::Create(*Context, DRE, MsgExprs, castType, VK_LValue, in SynthMsgSendStretCallExpr()
3185 FieldDecl *FieldD = FieldDecl::Create(*Context, nullptr, SourceLocation(), in SynthMsgSendStretCallExpr()
3187 &Context->Idents.get("s"), in SynthMsgSendStretCallExpr()
3192 *Context, STCE, false, FieldD, FieldD->getType(), VK_LValue, OK_Ordinary); in SynthMsgSendStretCallExpr()
3246 Context, Context->getObjCIdType(), CK_BitCast, in SynthMessageExpr()
3247 new (Context) DeclRefExpr(*Context, CurMethodDef->getSelfDecl(), false, in SynthMessageExpr()
3248 Context->getObjCIdType(), VK_PRValue, in SynthMessageExpr()
3265 NoTypeInfoCStyleCastExpr(Context, in SynthMessageExpr()
3266 Context->getObjCIdType(), in SynthMessageExpr()
3275 DeclRefExpr *DRE = new (Context) in SynthMessageExpr()
3276 DeclRefExpr(*Context, SuperConstructorFunctionDecl, false, superType, in SynthMessageExpr()
3279 CallExpr::Create(*Context, DRE, InitExprs, superType, VK_LValue, in SynthMessageExpr()
3288 const_cast<ASTContext &>(*Context), SuperRep, UO_AddrOf, in SynthMessageExpr()
3289 Context->getPointerType(SuperRep->getType()), VK_PRValue, OK_Ordinary, in SynthMessageExpr()
3291 SuperRep = NoTypeInfoCStyleCastExpr(Context, in SynthMessageExpr()
3292 Context->getPointerType(superType), in SynthMessageExpr()
3297 new (Context) InitListExpr(*Context, SourceLocation(), InitExprs, in SynthMessageExpr()
3300 = Context->getTrivialTypeSourceInfo(superType); in SynthMessageExpr()
3301 SuperRep = new (Context) CompoundLiteralExpr(SourceLocation(), superTInfo, in SynthMessageExpr()
3306 const_cast<ASTContext &>(*Context), SuperRep, UO_AddrOf, in SynthMessageExpr()
3307 Context->getPointerType(SuperRep->getType()), VK_PRValue, OK_Ordinary, in SynthMessageExpr()
3322 CastExpr *ArgExpr = NoTypeInfoCStyleCastExpr(Context, in SynthMessageExpr()
3323 Context->getObjCIdType(), in SynthMessageExpr()
3338 Context, Context->getObjCIdType(), CK_BitCast, in SynthMessageExpr()
3339 new (Context) DeclRefExpr(*Context, CurMethodDef->getSelfDecl(), false, in SynthMessageExpr()
3340 Context->getObjCIdType(), VK_PRValue, in SynthMessageExpr()
3358 NoTypeInfoCStyleCastExpr(Context, Context->getObjCIdType(), in SynthMessageExpr()
3367 DeclRefExpr *DRE = new (Context) in SynthMessageExpr()
3368 DeclRefExpr(*Context, SuperConstructorFunctionDecl, false, superType, in SynthMessageExpr()
3371 CallExpr::Create(*Context, DRE, InitExprs, superType, VK_LValue, in SynthMessageExpr()
3380 const_cast<ASTContext &>(*Context), SuperRep, UO_AddrOf, in SynthMessageExpr()
3381 Context->getPointerType(SuperRep->getType()), VK_PRValue, OK_Ordinary, in SynthMessageExpr()
3383 SuperRep = NoTypeInfoCStyleCastExpr(Context, in SynthMessageExpr()
3384 Context->getPointerType(superType), in SynthMessageExpr()
3389 new (Context) InitListExpr(*Context, SourceLocation(), InitExprs, in SynthMessageExpr()
3392 = Context->getTrivialTypeSourceInfo(superType); in SynthMessageExpr()
3393 SuperRep = new (Context) CompoundLiteralExpr( in SynthMessageExpr()
3411 recExpr = NoTypeInfoCStyleCastExpr(Context, Context->getObjCIdType(), in SynthMessageExpr()
3433 type = Context->getObjCIdType(); in SynthMessageExpr()
3438 if (SubExpr->getType()->isIntegralType(*Context) && in SynthMessageExpr()
3453 userExpr = NoTypeInfoCStyleCastExpr(Context, type, CK, userExpr); in SynthMessageExpr()
3461 if (userExpr->getType()->isIntegralType(*Context)) { in SynthMessageExpr()
3470 userExpr = NoTypeInfoCStyleCastExpr(Context, Context->getObjCIdType(), in SynthMessageExpr()
3487 ArgTypes.push_back(Context->getPointerType(getSuperStructType())); in SynthMessageExpr()
3489 ArgTypes.push_back(Context->getObjCIdType()); in SynthMessageExpr()
3490 ArgTypes.push_back(Context->getObjCSelType()); in SynthMessageExpr()
3495 ? Context->getObjCIdType() in SynthMessageExpr()
3505 returnType = Context->getObjCIdType(); in SynthMessageExpr()
3511 DeclRefExpr *DRE = new (Context) DeclRefExpr( in SynthMessageExpr()
3512 *Context, MsgSendFlavor, false, msgSendType, VK_LValue, SourceLocation()); in SynthMessageExpr()
3518 cast = NoTypeInfoCStyleCastExpr(Context, in SynthMessageExpr()
3519 Context->getPointerType(Context->VoidTy), in SynthMessageExpr()
3527 castType = Context->getPointerType(castType); in SynthMessageExpr()
3528 cast = NoTypeInfoCStyleCastExpr(Context, castType, CK_BitCast, in SynthMessageExpr()
3532 ParenExpr *PE = new (Context) ParenExpr(StartLoc, EndLoc, cast); in SynthMessageExpr()
3535 CallExpr *CE = CallExpr::Create(*Context, PE, MsgExprs, FT->getReturnType(), in SynthMessageExpr()
3569 = Context->getTrivialTypeSourceInfo(Context->getObjCIdType()); in getProtocolType()
3570 ProtocolTypeDecl = TypedefDecl::Create(*Context, TUDecl, in getProtocolType()
3572 &Context->Idents.get("Protocol"), in getProtocolType()
3575 return Context->getTypeDeclType(ProtocolTypeDecl); in getProtocolType()
3585 IdentifierInfo *ID = &Context->Idents.get(Name); in RewriteObjCProtocolExpr()
3586 VarDecl *VD = VarDecl::Create(*Context, TUDecl, SourceLocation(), in RewriteObjCProtocolExpr()
3589 DeclRefExpr *DRE = new (Context) DeclRefExpr( in RewriteObjCProtocolExpr()
3590 *Context, VD, false, getProtocolType(), VK_LValue, SourceLocation()); in RewriteObjCProtocolExpr()
3592 Context, Context->getPointerType(DRE->getType()), CK_BitCast, DRE); in RewriteObjCProtocolExpr()
3613 return Context->getSourceManager().isBeforeInTranslationUnit( in IsTagDefinedInsideClass()
3621 return Context->getSourceManager().isBeforeInTranslationUnit( in IsTagDefinedInsideClass()
3637 QualType ElemTy = Context->getBaseElementType(Type); in RewriteObjCFieldDeclType()
3700 Type.getAsStringInternal(Name, Context->getPrintingPolicy()); in RewriteObjCFieldDecl()
3703 Result += " : "; Result += utostr(fieldDecl->getBitWidthValue(*Context)); in RewriteObjCFieldDecl()
3706 const ArrayType *AT = Context->getAsArrayType(Type); in RewriteObjCFieldDecl()
3714 AT = Context->getAsArrayType(AT->getElementType()); in RewriteObjCFieldDecl()
3729 Type = Context->getBaseElementType(Type); in RewriteLocallyDefinedNamedAggregates()
3785 *Context, TagTypeKind::Struct, Context->getTranslationUnitDecl(), in SynthesizeBitfieldGroupStructType()
3786 SourceLocation(), SourceLocation(), &Context->Idents.get(StructTagName)); in SynthesizeBitfieldGroupStructType()
3789 RD->addDecl(FieldDecl::Create(*Context, RD, SourceLocation(), SourceLocation(), in SynthesizeBitfieldGroupStructType()
3790 &Context->Idents.get(Ivar->getName()), in SynthesizeBitfieldGroupStructType()
3796 return Context->getTagDeclType(RD); in SynthesizeBitfieldGroupStructType()
4047 S += "static " + RT.getAsString(Context->getPrintingPolicy()) + " __" + in SynthesizeBlockFunc()
4071 QT.getAsStringInternal(ParamStr, Context->getPrintingPolicy()); in SynthesizeBlockFunc()
4119 QT = Context->getPointerType(QT); in SynthesizeBlockFunc()
4120 QT.getAsStringInternal(Name, Context->getPrintingPolicy()); in SynthesizeBlockFunc()
4213 QT = Context->getPointerType(QT); in SynthesizeBlockImpl()
4214 QT.getAsStringInternal(FieldName, Context->getPrintingPolicy()); in SynthesizeBlockImpl()
4215 QT.getAsStringInternal(ArgName, Context->getPrintingPolicy()); in SynthesizeBlockImpl()
4512 T = Context->getPointerType(T); in convertObjCTypeToCStyleType()
4570 ConditionalOperator *CondExpr = new (Context) ConditionalOperator( in SynthesizeBlockCall()
4588 RecordDecl *RD = RecordDecl::Create(*Context, TagTypeKind::Struct, TUDecl, in SynthesizeBlockCall()
4590 &Context->Idents.get("__block_impl")); in SynthesizeBlockCall()
4591 QualType PtrBlock = Context->getPointerType(Context->getTagDeclType(RD)); in SynthesizeBlockCall()
4610 PtrToFuncCastType = Context->getPointerType(PtrToFuncCastType); in SynthesizeBlockCall()
4612 CastExpr *BlkCast = NoTypeInfoCStyleCastExpr(Context, PtrBlock, in SynthesizeBlockCall()
4616 ParenExpr *PE = new (Context) ParenExpr(SourceLocation(), SourceLocation(), in SynthesizeBlockCall()
4620 FieldDecl *FD = FieldDecl::Create(*Context, nullptr, SourceLocation(), in SynthesizeBlockCall()
4622 &Context->Idents.get("FuncPtr"), in SynthesizeBlockCall()
4623 Context->VoidPtrTy, nullptr, in SynthesizeBlockCall()
4627 *Context, PE, true, FD, FD->getType(), VK_LValue, OK_Ordinary); in SynthesizeBlockCall()
4629 CastExpr *FunkCast = NoTypeInfoCStyleCastExpr(Context, PtrToFuncCastType, in SynthesizeBlockCall()
4631 PE = new (Context) ParenExpr(SourceLocation(), SourceLocation(), FunkCast); in SynthesizeBlockCall()
4642 CallExpr::Create(*Context, PE, BlkExprs, Exp->getType(), VK_PRValue, in SynthesizeBlockCall()
4667 FieldDecl *FD = FieldDecl::Create(*Context, nullptr, SourceLocation(), in RewriteBlockDeclRefExpr()
4669 &Context->Idents.get("__forwarding"), in RewriteBlockDeclRefExpr()
4670 Context->VoidPtrTy, nullptr, in RewriteBlockDeclRefExpr()
4674 *Context, DeclRefExp, isArrow, FD, FD->getType(), VK_LValue, OK_Ordinary); in RewriteBlockDeclRefExpr()
4677 FD = FieldDecl::Create(*Context, nullptr, SourceLocation(), SourceLocation(), in RewriteBlockDeclRefExpr()
4678 &Context->Idents.get(Name), in RewriteBlockDeclRefExpr()
4679 Context->VoidPtrTy, nullptr, in RewriteBlockDeclRefExpr()
4682 ME = MemberExpr::CreateImplicit(*Context, ME, true, FD, DeclRefExp->getType(), in RewriteBlockDeclRefExpr()
4686 ParenExpr *PE = new (Context) ParenExpr(DeclRefExp->getExprLoc(), in RewriteBlockDeclRefExpr()
4702 const_cast<ASTContext &>(*Context), DRE, UO_Deref, DRE->getType(), in RewriteLocalVariableExternalStorage()
4705 ParenExpr *PE = new (Context) ParenExpr(SourceLocation(), SourceLocation(), in RewriteLocalVariableExternalStorage()
4757 std::string TypeString(QT.getAsString(Context->getPrintingPolicy())); in RewriteImplicitCastObjCExpr()
4967 static_cast<unsigned>(Context->getTypeSize(Context->IntTy)); in SynthesizeByrefCopyDestroyHelper()
4969 static_cast<unsigned>(Context->getTypeSize(Context->VoidPtrTy)); in SynthesizeByrefCopyDestroyHelper()
4971 unsigned offset = (VoidPtrSize*4 + IntSize + IntSize)/Context->getCharWidth(); in SynthesizeByrefCopyDestroyHelper()
5034 bool HasCopyAndDispose = Context->BlockRequiresCopying(Ty, ND); in RewriteByRefVar()
5042 T.getAsStringInternal(Name, Context->getPrintingPolicy()); in RewriteByRefVar()
5186 IdentifierInfo *ID = &Context->Idents.get(name); in SynthBlockInitFunctionDecl()
5187 QualType FType = Context->getFunctionNoProtoType(Context->VoidPtrTy); in SynthBlockInitFunctionDecl()
5188 return FunctionDecl::Create(*Context, TUDecl, SourceLocation(), in SynthBlockInitFunctionDecl()
5255 QualType FType = Context->getPointerType(BFT); in SynthBlockInitExpr()
5270 DeclRefExpr *DRE = new (Context) in SynthBlockInitExpr()
5271 DeclRefExpr(*Context, FD, false, FType, VK_PRValue, SourceLocation()); in SynthBlockInitExpr()
5277 DeclRefExpr *Arg = new (Context) DeclRefExpr( in SynthBlockInitExpr()
5278 *Context, FD, false, FD->getType(), VK_LValue, SourceLocation()); in SynthBlockInitExpr()
5279 CastExpr *castExpr = NoTypeInfoCStyleCastExpr(Context, Context->VoidPtrTy, in SynthBlockInitExpr()
5287 *Context, TUDecl, SourceLocation(), SourceLocation(), in SynthBlockInitExpr()
5288 &Context->Idents.get(DescData), Context->VoidPtrTy, nullptr, SC_Static); in SynthBlockInitExpr()
5290 const_cast<ASTContext &>(*Context), in SynthBlockInitExpr()
5291 new (Context) DeclRefExpr(*Context, NewVD, false, Context->VoidPtrTy, in SynthBlockInitExpr()
5293 UO_AddrOf, Context->getPointerType(Context->VoidPtrTy), VK_PRValue, in SynthBlockInitExpr()
5306 Exp = new (Context) DeclRefExpr(*Context, FD, false, FD->getType(), in SynthBlockInitExpr()
5310 QT = Context->getPointerType(QT); in SynthBlockInitExpr()
5311 Exp = UnaryOperator::Create(const_cast<ASTContext &>(*Context), Exp, in SynthBlockInitExpr()
5318 Arg = new (Context) DeclRefExpr(*Context, FD, false, FD->getType(), in SynthBlockInitExpr()
5320 Exp = NoTypeInfoCStyleCastExpr(Context, Context->VoidPtrTy, in SynthBlockInitExpr()
5324 Exp = new (Context) DeclRefExpr(*Context, FD, false, FD->getType(), in SynthBlockInitExpr()
5328 QT = Context->getPointerType(QT); in SynthBlockInitExpr()
5329 Exp = UnaryOperator::Create(const_cast<ASTContext &>(*Context), Exp, in SynthBlockInitExpr()
5345 IdentifierInfo *II = &Context->Idents.get(RecName.c_str() in SynthBlockInitExpr()
5348 RecordDecl::Create(*Context, TagTypeKind::Struct, TUDecl, in SynthBlockInitExpr()
5351 QualType castT = Context->getPointerType(Context->getTagDeclType(RD)); in SynthBlockInitExpr()
5354 Exp = new (Context) DeclRefExpr(*Context, FD, false, FD->getType(), in SynthBlockInitExpr()
5370 const_cast<ASTContext &>(*Context), Exp, UO_AddrOf, in SynthBlockInitExpr()
5371 Context->getPointerType(Exp->getType()), VK_PRValue, OK_Ordinary, in SynthBlockInitExpr()
5373 Exp = NoTypeInfoCStyleCastExpr(Context, castT, CK_BitCast, Exp); in SynthBlockInitExpr()
5381 static_cast<unsigned>(Context->getTypeSize(Context->IntTy)); in SynthBlockInitExpr()
5382 Expr *FlagExp = IntegerLiteral::Create(*Context, llvm::APInt(IntSize, flag), in SynthBlockInitExpr()
5383 Context->IntTy, SourceLocation()); in SynthBlockInitExpr()
5386 NewRep = CallExpr::Create(*Context, DRE, InitExprs, FType, VK_LValue, in SynthBlockInitExpr()
5397 const_cast<ASTContext &>(*Context), NewRep, UO_AddrOf, in SynthBlockInitExpr()
5398 Context->getPointerType(NewRep->getType()), VK_PRValue, OK_Ordinary, in SynthBlockInitExpr()
5400 NewRep = NoTypeInfoCStyleCastExpr(Context, FType, CK_BitCast, in SynthBlockInitExpr()
5403 NewRep = new (Context) ParenExpr(SourceLocation(), SourceLocation(), in SynthBlockInitExpr()
5648 CastExpr *Replacement = new (Context) CastExpr(ICE->getType(), in RewriteFunctionBodyOrGlobalInitializer()
5807 static void Write_ProtocolExprReferencedMetadata(ASTContext *Context, in Write_ProtocolExprReferencedMetadata() argument
5811 if (Context->getLangOpts().MicrosoftExt) in Write_ProtocolExprReferencedMetadata()
5839 Write_ProtocolExprReferencedMetadata(Context, ProtDecl, Preamble); in HandleTranslationUnit()
6173 static void WriteModernMetadataDeclarations(ASTContext *Context, std::string &Result) { in WriteModernMetadataDeclarations() argument
6217 const llvm::Triple &Triple(Context->getTargetInfo().getTriple()); in WriteModernMetadataDeclarations()
6290 static void Write_protocol_list_initializer(ASTContext *Context, std::string &Result, in Write_protocol_list_initializer() argument
6314 ASTContext *Context, std::string &Result, in Write_method_list_t_initializer() argument
6335 std::string MethodTypeString = Context->getObjCEncodingForMethodDecl(MD); in Write_method_list_t_initializer()
6354 ASTContext *Context, std::string &Result, in Write_prop_list_t_initializer() argument
6375 Context->getObjCEncodingForPropertyDecl(PropDecl, Container); in Write_prop_list_t_initializer()
6402 static void Write__class_ro_t_initializer(ASTContext *Context, std::string &Result, in Write__class_ro_t_initializer() argument
6420 const llvm::Triple &Triple(Context->getTargetInfo().getTriple()); in Write__class_ro_t_initializer()
6469 static void Write_class_t(ASTContext *Context, std::string &Result, in Write_class_t() argument
6609 static void Write_category_t(RewriteModernObjC &RewriteObj, ASTContext *Context, in Write_category_t() argument
6692 ASTContext *Context, std::string &Result, in Write__extendedMethodTypes_initializer() argument
6706 Context->getObjCEncodingForMethodDecl(MD, true); in Write__extendedMethodTypes_initializer()
6719 ASTContext *Context, in Write_IvarOffsetVar() argument
6737 if (Context->getLangOpts().MicrosoftExt) in Write_IvarOffsetVar()
6740 if (!Context->getLangOpts().MicrosoftExt || in Write_IvarOffsetVar()
6762 ASTContext *Context, std::string &Result, in Write__ivar_list_t_initializer() argument
6767 Write_IvarOffsetVar(RewriteObj, Context, Result, OriginalIvars, CDecl); in Write__ivar_list_t_initializer()
6814 Context->getObjCEncodingForType(IVQT, IvarTypeString, in Write__ivar_list_t_initializer()
6821 unsigned Align = Context->getTypeAlign(IVQT)/8; in Write__ivar_list_t_initializer()
6824 CharUnits Size = Context->getTypeSizeInChars(IVQT); in Write__ivar_list_t_initializer()
6842 WriteModernMetadataDeclarations(Context, Result); in RewriteObjCProtocolMetaData()
6879 Write__extendedMethodTypes_initializer(*this, Context, Result, in RewriteObjCProtocolMetaData()
6885 Write_protocol_list_initializer(Context, Result, SuperProtocols, in RewriteObjCProtocolMetaData()
6889 Write_method_list_t_initializer(*this, Context, Result, InstanceMethods, in RewriteObjCProtocolMetaData()
6893 Write_method_list_t_initializer(*this, Context, Result, ClassMethods, in RewriteObjCProtocolMetaData()
6897 Write_method_list_t_initializer(*this, Context, Result, OptInstanceMethods, in RewriteObjCProtocolMetaData()
6901 Write_method_list_t_initializer(*this, Context, Result, OptClassMethods, in RewriteObjCProtocolMetaData()
6908 Write_prop_list_t_initializer(*this, Context, Result, ProtocolProperties, in RewriteObjCProtocolMetaData()
6989 static bool hasObjCExceptionAttribute(ASTContext &Context, in hasObjCExceptionAttribute() argument
6994 return hasObjCExceptionAttribute(Context, Super); in hasObjCExceptionAttribute()
7007 WriteModernMetadataDeclarations(Context, Result); in RewriteObjCClassMetaData()
7018 Write__ivar_list_t_initializer(*this, Context, Result, IVars, in RewriteObjCClassMetaData()
7045 Write_method_list_t_initializer(*this, Context, Result, InstanceMethods, in RewriteObjCClassMetaData()
7051 Write_method_list_t_initializer(*this, Context, Result, ClassMethods, in RewriteObjCClassMetaData()
7068 Write_protocol_list_initializer(Context, Result, in RewriteObjCClassMetaData()
7076 Write_prop_list_t_initializer(*this, Context, Result, ClassProperties, in RewriteObjCClassMetaData()
7095 Write__class_ro_t_initializer(Context, Result, flags, in RewriteObjCClassMetaData()
7109 if (hasObjCExceptionAttribute(*Context, CDecl)) in RewriteObjCClassMetaData()
7134 Write__class_ro_t_initializer(Context, Result, flags, in RewriteObjCClassMetaData()
7143 Write_class_t(Context, Result, in RewriteObjCClassMetaData()
7147 Write_class_t(Context, Result, in RewriteObjCClassMetaData()
7262 WriteModernMetadataDeclarations(Context, Result); in RewriteObjCCategoryImplDecl()
7293 Write_method_list_t_initializer(*this, Context, Result, InstanceMethods, in RewriteObjCCategoryImplDecl()
7299 Write_method_list_t_initializer(*this, Context, Result, ClassMethods, in RewriteObjCCategoryImplDecl()
7311 Write_protocol_list_initializer(Context, Result, in RewriteObjCCategoryImplDecl()
7319 Write_prop_list_t_initializer(*this, Context, Result, ClassProperties, in RewriteObjCCategoryImplDecl()
7324 Write_category_t(*this, Context, Result, in RewriteObjCCategoryImplDecl()
7418 Context->getObjCEncodingForMethodDecl(*MethodBegin, MethodTypeString); in RewriteObjCMethodsMetaData()
7428 Context->getObjCEncodingForMethodDecl(*MethodBegin, MethodTypeString); in RewriteObjCMethodsMetaData()
7473 CastExpr *castExpr = NoTypeInfoCStyleCastExpr(Context, in RewriteObjCIvarRefExpr()
7474 Context->getPointerType(Context->CharTy), in RewriteObjCIvarRefExpr()
7477 VarDecl *NewVD = VarDecl::Create(*Context, TUDecl, SourceLocation(), in RewriteObjCIvarRefExpr()
7478 SourceLocation(), &Context->Idents.get(IvarOffsetName), in RewriteObjCIvarRefExpr()
7479 Context->UnsignedLongTy, nullptr, in RewriteObjCIvarRefExpr()
7481 DeclRefExpr *DRE = new (Context) in RewriteObjCIvarRefExpr()
7482 DeclRefExpr(*Context, NewVD, false, Context->UnsignedLongTy, in RewriteObjCIvarRefExpr()
7485 *Context, castExpr, DRE, BO_Add, in RewriteObjCIvarRefExpr()
7486 Context->getPointerType(Context->CharTy), VK_PRValue, OK_Ordinary, in RewriteObjCIvarRefExpr()
7489 ParenExpr *PE = new (Context) ParenExpr(SourceLocation(), in RewriteObjCIvarRefExpr()
7508 *Context, TagTypeKind::Struct, TUDecl, SourceLocation(), in RewriteObjCIvarRefExpr()
7509 SourceLocation(), &Context->Idents.get(RecName)); in RewriteObjCIvarRefExpr()
7510 QualType PtrStructIMPL = Context->getPointerType(Context->getTagDeclType(RD)); in RewriteObjCIvarRefExpr()
7512 static_cast<unsigned>(Context->getTypeSize(Context->UnsignedIntTy)); in RewriteObjCIvarRefExpr()
7513 Expr *Zero = IntegerLiteral::Create(*Context, in RewriteObjCIvarRefExpr()
7515 Context->UnsignedIntTy, SourceLocation()); in RewriteObjCIvarRefExpr()
7516 Zero = NoTypeInfoCStyleCastExpr(Context, PtrStructIMPL, CK_BitCast, Zero); in RewriteObjCIvarRefExpr()
7517 ParenExpr *PE = new (Context) ParenExpr(SourceLocation(), SourceLocation(), in RewriteObjCIvarRefExpr()
7519 FieldDecl *FD = FieldDecl::Create(*Context, nullptr, SourceLocation(), in RewriteObjCIvarRefExpr()
7521 &Context->Idents.get(D->getNameAsString()), in RewriteObjCIvarRefExpr()
7526 *Context, PE, true, FD, FD->getType(), VK_LValue, OK_Ordinary); in RewriteObjCIvarRefExpr()
7527 IvarT = Context->getDecltypeType(ME, ME->getType()); in RewriteObjCIvarRefExpr()
7531 QualType castT = Context->getPointerType(IvarT); in RewriteObjCIvarRefExpr()
7533 castExpr = NoTypeInfoCStyleCastExpr(Context, in RewriteObjCIvarRefExpr()
7539 const_cast<ASTContext &>(*Context), castExpr, UO_Deref, IvarT, in RewriteObjCIvarRefExpr()
7541 PE = new (Context) ParenExpr(OldRange.getBegin(), in RewriteObjCIvarRefExpr()
7546 FieldDecl *FD = FieldDecl::Create(*Context, nullptr, SourceLocation(), in RewriteObjCIvarRefExpr()
7548 &Context->Idents.get(D->getNameAsString()), in RewriteObjCIvarRefExpr()
7553 MemberExpr::CreateImplicit(*Context, PE, /*isArrow*/ false, FD, in RewriteObjCIvarRefExpr()