This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: [PATCH] Guard a call to TYPE_TARGET_TYPE in gnuv3_pass_by_reference
- From: Pedro Alves <palves at redhat dot com>
- To: Siva Chandra <sivachandra at google dot com>, Doug Evans <dje at google dot com>, gdb-patches <gdb-patches at sourceware dot org>
- Date: Thu, 16 Oct 2014 19:01:21 +0100
- Subject: Re: [PATCH] Guard a call to TYPE_TARGET_TYPE in gnuv3_pass_by_reference
- Authentication-results: sourceware.org; auth=none
- References: <CAGyQ6gzAMpiA8Hwt1=DqmFxXjfe44nqGsCqsj-fx=ObJbgPAsA at mail dot gmail dot com>
Hi Siva,
On 10/16/2014 03:38 PM, Siva Chandra wrote:
> A call to TYPE_TARGET_TYPE was being done without checking if the type
> does have a target type. This was introduced by my commit:
> 82c48ac732edb0155288a93ef3dd39625ff2d2e1
>
> The attached patch fixes it. This probably qualifies as an obvious
> fix, but just in case.
>
> 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?
Thanks,
Pedro Alves