comp.lang.ada
 help / color / mirror / Atom feed
From: dennison@telepath.com
Subject: Re: scope and/or parameters (beginner)
Date: 1999/04/14
Date: 1999-04-14T00:00:00+00:00	[thread overview]
Message-ID: <7f2ar3$b6l$1@nnrp1.dejanews.com> (raw)
In-Reply-To: 37149AE9.883147B6@prolifics.com

In article <37149AE9.883147B6@prolifics.com>,
  Hyman Rosen <hymie@prolifics.com> wrote:
> Robert Dewar wrote:
> > A C programmer making the same choice would have two
> > approaches.
> > ...
> > Which do you think would be chosen (I would guess neither,
>
> Correct. A C programmer would, of course, simply declare the
> parameter as being 'const', then insert the test exactly as
> you did in Ada.
>
> Hmph. I'm surprised that you, of all people, are so parochial.
> You usually aren't.

I don't think "const" exists in all versions of C. My old C reference book
(circa 1984) doesn't list it as a reserved word, or anywhere at all for that
matter. I suspect that means it did not exist in K&R C. Was it introduced in
ANSI C? In C++?

I don't look at too much C code myself, but the first time I ever saw "const"
in C source was about 3 months ago, and it was for a C++ capable compiler.

--
T.E.D.

-----------== Posted via Deja News, The Discussion Network ==----------
http://www.dejanews.com/       Search, Read, Discuss, or Start Your Own    




  reply	other threads:[~1999-04-14  0:00 UTC|newest]

Thread overview: 44+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
1999-04-02  0:00 scope and/or parameters (beginner) fluffy_pink
1999-04-03  0:00 ` Matthew Heaney
1999-04-05  0:00 ` Corey Ashford
1999-04-05  0:00   ` fluffy_doo
1999-04-06  0:00     ` Matthew Heaney
1999-04-08  0:00     ` czgrr
1999-04-10  0:00       ` fluffy_puff
1999-04-12  0:00       ` dennison
1999-04-13  0:00         ` czgrr
1999-04-13  0:00           ` Robert Dewar
1999-04-14  0:00             ` czgrr
1999-04-14  0:00               ` Robert Dewar
1999-04-15  0:00                 ` czgrr
1999-04-15  0:00                   ` Robert Dewar
1999-04-14  0:00               ` dennison
1999-04-13  0:00         ` Robert Dewar
1999-04-13  0:00     ` Robert A Duff
1999-04-14  0:00       ` Robert Dewar
1999-04-14  0:00         ` Hyman Rosen
1999-04-14  0:00           ` dennison [this message]
1999-04-14  0:00             ` Hyman Rosen
1999-04-14  0:00               ` dennison
1999-04-14  0:00                 ` Hyman Rosen
1999-04-15  0:00                   ` dennison
1999-04-15  0:00                     ` Robert Dewar
1999-04-15  0:00                       ` dennison
1999-04-15  0:00                       ` Hyman Rosen
1999-04-15  0:00           ` Robert Dewar
1999-04-15  0:00             ` Hyman Rosen
1999-04-15  0:00               ` Robert Dewar
1999-04-15  0:00                 ` Hyman Rosen
1999-04-16  0:00               ` Rakesh Malhotra
1999-04-15  0:00       ` fluffy_dong
1999-04-15  0:00         ` Robert Dewar
1999-04-15  0:00           ` dennison
1999-04-15  0:00             ` fluffy_dong
1999-04-16  0:00               ` Robert Dewar
1999-04-16  0:00                 ` Fraser Wilson
1999-04-16  0:00                   ` Gautier.DeMontmollin
1999-04-20  0:00                     ` Nick Roberts
1999-04-21  0:00                     ` fraser
1999-04-22  0:00               ` Robert A Duff
1999-04-22  0:00                 ` Larry Kilgallen
1999-04-16  0:00         ` Samuel Mize
replies disabled

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox