From: Andrew Cagney <ac131313@redhat.com>
To: Hilfinger@otisco.mckusick.com
Cc: gdb-patches@sources.redhat.com
Subject: Re: RFA: Ada-related patches, part I
Date: Fri, 07 Mar 2003 16:18:00 -0000 [thread overview]
Message-ID: <3E68C642.30009@redhat.com> (raw)
In-Reply-To: <200303050827.AAA25601@otisco.McKusick.COM>
> Andrew,
>
>
>> You don't appear to have a personal assignment for GDB on file.
>> Assuming this is being done as an employee of Act, can you please use
>> your act e-mail address in your ChangLogs.
>
>
> Sure, if that will simplify things. For the record, however,
> otisco.mckusick.com is the property of Ada Core Technologies.
>
>
>> > * defs.h (enum language): Add language_ada.
>
>>
>> This is ok.
>>
>> However, this change shouldn't be necessary. The language code should
>> be sufficiently modula as to not need this. Can you/act at least
>> investigate what would be needed to finish this?
>
>
> Umm. But I notice quite a few tests scattered around the current
> sources having the form ``if (suchandsuch == language_cplus...).'' In
> particular, there are uses in such routines as symbol_natural_name
> that are going to have to be extended for Ada. Perhaps, then, I am a
> bit unclear what you intend here.
(insert std disclaimer `ignoring c++ ...')
> Are you simply saying that if I find a place in common (i.e., non ada-
> *) files that requires different treatment for Ada than for another
> language, I should introduce a new entry into the language_defn
> structure to handle it object-orientedly rather than performing
> specific ``... == language_ada'' tests? I'm certainly all for that.
Yes. Before adding another case to a switch, see of the code can be
pushed into the language vector.
> Yes, I considered doing that, just as someone (you, as I recall) previously
> asked for OP_ADA_ATTRIBUTE. However, these operators make sense
> generically; it's just that only Ada uses them at the moment.
> How's about if I change the comments instead to remove all
> traces of Ada (see below)? Your choice.
Which ever. The re-worded version is much better.
>> (mind you, again, this shouldn't be needed. Instead these operators
>> should be objects that language specific modules can just add).
>
>
> I think I agree again, and normally would have done just this as a matter
> of course, except that parse.c is not set up to be extensible in this
> way. The functions prefixify_subexp and length_of_subexp both need to
> know about these opcodes, as things now stand. Of course, if you are
> asking me to reorganize parse.c and to revise expression.h so as to
> make the operator set open-ended, just say the word.
Wow! is there duplication or what. Would adding a new operator
`generic' that, in the expression array, added:
OP_GENERIC (better name?)
(operator *) op
... op->length(exp) elements ...
work? Something similar for the expression evaluator.
What about op_print? I guess operator ends up containing similar
information.
Andrew
next prev parent reply other threads:[~2003-03-07 16:18 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2003-03-04 7:37 Paul N. Hilfinger
2003-03-04 15:56 ` Andrew Cagney
2003-03-05 8:30 ` Paul N. Hilfinger
2003-03-07 16:18 ` Andrew Cagney [this message]
2003-03-04 19:43 ` Eli Zaretskii
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=3E68C642.30009@redhat.com \
--to=ac131313@redhat.com \
--cc=Hilfinger@otisco.mckusick.com \
--cc=gdb-patches@sources.redhat.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox