Steven - > Bootstrapped&tested on powerpc64-unknown-linux-gnu. OK for trunk?
Thanks for working on this. It looks good, couple of minor comments: Please add an assert that d->have_this_obj == true in write_types_local_process_field, before the oprintf that outputs "this_obj". > @@ -3444,6 +3449,7 @@ write_local_func_for_structure (const_type_p orig_ > d.prev_val[3] = "x"; > d.val = "(*x)"; > d.fn_wants_lvalue = true; > + d.have_this_obj = false; > > oprintf (d.of, "\n"); > oprintf (d.of, "void\n"); > @@ -3458,6 +3464,7 @@ write_local_func_for_structure (const_type_p orig_ > s->kind == TYPE_UNION ? "union" : "struct", s->u.s.tag, > s->kind == TYPE_UNION ? "union" : "struct", s->u.s.tag); > d.indent = 2; > + d.have_this_obj = true; > walk_type (s, &d); > oprintf (d.of, "}\n"); > } The first store is dead here. Thanks! -- Laurynas