Article View: comp.lang.modula2
Article #4377Re: C vs. M2
From: Ken Badertscher
Date: Tue, 16 Aug 1988 21:56
Date: Tue, 16 Aug 1988 21:56
39 lines
2020 bytes
2020 bytes
in article <49@volition.dec.com>, vixie@decwrl.dec.com (Paul Vixie) says:
> Yes, it's true, a good compiler will find the best way no matter how you
> say it. But again, appearance gets my vote:
>
> foo[i]->bar.size += newsize;
> vs.
> foo[i]^.bar.count = foo[i]^.bar.count + newsize;
>
> I get to say what I mean. Yes, I know about INCR, but this is only one case.
Don't forget WITH!
WITH foo[i]^.bar DO
count = count + newsize
END;
Or even, since you mentioned it,
WITH foo[i]^.bar DO INC(count,newsize) END;
And to jump into the middle of the discussion, all I really have to add
is that Modula-2 "feels" a lot nicer to me. The verbosity doesn't bother
me, as someone said, I find myself being more eloquent with the more
eloquent language. I do think it is valid to compare the languages,
but many of the discussions I've ever read end up haggling over natty
details like case sensitivity and amount of typing (hmm... unintended
double entendre there, I initially meant "number of keystrokes", but
"strict type checking" applies as well ;-).
I spent my software engineering "apprenticeship" helping build a set of
libraries for a Modula-2 environment, and I now find myself doing most
of my programming in C (not by choice, I assure you). I miss the comforts
of strong type checking and DEFINITION MODULEs, and the rest. Some find
it oppressive, I find it helpful. And the bigger the program, the more
helpful it is, in my experience.
--
Ken Badertscher | Hey, umm, the stuff I said up there
Atari R&D Software Test/Support | is, like, what _I_ think, okay?
{portal,ames,imagen}!atari!kbad | So, y'know, don't bug Atari about it.
Technical Details
Message-ID:
<1120@atari.UUCP>Path:
arc1-ca.pugleaf.net!utzoo!attcan!uunet!portal!atari!kbadReferences:
<49@volition.dec.com>Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!attcan!uunet!portal!atari!kbad From: kbad@atari.UUCP (Ken Badertscher) Newsgroups: comp.lang.modula2 Subject: Re: C vs. M2 Message-ID: <1120@atari.UUCP> Date: 16 Aug 88 21:56:34 GMT References: <49@volition.dec.com> Organization: Atari Corp., Sunnyvale, CA Lines: 39