[PATCH] Guard a call to TYPE_TARGET_TYPE in gnuv3_pass_by_reference
Siva Chandra
sivachandra@google.com
Thu Oct 16 18:10:00 GMT 2014
On Thu, Oct 16, 2014 at 11:01 AM, Pedro Alves <palves@redhat.com> wrote:
>> 2014-10-16 Siva Chandra Reddy <sivachandra@google.com>
>>
>> * gnu-v3-abi.c (gnuv3_pass_by_reference): Call TYPE_TARGET_TYPE
>> on the arg type of a constructor only if it is of reference type.
>>
>
> How did you notice this? Does an existing test catch it?
I hit it while I was "using" GDB so to say :)
I had a class which had a copy constructor as well as another
constructor taking an argument. It fails when going over the other
constructor.
Do you think a test case should be added? I did think about it, but
then, should there be a test case for every use of TYPE_TARGET_TYPE? I
thought it was more of a "user mistake" in my original patch.
Thank you,
Siva Chandra
More information about the Gdb-patches
mailing list