Lines Matching refs:MigrateCtx
28 MigrationContext &MigrateCtx; member in __anon309938d70111::GCAttrsCollector
36 : MigrateCtx(ctx), FullyMigratable(false), in GCAttrsCollector()
90 if (MigrateCtx.AttrSet.count(RawLoc)) in handleAttr()
93 ASTContext &Ctx = MigrateCtx.Pass.Ctx; in handleAttr()
106 MigrateCtx.AttrSet.insert(RawLoc); in handleAttr()
107 MigrateCtx.GCAttrs.push_back(MigrationContext::GCAttrOccurrence()); in handleAttr()
108 MigrationContext::GCAttrOccurrence &Attr = MigrateCtx.GCAttrs.back(); in handleAttr()
170 SourceManager &SM = MigrateCtx.Pass.Ctx.getSourceManager(); in isInMainFile()
177 static void errorForGCAttrsOnNonObjC(MigrationContext &MigrateCtx) { in errorForGCAttrsOnNonObjC() argument
178 TransformActions &TA = MigrateCtx.Pass.TA; in errorForGCAttrsOnNonObjC()
180 for (unsigned i = 0, e = MigrateCtx.GCAttrs.size(); i != e; ++i) { in errorForGCAttrsOnNonObjC()
181 MigrationContext::GCAttrOccurrence &Attr = MigrateCtx.GCAttrs[i]; in errorForGCAttrsOnNonObjC()
193 static void checkWeakGCAttrs(MigrationContext &MigrateCtx) { in checkWeakGCAttrs() argument
194 TransformActions &TA = MigrateCtx.Pass.TA; in checkWeakGCAttrs()
196 for (unsigned i = 0, e = MigrateCtx.GCAttrs.size(); i != e; ++i) { in checkWeakGCAttrs()
197 MigrationContext::GCAttrOccurrence &Attr = MigrateCtx.GCAttrs[i]; in checkWeakGCAttrs()
202 if (!canApplyWeak(MigrateCtx.Pass.Ctx, Attr.ModifiedType, in checkWeakGCAttrs()
205 if (!MigrateCtx.RemovedAttrSet.count(Attr.Loc.getRawEncoding())) in checkWeakGCAttrs()
217 static void checkAllAtProps(MigrationContext &MigrateCtx, in checkAllAtProps() argument
258 TransformActions &TA = MigrateCtx.Pass.TA; in checkAllAtProps()
264 MigrateCtx.AtPropsWeak.insert(AtLoc.getRawEncoding()); in checkAllAtProps()
269 if (canApplyWeak(MigrateCtx.Pass.Ctx, IndProps.front()->getType(), in checkAllAtProps()
276 MigrateCtx.rewritePropertyAttribute("assign", toAttr, AtLoc); in checkAllAtProps()
278 MigrateCtx.addPropertyAttribute(toAttr, AtLoc); in checkAllAtProps()
284 Loc = MigrateCtx.Pass.Ctx.getSourceManager() in checkAllAtProps()
291 MigrateCtx.RemovedAttrSet.insert(Loc.getRawEncoding()); in checkAllAtProps()
295 static void checkAllProps(MigrationContext &MigrateCtx, in checkAllProps() argument
317 checkAllAtProps(MigrateCtx, AtLoc, IndProps); in checkAllProps()
321 void GCAttrsTraverser::traverseTU(MigrationContext &MigrateCtx) { in traverseTU() argument
323 GCAttrsCollector(MigrateCtx, AllProps).TraverseDecl( in traverseTU()
324 MigrateCtx.Pass.Ctx.getTranslationUnitDecl()); in traverseTU()
326 errorForGCAttrsOnNonObjC(MigrateCtx); in traverseTU()
327 checkAllProps(MigrateCtx, AllProps); in traverseTU()
328 checkWeakGCAttrs(MigrateCtx); in traverseTU()