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,56250291936154a0 X-Google-Attributes: gid103376,public From: "Tarjei T. Jensen" Subject: Re: OS Bindings (was: Where is the elusive jump command?) Date: 2000/04/07 Message-ID: <8ck638$krs3@ftp.kvaerner.com>#1/1 X-Deja-AN: 607912796 Content-Transfer-Encoding: 7bit References: <38D771CA.D41AF9B5@port.ac.uk> <8bq7ku$mc8$1@nnrp1.deja.com> <38E0E723.C39C392@quadruscorp.com> <8brfm4$4uc$1@nnrp1.deja.com> <8brn4k$p6i$1@slb0.atl.mindspring.net> <8brrpj$i04$1@nnrp1.deja.com> <38E312F8.78883ACB@icn.siemens.de> <8c4rvf$d9k$1@nnrp1.deja.com> <2000Apr5.070127.1@eisner> <2000Apr6.081305.1@eisner> <8ci6vf$r5a$1@nnrp1.deja.com> Content-Type: text/plain; charset="iso-8859-1" X-MimeOLE: Produced By Microsoft MimeOLE V4.72.2120.0 Organization: Kv�rner Group IT Mime-Version: 1.0 Newsgroups: comp.lang.ada Date: 2000-04-07T00:00:00+00:00 List-Id: Robert Dewar wrote >Many functions can be done using the portable POSIX interface. >This is desirable where possible, since it avoids the nasty >trap that particularly VMS programmers get stuck in of doing >everything with Starlet and building completely non-portable >programs. Many of these Starlet functions could perfectly >well be performed using a good posix interface. > >Other bindings to well established interface sets are also >generally available, and these are largely portable. In addition >every compiler comes with various operating system interfaces >that are not necessarily portable to other Ada compilers. They may be portable, but the bindings I have seen tend to do certain things the wrong way around. Every time there is an unsigned type like size_t it is translated to a modular type. This is just plain wrong. One have to differentiate between an unsigned type which contains a set of flags and legitimate unsigned types which may be used in arithmetic expressions. A good example of this is the definitions in the interfaces.C. The unsigned types are really useless and undermines the type safety we should expect from Ada. These definitions fails completely to capture the spirit of the usage in C. The modular types should have been named something like unsigned__flags or something to that effect. Then the purpose and meaning would be clear and we would avoid the bungle which is the present standard. It anoys me no end that I did not catch this during the review process. I really should have noticed. Greetings,