From: Andreas Schwab <schwab@suse.de>
To: Andrew Cagney <ac131313@cygnus.com>
Cc: gdb-patches@sources.redhat.com
Subject: Re: RFA: ``set mips abi''
Date: Wed, 19 Jun 2002 02:00:00 -0000 [thread overview]
Message-ID: <jehejzlk20.fsf@sykes.suse.de> (raw)
In-Reply-To: <20020618223408.GA5128@nevyn.them.org> (Daniel Jacobowitz's message of "Tue, 18 Jun 2002 18:34:08 -0400")
Daniel Jacobowitz <drow@mvista.com> writes:
|> > >You can do it very easily with designated initializers, but they are
|> > >not adequately portable. You can do it very easily building the array
|> > >at runtime but why bother? Keeping two lists in sync is not the most
|> > >complicated thing in the world.
|> >
|> > (what's a designated initializer?)
|>
|> I think I'm mixing terms here; I'm thinking of two language extensions
|> in GCC and c99. The pertinent one is:
The term is correct, but the C99 syntax is different.
|> void *array[] = {
|> [1] NULL,
|> [2] some_void_ptr,
|> [3] NULL,
|> };
void *array[] = {
[1] = NULL,
[2] = some_void_ptr,
[3] = NULL,
};
|> I think you can use enum values as the tags but I'm not quite sure.
You can use any constant expression in an array designator.
Andreas.
--
Andreas Schwab, SuSE Labs, schwab@suse.de
SuSE Linux AG, Deutschherrnstr. 15-19, D-90429 Nürnberg
Key fingerprint = 58CA 54C7 6D53 942B 1756 01D3 44D5 214B 8276 4ED5
"And now for something completely different."
next prev parent reply other threads:[~2002-06-19 9:00 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2002-06-13 11:51 Daniel Jacobowitz
2002-06-18 14:22 ` Andrew Cagney
2002-06-18 14:34 ` Daniel Jacobowitz
2002-06-18 15:26 ` Andrew Cagney
2002-06-18 15:34 ` Daniel Jacobowitz
2002-06-19 2:00 ` Andreas Schwab [this message]
2002-06-19 9:45 ` Daniel Jacobowitz
2002-06-19 11:43 ` Andrew Cagney
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=jehejzlk20.fsf@sykes.suse.de \
--to=schwab@suse.de \
--cc=ac131313@cygnus.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