This is the mail archive of the
gdb-patches@sources.redhat.com
mailing list for the GDB project.
Re: [RFC/RFA] gdb extension for Harvard architectures
cagney wrote:
: > - doesn't change the meaning of any valid C expressions
:
: Is this a valid C expression?
:
: int foo();
: char *c = foo;
:
: I.e. does ISO C define its semantics?
A mere pointer assignment? There is not much possible semantics there
to worry about. Yes, it'd be illegal to dereference the char* pointer.
It may be legal to cast it back to "int (*) ()" and call through that,
if "char*" is as big as "int (*) ()".
Some of this discussion seems to me to focus too much on how
fundamentally nonsensical operations may be expressed in nonsensical
gdb expression syntax.
- FChE