From: nmm1@cus.cam.ac.uk (Nick Maclaren)
Subject: Re: WAS Re: Final kick at the "Merced Guessing Game"
Date: 1997/10/18 [thread overview]
Message-ID: <62a0f5$9p8$1@lyra.csx.cam.ac.uk> (raw)
In-Reply-To: 3447D55B.1CDE@world.std.com
In article <3447D55B.1CDE@world.std.com>,
David Chase <chase@world.std.com> wrote:
>William Clodius wrote:
>
>> A minor point, but one aspect in which conventional languages are
>> starting to resemble functional languages is in the presence of garbage
>> collectors. While I don't know of any C or C++ implementations that
>> provide it, the availabiltiy of the Boehm collector and the commercial
>> add ons is starting to impact the C/C++ community. ...
>
>There's some problems here, at least with respect to C. Fortran 90
>is somewhat saner with its pointers than is C, at least in its
>specification. Working only within the C specification, it is
>possible for the programmer to create pointers anywhere within the
>interior of a structure or an array, or to the first address after
>such an object. In practice, C programmers commit vastly more
>disgusting sins (my favorite -- out-of-bounds pointer arithmetic
>from a freed pointer. ...
Yes, and I regard this whole mess as a tragedy of the first water. The
point is that there are TWO aspects here:
1) Are ALL pointer operations checked?
2) Is there a semi-automatic way of recovering dead space?
The confusion that caused the Maclaren-O'Keefe explosion was due to a
misunderstanding over this. I was stating that I did not like the second
and had never seen a good one - but I was NOT stating that I did not want
the first! What I actually want is a language where all pointer uses are
checked, and I get an error when I get it wrong, but where the system
does not do unspeakable things to my data storage behind my back.
I have a fair amount of experience in attempting to debug problems in
large programs (not mine) with unchecked pointers AND garbage collection,
and it has almost always been a complete disaster. The effect of an error
is that it is rarely detected near where it occurs, and the garbage
collector has destroyed all the evidence by the time the program falls
over. I have several times had to resolve this problem in cases where the
authors of the code admitted defeat, and it took AGES.
Hence my position. If don't really WANT garbage collection, but I will
put up with it (for most programs) ONLY if all pointer operations are
checked. If that is not so, I don't want to know.
Nick Maclaren,
University of Cambridge Computer Laboratory,
New Museums Site, Pembroke Street, Cambridge CB2 3QG, England.
Email: nmm1@cam.ac.uk
Tel.: +44 1223 334761 Fax: +44 1223 334679
next prev parent reply other threads:[~1997-10-18 4:00 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
1997-10-07 4:00 Final kick at the "Merced Guessing Game" Robert Harley
1997-10-07 4:00 ` Martin Rodgers
1997-10-07 4:00 ` Nick Maclaren
1997-10-07 4:00 ` Shankar Unni
1997-10-08 4:00 ` boo
1997-10-09 4:00 ` Patrick F. McGehearty
1997-10-10 4:00 ` Richard A. O'Keefe
1997-10-15 4:00 ` David Chase
1997-10-16 4:00 ` William Clodius
1997-10-17 4:00 ` WAS " David Chase
1997-10-18 4:00 ` Nick Maclaren [this message]
1997-10-18 4:00 ` David Chase
1997-10-18 4:00 ` [Reposted due to Enlow UCE cancel]: " David Chase
1997-10-19 4:00 ` Nick Maclaren
1997-10-22 4:00 ` pointer checking (WAS Re: Final kick at the "Merced Guessing Game") Hans-Juergen Boehm
read-only archive
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox