PATCH: private ivars

Dmitri Gribenko gribozavr at
Fri Feb 15 15:59:16 PST 2013

On Sat, Feb 16, 2013 at 1:45 AM, Adrian Prantl <aprantl at> wrote:
> On Feb 15, 2013, at 3:06 PM, jahanian <fjahanian at> wrote:
>> ObjCInterfaceDecl::all_declared_ivar_begin has changed recently. You need to apply the patch against
>> current revision and make sure all clang tests pass after that.
> Thanks for noticing, Fariborz! Here is a rebased patch that passes the regression suite.

Sorry, there's one more:

+    ObjCInterfaceDecl* decl = cast<ObjCInterfaceType>(Ty)->getDecl();
+    if (decl)

cast<> can not return null (it will either succeed or assert in
+Asserts mode, or just produce a wrong value in -Asserts).  Use
dyn_cast (that returns null on failure) or drop the check -- whatever
is appropriate.  And there's a dyn_cast idiom:

if (Foo *F = dyn_cast<Foo>(Blah))
  ... use F...


(j){printf("%d\n",i);}}} /*Dmitri Gribenko <gribozavr at>*/

More information about the cfe-commits mailing list