This is the mail archive of the
mailing list for the Archer project.
Re: [patch] Do not allow invalid subscript operations on GDB values
- From: Tom Tromey <tromey at redhat dot com>
- To: Phil Muldoon <pmuldoon at redhat dot com>
- Cc: Project Archer <archer at sourceware dot org>
- Date: Tue, 15 Sep 2009 14:43:16 -0600
- Subject: Re: [patch] Do not allow invalid subscript operations on GDB values
- References: <4AAF6528.email@example.com>
- Reply-to: Tom Tromey <tromey at redhat dot com>
>>>>> "Phil" == Phil Muldoon <firstname.lastname@example.org> writes:
Phil> + /* Check the value's type is something that can be accessed via
Phil> + a subscript. */
Phil> + struct type *type = check_typedef (value_type (tmp));
I see eval.c also uses coerce_ref here.
So, I wonder if this works properly with a value of type
reference-to-array or reference-to-pointer.
Could you try that?
If that fails, please add the call and commit it.
If it works, it is ok as-is, so please commit it.
Also, please submit the final patch upstream.