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=-0.5 required=5.0 tests=BAYES_00,INVALID_MSGID, PP_MIME_FAKE_ASCII_TEXT autolearn=no autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII X-Google-Thread: 103376,88e7ef9008757431 X-Google-Attributes: gid103376,public From: "Jean-Pierre Rosen" Subject: Re: Function Calls by Address Date: 1999/09/04 Message-ID: <7qt4dv$fp7$1@wanadoo.fr>#1/1 X-Deja-AN: 521238111 References: <37CADE68.6AF06F5D@escmail.orl.lmco.com> <37CEEFFA.7D73F78D@magic.fr> <7qooh7$hbh$1@nnrp1.deja.com> <37CFFEA6.921CBE59@magic.fr> <7qp8sd$u8i$1@nnrp1.deja.com> <7qpd5b$1gg$1@nnrp1.deja.com> X-Priority: 3 X-MimeOLE: Produced By Microsoft MimeOLE V5.00.2014.211 X-Complaints-To: abuse@wanadoo.fr X-Trace: wanadoo.fr 936514815 16167 193.250.194.4 (5 Sep 1999 07:00:15 GMT) Organization: Adalog X-MSMail-Priority: Normal NNTP-Posting-Date: 5 Sep 1999 07:00:15 GMT Newsgroups: comp.lang.ada Date: 1999-09-05T07:00:15+00:00 List-Id: Ted Dennison a �crit dans le message : 7qpd5b$1gg$1@nnrp1.deja.com... > I'll agree that Francois might have gone a bit overboard. But I must > confess I'm one who never has understood the "power" of separates > either. As near as I can tell, its only power is the ability to split up > cumbersome files into smaller files without having to go through the > pain of properly reencapsulating functionality into new packages. Does > it have other "powers" that I'm missing? > Pluggable modules. You can write a big library that needs some functionnality to be adjusted (depending on the OS, or whatever). If the functionnality is provided as a "separate", you can change it without even looking into the (big, complicated) library. On some systems, you would'nt even need to provide the source of the library, so a customer could provide it's own version, without being able to see your (proprietary) big library. Why not use a (child) package for that ? If the separate module needs to access global data from the package body. Note that if you are clever enough, you won't expose what the separate procedure needs not to see: package body pack is -- data visible to the separate proc goes here procedure to_be_adjusted is separate; -- data not visible to the separate proc goes here ... end pack; If you use a child package, then the "data visible" must be put in the private part of the parent, which may have other drawbacks. In short: there is certainly no definitive "best solution". The best recommendation is: "know the tools that are available, know their drawbacks and benefits, and choose the most appropriate for the task at hand on a case by case basis". -- --------------------------------------------------------- J-P. Rosen (Rosen.Adalog@wanadoo.fr) Visit Adalog's web site at http://perso.wanadoo.fr/adalog