arphaman added inline comments.
================ Comment at: lib/Sema/SemaDeclObjC.cpp:4337 + VersionTuple MethodVersion = Method->getVersionIntroduced(); + if (SemaRef.getASTContext().getTargetInfo().getPlatformMinVersion() >= + AcceptedInVersion && ---------------- erik.pilkington wrote: > I wonder if this is the right place to check this. If we're compiling using a > new SDK, but deploying back before vector types were supported we will > diagnose a method declared in a header even if it is never called. We should > probably hook this into DiagnoseAvailabilityOfDecl (in SemaExpr.cpp), which > is called whenever a method is actually used, and diagnose it then. I'm not sure I get your argument.. We don't diagnose on method declarations, just method definitions, so I don't see how the header stuff is relevant here. We definitely don't want to diagnose on method uses either. Repository: rL LLVM https://reviews.llvm.org/D28670 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits