🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.lang.misc
Article #3331

Re: CHALLENGE: heterogeneous collections

#3331
From: Chip Salzenberg
Date: Mon, 01 Apr 1991 18:28
32 lines
1927 bytes
According to carroll@cis.udel.edu (Mark Carroll):
>The argument shouldn't be:
>  "I can do heterogeneous lists in a static system (using MI), so
>   since you don't need dynamic typing to do it, dynamic typing is
>   no good".
>
>The correct form of the argument is this:
>  "My staticly typed solution is a BETTER solution than your
>   dynamic one, and this is why:".

I cannot cast my argument in this form, because that's not the point
of this thread.  The original question was, "Why do you _need_
heterogenous collection?"  I have enjoyed debunking some of the
replies.

However, the heterogenous/homogenous collection issue is really a side
issue for me.  I like static typing for its measure of safety from
message-not-recognized errors.  If that forces me to use the C++
preprocessor to make collection classes, I can live with that.

>Now, in the context of this argument, I think that the dynamic solution
>under which I can iterate ANY method over a heterogeneous lists is a
>better, cleaner solution that the static solution in which I have to
>create an artificial superclass for every method that I want to use
>to iterate over the list.

Agreed, as far as it goes.  But I'm not willing to sacrifice type
safety for that notational convenience.
-- 
Chip Salzenberg at Teltronics/TCT     <chip@tct.com>, <uunet!pdn!tct!chip>
   "All this is conjecture of course, since I *only* post in the nude.
    Nothing comes between me and my t.b.  Nothing."   -- Bill Coderre
Technical Details
Message-ID: <27F77BD2.1741@tct.com>
Path: arc1-ca.pugleaf.net!utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!uunet!pdn!tscs!tct!chip
References: <objtch.670026043@extro> <27F11E1D.6354@tct.uucp> <49413@nigel.ee.udel.edu>

Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!uunet!pdn!tscs!tct!chip
From: chip@tct.com (Chip Salzenberg)
Newsgroups: comp.lang.misc
Subject: Re: CHALLENGE: heterogeneous collections
Message-ID: <27F77BD2.1741@tct.com>
Date: 1 Apr 91 18:28:34 GMT
References: <objtch.670026043@extro> <27F11E1D.6354@tct.uucp> <49413@nigel.ee.udel.edu>
Organization: Teltronics/TCT, Sarasota, FL
Lines: 32