public inbox for gcc@gcc.gnu.org
 help / color / mirror / Atom feed
* Variably sized data types and local functions
@ 2003-04-05 20:32 Christian Ehrhardt
  2003-04-07 21:32 ` Richard Henderson
  0 siblings, 1 reply; 2+ messages in thread
From: Christian Ehrhardt @ 2003-04-05 20:32 UTC (permalink / raw)
  To: gcc


PR 8081 is basically about this piece of code (gives an ICE with all
versions of gcc):

void f (int size)
{
        typedef struct { char val[size]; } block;
        block retframe_block () { }
        retframe_block ();
}

Now my question is: Should this be legal?

Second question: Should an actual parameter of variable size be legal, i.e.:

void f (int size)
{
        typedef struct { char val[size]; } block;
        void retframe_block (block b) { }
}

None of the variations I tried currently work, but I managed to get
at least three different ICEs.

    regards  Christian

-- 
THAT'S ALL FOLKS!

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

* Re: Variably sized data types and local functions
  2003-04-05 20:32 Variably sized data types and local functions Christian Ehrhardt
@ 2003-04-07 21:32 ` Richard Henderson
  0 siblings, 0 replies; 2+ messages in thread
From: Richard Henderson @ 2003-04-07 21:32 UTC (permalink / raw)
  To: Christian Ehrhardt; +Cc: gcc

On Sat, Apr 05, 2003 at 02:22:54PM +0200, Christian Ehrhardt wrote:
> None of the variations I tried currently work, but I managed to get
> at least three different ICEs.

I don't see any reason why these cases should be illegal.


r~

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

end of thread, other threads:[~2003-04-07 20:34 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2003-04-05 20:32 Variably sized data types and local functions Christian Ehrhardt
2003-04-07 21:32 ` Richard Henderson

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).