sizeof, ptrs, lint, portability

jsdy at SEISMO.ARPA jsdy at SEISMO.ARPA
Fri Feb 8 14:15:43 AEST 1985


I'm kinda tired of cottrell's insistent flaming.  I am almost convinced
that he does a lot of it just to get under the skins of people like Guy,
who can get very righteously provoked.	;-)/;-S

I think most folk would agree that we like C's terse style, and that
once we have its capabilities on our particular machine down pat, we can
right incredibly clever and, yes, punning programs that do all manner of
wonderful things.  We can do this quickly, brightly, and with beauty,
but not necessarily portably.  And I'm using that word in a highly
literal sense there!  If it ports to 99.9% of correct compilers but not
to 0.1%, then it is not portable.  That is  n o t  to say it's bad code
-- it does what you want, if you don't want to run on the 0.1%.  I know
that cottrell has said any number of times he doesn't, so his code is
still GOOD CODE.  At least, as far as this criterion goes.

However, there is an important subgroup of us to whom it is important
to know exactly what is legal for 100% of all correct compilers, and
what is not.  This is a subgroup, not the whole.  And to that group,
it matters much that a program to be 100% portable must take into
account "weird" machines and odd-sized word/byte/???? sizes.  And, yes,
pointers like the DEC-10 byte pointers! (18 bits address, 18 bits byte
specifier, remember?)

There is room in this world for all of us.  I fall into each group, on
occasion, although I must admit that Guy sounds much purer than anything
I've ever written.  (Of course, I've never written ANSI code ...).
However, there is not room in my notesfiles for so many flames!  [;-)]
I am not "the legendary Loren", and have trouble keeping up with my
limited number of newsgroups.  So, let's keep it to more light than
heat, OK?	;-);-);-)

Joe Yao		hadron!jsdy at seismo.{ARPA,UUCP}



More information about the Comp.lang.c mailing list