Path: utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!wuarchive!cs.utexas.edu!ut-emx!lad-shrike!aihaug From: aihaug@AUSTIN.LOCKHEED.COM (Daniel A Haug) Newsgroups: comp.object Subject: Re: Understanding the Object-Oriented Life-Cycle Message-ID: <315@shrike.AUSTIN.LOCKHEED.COM> Date: 10 Nov 89 07:43:42 GMT References: <5026@internal.Apple.COM> Organization: Lockheed Austin Div. Lines: 39 In article <5026@internal.Apple.COM>, chewy@apple.com (Paul Snively) writes: > Speaking of criticisms, I'm interested in a good discussion on why > statically-typed hybrid languages like Object Pascal and C++ aren't useful > in some contexts where dynamically-typed languages such as Common Lisp > w/CLOS are. Any takers? Having just completed a project with 100+ thousand lines of CLOS-based code, yeah I can think of a few places where dynamic typing was useful... and a few dozen other things that would have made this project VERY hard in C++. By far (IMHO), the largest advantage to this is in code extensibility, or reusability. It is so incredibly useful to define an algorithm that doesn't care about the types on which it operates. For example, I need only implement a priority queue ADT once. The algorithm is the same, but the types can be whatever. As result, I only need to write one QUEUE and DEQUE procedure that don't depend on any typing. Then, every object that is passed into the queue would need to support some sort of comparison method that QUEUE would call to determine proper placement. Although you, Paul, have barked at people referring to Lisp as typeless (understandably), I still think of this as being an example of a typeless function. The functions QUEUE and DEQUE know nothing about the types of objects on which they are operating. This is VERY typical of the style of design in our applications. The ability to reuse major segments of code because of their `typeless' characteristics saved us man-years of effort. ---------- On a naive note, does C++ or any other C-based OO extensions support different types of method combination? In our applications, we only used this capability in CLOS a few times. However, it was immensely useful when we DID use it. -- Internet: haug@austin.lockheed.com UUCP: ut-emx!lad-shrike!aihaug