[PATCH] ARC + collection literal fix

Jesse Rusak me at jesserusak.com
Thu Apr 4 05:44:47 PDT 2013


On 2013-04-03, at 9:24 PM, John McCall <rjmccall at apple.com> wrote:

> On Mar 30, 2013, at 8:59 AM, Jesse Rusak <me at jesserusak.com> wrote:
>> I've put together a tiny patch which fixes a potential early release in collection literals under ARC, based on our conversation from cfe-dev: http://lists.cs.uiuc.edu/pipermail/cfe-dev/2013-March/028527.html
>> 
>> The patch uses the machinery you added for the @clang.arc.use call, and adds some checks for the presence of that call in the existing Objective-C literal tests. 
> 
> Thanks!  I've committed it as r178721.
> 
> I fleshed out the test case quite a bit and discovered that you were (1) double-emitting the key expressions in dictionary literals and (2) emitting the key expression yet again instead of the object expression.  It's unfortunate that the existing test wasn't precise enough to catch this, but now it should be.

In other words, I had royally messed up the generated code and hadn't tested it beyond the ARC-related behaviour. Great! So sorry for all the trouble, and thanks again for your time.

Cheers,
Jesse



More information about the cfe-commits mailing list