public inbox for gcc@gcc.gnu.org
 help / color / mirror / Atom feed
* need function decl/type in get_parm_info
@ 2003-08-02  3:24 DJ Delorie
  2003-08-02 11:16 ` Zack Weinberg
  0 siblings, 1 reply; 2+ messages in thread
From: DJ Delorie @ 2003-08-02  3:24 UTC (permalink / raw)
  To: gcc


I'm working on converting PROMOTE_PROTOTYPES to be a target hook,
sensitive to any attributes that might have been added to the function
decl.  Unfortunately, one of the places it's used - get_parm_info() in
c-decl.c - happens before current_function_decl is defined, and there
doesn't appear to be an obvious way to get the function type or decl.

Alternately, can the promotions be deferred until later, when the decl
is available?  If so, where's the best place to move it to?

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: need function decl/type in get_parm_info
  2003-08-02  3:24 need function decl/type in get_parm_info DJ Delorie
@ 2003-08-02 11:16 ` Zack Weinberg
  0 siblings, 0 replies; 2+ messages in thread
From: Zack Weinberg @ 2003-08-02 11:16 UTC (permalink / raw)
  To: DJ Delorie; +Cc: gcc

DJ Delorie <dj@redhat.com> writes:

> I'm working on converting PROMOTE_PROTOTYPES to be a target hook,
> sensitive to any attributes that might have been added to the function
> decl.  Unfortunately, one of the places it's used - get_parm_info() in
> c-decl.c - happens before current_function_decl is defined, and there
> doesn't appear to be an obvious way to get the function type or decl.
>
> Alternately, can the promotions be deferred until later, when the decl
> is available?  If so, where's the best place to move it to?

I don't have a good answer, but I think c-decl.c shouldn't have to
know about this particular target hook.  Adjusting as-passed argument
types should happen only when converting to RTL.

zw

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2003-08-02  1:37 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2003-08-02  3:24 need function decl/type in get_parm_info DJ Delorie
2003-08-02 11:16 ` Zack Weinberg

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).