[PATCH] Do not attach a debug location to code inserted by ARC / API for disabling DebugLocations

Eric Christopher echristo at gmail.com
Mon Apr 8 11:06:02 PDT 2013

On Mon, Apr 8, 2013 at 10:40 AM, John McCall <rjmccall at apple.com> wrote:
> On Apr 5, 2013, at 5:22 PM, Adrian Prantl <aprantl at apple.com> wrote:
>> Patch for review, mostly for the IRBuilder::DisableDebugLocations() part.
>> Do not attach a debug location to code inserted by ARC --
>> it would create a spurious line table entry at the closing } of the scope.
> Is this a problem?  Just that we don't want "next" to stop here?

Pretty much. It's analogous to the same when we're looking at
cleanups, etc. I think this is going into the realm of "opinions on
behavior" here. There are a couple of bugs off of PR14330 that are
similar here where the gdb testsuite is checking to see where "next"
takes you. It's more interesting when you're looking at where next
takes you in something like:

foo (bar(), baz())

and you want to make sure that when you "next" out of baz that it
leaves you on the same line as foo.

For the patch, while I'm not sure we want it, I'd like to see how the
functionality plays out with other similar constructs in addition to
just arc to see?


More information about the cfe-commits mailing list