Zero Length Arrays Allowed in C Standard?

T. William Wells bill at twwells.com
Fri Dec 8 06:58:39 AEST 1989


In article <526 at codonics.COM> bret at codonics.com (Bret Orsburn) writes:
: "That ANSI chose not to require it" is ALSO not the point of the original
: posting. That ANSI chose to FORBID it is the point. And that ANSI chose
: to forbid it in the face of existing implementations and existing code
: deserves at least an "Aargh!".

Let's see if I have this straight:

	1) Some implementations provide feature X.
	2) X3J11 chose not to permit feature X.
	3) Programs using feature X will break under an ANSI compiler.
	3) Therefore X3J11 deserves at least an Aargh!

Nope. Doesn't wash. Only if feature X were either a de facto or a
de jure standard (such as they were), or filled a very important,
portable, need, would this be a valid argument.

While I'd like to have zero length arrays (and, in fact,
complained about their lack in the comments I sent to X3J11) I'm
not going to pretend that this particular feature is really all
that important.

Never mind that the committee included at least one feeping
creature, it was not their business to include every feature that
someone had dreamt up for a C compiler. And code that relied on
those features will necessarily break when used on an ANSI
compliant compiler. Such is life.

---
Bill                    { uunet | novavax | ankh | sunvice } !twwells!bill
bill at twwells.com



More information about the Comp.lang.c mailing list