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,3ccb707f4c91a5f2 X-Google-Attributes: gid103376,public From: Ken Garlington Subject: Re: Once again, Ada absent from DoD SBIR solicitation Date: 1996/10/14 Message-ID: <32625233.6EF9@lmtas.lmco.com>#1/1 X-Deja-AN: 189407459 references: content-type: text/plain; charset=us-ascii organization: Lockheed Martin Tactical Aircraft Systems mime-version: 1.0 newsgroups: comp.lang.ada x-mailer: Mozilla 2.02 (Macintosh; I; 68K) Date: 1996-10-14T00:00:00+00:00 List-Id: Mitch Gart wrote: > > In this particular case, I also think it goes beyond a personal opinion, > I think the Ada notation > > pkg1.func(obj) > > is actively misleading when the code that will be executed at runtime is in the > body of pkg2. It's not just "Which you prefer to look at". Note that this can occur in Ada 83, or for that matter other non-dispatching languages. For example: with Foo; package body Pkg1 is function func ( op : a_type ) return func_type is begin return Foo.Some_Other_Function(op); end; end; So, the call to func in fact causes some other code to be executed at runtime. In fact, with a good optimizer, the caller of func may in fact end up with a direct call to Some_Other_Function in the object code. So, if you want to make these calls explicit, you have to have a coding convention (in Ada, FORTRAN, C, etc.) that prohibits such "wrappers". Of course, as you pointed out earlier, you can eliminate the "confusion" of dispatching by removing the package name via a use clause. If you've read some coding standard that says "don't use Ada in this manner," and you choose to follow that standard, that's your problem -- not the language! > > - Mitch -- LMTAS - "Our Brand Means Quality" For more info, see http://www.lmtas.com or http://www.lmco.com