comp.lang.ada
 help / color / mirror / Atom feed
From: Robert A Duff <bobduff@world.std.com>
Subject: Re: ada.strings.unbounded "free" and "String_Access"
Date: 2000/03/11
Date: 2000-03-11T00:00:00+00:00	[thread overview]
Message-ID: <wccog8llcpu.fsf@world.std.com> (raw)
In-Reply-To: 38c6de74@eeyore.callnetuk.com

"Nick Roberts" <nickroberts@callnetuk.com> writes:

> Really, the type String_Access, and the function Free, are provided purely
> as a convenience. They could easily have been omitted (to be declared
> incidentally instead), but that was obviously felt to be just a little too
> inconvenient by the designers of Ada 95 (and I agree with them).

Right.  The inconvenience comes from the fact that you will end up with
several String_Access types in different packages (some probably called
String_Ptr, and so forth), and then when writing some code that uses
more than one package, you end up with a bunch of silly type
conversions.

If you always use the One True String_Access, you avoid that problem,
although that seems kind of kludgy if you don't really want to use
Unbounded_Strings.

- Bob




  parent reply	other threads:[~2000-03-11  0:00 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2000-03-07  0:00 ada.strings.unbounded "free" and "String_Access" Al Johnston
2000-03-08  0:00 ` Robert A Duff
2000-03-08  0:00 ` Nick Roberts
2000-03-08  0:00   ` Jeff Carter
2000-03-10  0:00     ` Ted Dennison
2000-03-11  0:00   ` Robert A Duff [this message]
2000-03-13  0:00     ` Robert Dewar
2000-03-09  0:00 ` Al Johnston
replies disabled

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