comp.lang.ada
 help / color / mirror / Atom feed
* Re: Fragile base dependency problem
       [not found] <01bc7f8f$47640780$cfe4a6ce@camden>
@ 1997-06-23  0:00 ` Tucker Taft
  1997-06-24  0:00 ` Jon S Anthony
  1 sibling, 0 replies; 2+ messages in thread
From: Tucker Taft @ 1997-06-23  0:00 UTC (permalink / raw)



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




^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: Fragile base dependency problem
       [not found] <01bc7f8f$47640780$cfe4a6ce@camden>
  1997-06-23  0:00 ` Fragile base dependency problem Tucker Taft
@ 1997-06-24  0:00 ` Jon S Anthony
  1 sibling, 0 replies; 2+ messages in thread
From: Jon S Anthony @ 1997-06-24  0:00 UTC (permalink / raw)



In article <01bc7f8f$47640780$cfe4a6ce@camden> "Dave Smith" <dksmith@traveller.com> writes:

> 	I continually run into the classic "fragile base class"
> problem as both a client and server of package libraries.

Without the details it is hard to comment productively.  But, from
what you say it sounds like the units are not sufficiently small and
decoupled.


> 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.

For example, I never seem to face this sort of problem.


> Is there an appropriate way to tackle this problem in Ada?

Most likely.  But there may be something about your situation that
makes the problem particularly difficult.  In general, if you are
careful about the "granularity" of the units and their coupling, this
will not be a problem.


>  Is this problem a result of the design of gnat, or the
> Ada language itself?

This sort of thing is always present in some degree in a strongly
statically checked language.  You can get incremental compilation
implementations which pretty much eliminate it.  GNAT is not of this
ilk, but really I don't think GNAT is the problem here either.


>  Does Java avoid this problem?  (I've been told it does...)

Not particularly.


>  If so, does it avoid the problem b/c it's an interpreted language?

Java is not interpreted - well, I don't know of any such
implementations.  Typical implemenations compile to byte code (J-Code)
which is executed by a JVM.


>  If this is the case, how will Ada survive as interpreted languages
> become more and more practical?

"Interpreted languages" have always been practical for their uses.
More importantly, dynamically typed languages have been.  Java brings
nothing new here at all.

/Jon
-- 
Jon Anthony
OMI, Belmont, MA 02178
617.484.3383
"Nightmares - Ha!  The way my life's been going lately,
 Who'd notice?"  -- Londo Mollari




^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~1997-06-24  0:00 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
     [not found] <01bc7f8f$47640780$cfe4a6ce@camden>
1997-06-23  0:00 ` Fragile base dependency problem Tucker Taft
1997-06-24  0:00 ` Jon S Anthony

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox