🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.lang.misc
Article #3397

Re: Run-time Type Errors in Smalltalk (was Re: blip (was...))

#3397
From: Steve Olson
Date: Sat, 06 Apr 1991 17:26
37 lines
2809 bytes
In article <887@puck.mrcu> paj@mrcu (Paul Johnson) writes:
   Does anyone have any facts relating to the assertion that run-time
   failures due to type errors are rare in Smalltalk development?

For years I have been using an object-oriented Lisp (Flavors) to do
things like real-time interpretation of weather radar imagery.  For
the purpose of this discussion Lisp plus Flavors is probably equivalent
to Smalltalk.  These systems have been deployed at several radar sites
scattered across the country for several years.  My only possible reply
is "huh, whats a type error?"  Oh yes! I remember now - a type error is
what happens when you are programming in C and you screw up a cast.  

Seriously, I get the "message not understood" error from time to time, but
99 times out of a hundred, the problem is caught on the first or second
test run.  The other 1 out of hundred?  Well, I still get to diagnose and
fix the problem almost instantly because of the usually informative error
messages.  Much better than the mystery core dump.  I get things which look
like type errors when try to perform math on 'nil' for example, but thats
almost always because I have forgotten to properly calculate the value
of some slot.  Getting a type error in those cases is in fact a tremendous
help over what would happen in a typical statically typed language.

In my opinion, the biggest practical problem with dynamically typed languages
is that it is a pain in the butt to lug around the run time envirnoment.
To run a 1 page Common Lisp program on a UNIX system means I have to fire up a
multi-megabyte run time system which consumes vast amounts of core and virtual
memory.  Yuk.  There are lighter-weight alternatives to Common Lisp, of course,
but you're still going to have some extra baggage to lug around.

People who get endlessly alarmed about the alleged lack of type saftey in
a dynamically-typed languge are not well-informed about how Lisp or Smalltalk
software development actually works.

- Steve Olson
  MIT Lincoln Laboratory
  olson@juliet.ll.mit.edu
Technical Details
Message-ID: <OLSON.91Apr6172626@lear.juliet.ll.mit.edu>
Path: arc1-ca.pugleaf.net!utzoo!utgpu!news-server.csri.toronto.edu!rpi!zaphod.mps.ohio-state.edu!think.com!ames!xn.ll.mit.edu!xn!olson
References: <3523:Mar1803:21:0591@kramden.acf.nyu.edu> <22032@yunexus.YorkU.CA> <14160@life.ai.mit.edu> <1991Mar25.201620.5839@cua.cary.ibm.com> <879@puck.mrcu> <PX.91Apr1225918@hal.fct.unl.pt> <887@puck.mrcu>

Show Full Headers
Complete Article Headers
Newsgroups: comp.lang.misc,comp.object
Path: arc1-ca.pugleaf.net!utzoo!utgpu!news-server.csri.toronto.edu!rpi!zaphod.mps.ohio-state.edu!think.com!ames!xn.ll.mit.edu!xn!olson
From: olson@lear.juliet.ll.mit.edu ( Steve Olson)
Subject: Re: Run-time Type Errors in Smalltalk (was Re: blip (was...))
In-Reply-To: paj@mrcu's message of 4 Apr 91 09:00:14 GMT
Message-ID: <OLSON.91Apr6172626@lear.juliet.ll.mit.edu>
Sender: usenet@xn.ll.mit.edu
Organization: M.I.T. Lincoln Lab - Group 43
References: <3523:Mar1803:21:0591@kramden.acf.nyu.edu> <22032@yunexus.YorkU.CA>
 <14160@life.ai.mit.edu> <1991Mar25.201620.5839@cua.cary.ibm.com>
 <879@puck.mrcu> <PX.91Apr1225918@hal.fct.unl.pt> <887@puck.mrcu>
Date: 6 Apr 91 17:26:26