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.9 required=5.0 tests=BAYES_00 autolearn=ham autolearn_force=no version=3.4.4 X-Google-Thread: 103376,2efc07c562a92932 X-Google-Attributes: gid103376,public X-Google-Language: ENGLISH,ASCII-7-bit Path: g2news1.google.com!news2.google.com!proxad.net!feeder2-1.proxad.net!news11-e.free.fr!not-for-mail Newsgroups: comp.lang.ada Subject: Re: Ada & Postgresql References: <2prmojFo9eo1U1@uni-berlin.de> <2q2m4sFqobhgU1@uni-berlin.de> <2q2nvhFq4qqdU1@uni-berlin.de> <2q2r9tFqihj7U1@uni-berlin.de> <2q30d9Fr1gbmU1@uni-berlin.de> <413C4FFE.1010105@netcabo.pt> From: Jean-Marc Bourguet Message-ID: Date: 06 Sep 2004 17:18:47 +0200 MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Organization: Guest of ProXad - France NNTP-Posting-Date: 06 Sep 2004 17:18:49 MEST NNTP-Posting-Host: 62.189.36.28 X-Trace: 1094483929 news11-e.free.fr 2207 62.189.36.28:46360 X-Complaints-To: abuse@proxad.net Xref: g2news1.google.com comp.lang.ada:3382 Date: 2004-09-06T17:18:49+02:00 List-Id: Marius Amado Alves writes: > > ...I can't pinpoint now what annoying Ada 95 feature I was escaping back > > in 2001 when I wrote this package and its applications. Never mind. Just > > write Pgsql_Controlled. > > OK, I just took the time to write this. While I'm at it, I'll control also > Db_Type, to call Close on finalization. Oops, no, Ada 95 does not let me do > that, it makes > > function Execute (Db: Db_Type; Command: String) return Result_Type; > > illegal, because an "operation can be dispatching in only one type." The fact that all (well I'm not sure, that's so long ago that I could program in Ada, and it make me think about freezing rules that I've never really mastered) subroutines defined in the same package as a type having that type as argument or result are primitive operations is sometimes annoying, but there is an easy work around: provide it in a nested package and then use a renaming. Yours, -- Jean-Marc