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,8f5aa913d843e013 X-Google-Attributes: gid103376,public From: stt@houdini.camb.inmet.com (Tucker Taft) Subject: Re: Fragile base dependency problem Date: 1997/06/23 Message-ID: #1/1 X-Deja-AN: 252078673 Sender: news@inmet.camb.inmet.com (USENET news) X-Nntp-Posting-Host: houdini.camb.inmet.com References: <01bc7f8f$47640780$cfe4a6ce@camden> Organization: Intermetrics, Inc. Newsgroups: comp.lang.ada Date: 1997-06-23T00:00:00+00:00 List-Id: Dave Smith (dksmith@traveller.com) wrote: : I develop Ada 95 software on a US Army project : (SG platform using gnat). My portion of the system is approx. : 10K LOC. I depend on several package libraries (comm, : math, GUI, etc.) written by others in the project. I have also : recently started developing a class hierarchy that should : be useful to others on the project. : I continually run into the classic "fragile base class" : problem as both a client and server of package libraries. : With package libraries that I'm a client of, I must periodically : recompile *almost everything* b/c some little minute detail (which : I don't ACTUALLY depend on) changed in a package library. : As a server of a new class hierarchy, I get people : coming to me complaining b/c they needed to recompile : after I've made improvements/modifications. The dilemma : I face is... : Does my software have to be perfect before I : let others use it? : Is there an appropriate way to tackle this problem : in Ada? Is this problem a result of the design of gnat, or the : Ada language itself? Does Java avoid this problem? (I've : been told it does...) If so, does it avoid the problem b/c it's : an interpreted language? No, Java avoids the problem by doing class field/method-descriptor layout at dynamic link time rather than at compile-time. : ... If this is the case, how will Ada : survive as interpreted languages become more and more : practical? AppletMagic(tm), our Ada95 => Java-byte-code compiler has the same capability, namely that you don't need to recompile to use a new class file for an ancestor type. On the other hand, our compiler is so fast, that you may still prefer to recompile whenever any of the source file "dependees" change, just to get that added confidence of redoing the compile-time interface checking. Note that SGI sells a version of their C++ compiler (called "Delta C++") that performs essentially the same trick as Java, by doing class layout at link-time. This approach is certainly compatible with Ada 95 as well (as demonstrated by AppletMagic). : Thanks, : Dave Smith : dksmith@traveller.com -- -Tucker Taft stt@inmet.com http://www.inmet.com/~stt/ Intermetrics, Inc. Burlington, MA USA