Page MenuHomePhabricator

[Sema][ObjC] Preserve syntactic sugar when removing ARCReclaimReturnedObject cast

Authored by ahatanak on Oct 6 2017, 7:05 PM.



This is a follow-up patch to r314370.

Rather than throwing away the enclosing parentheses in maybeUndoReclaimObject, this patch walks down the expression until an ARCReclaimReturnedObject cast is found and removes just the cast, preserving the syntactic sugar expressions (parens and casts) that were visited up to that point.


Event Timeline

ahatanak created this revision.Oct 6 2017, 7:05 PM
rjmccall accepted this revision.Oct 6 2017, 8:30 PM


This revision is now accepted and ready to land.Oct 6 2017, 8:30 PM
This revision was automatically updated to reflect the committed changes.