From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: X-Spam-Status: No, score=-1.3 required=5.0 tests=BAYES_00,INVALID_MSGID autolearn=no autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,51b151b4d322b1cc X-Google-Attributes: gid103376,public From: Robert A Duff Subject: Re: ada.strings.unbounded "free" and "String_Access" Date: 2000/03/11 Message-ID: #1/1 X-Deja-AN: 596119456 Sender: bobduff@world.std.com (Robert A Duff) References: <38C5B5AD.D310C559@mindspring.com> <38c6de74@eeyore.callnetuk.com> Organization: The World Public Access UNIX, Brookline, MA Newsgroups: comp.lang.ada Date: 2000-03-11T00:00:00+00:00 List-Id: "Nick Roberts" 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