This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: [PATCH v2] Logical short circuiting with argument lists
On 09/12/2018 12:38 PM, Tom Tromey wrote:
>>>>>> "Rich" == Rich Bunt <richard.bunt@arm.com> writes:
>
>>> Though, another option is to do this in a fortran-specific way.
>
> Rich> Are you able to provide some more details on this approach please?
>
> Sure. Each language provides its own evaluation function. These
> functions can change the interpretation -- or even, in collusion with
> the language's expression parser the layout in memory -- of a given
> opcode. Most languages just defer to the generic evaluator.
>
> E.g., look at rust-lang.c:rust_evaluate_subexp. It changes UNOP_IND to
> handle Rust trait objects, among other things.
>
> Fortran doesn't have one of these as f_language_defn refers to
> exp_descriptor_standard.
>
> The whole expression data structure and approach is bad and should be
> rewritten.
>
> Anyway, doing this may be overkill, unless we think of some downside to
> your approach.
Thanks for this. It's good to know this is an option as I work through
other Fortran additions.
Rich.