Path: utzoo!utgpu!news-server.csri.toronto.edu!rpi!zaphod.mps.ohio-state.edu!wuarchive!hsdndev!cmcl2!kramden.acf.nyu.edu!brnstnd From: brnstnd@kramden.acf.nyu.edu (Dan Bernstein) Newsgroups: comp.lang.misc Subject: Re: The search for heterogeneous lists is still on! Message-ID: <11132:Apr319:34:0291@kramden.acf.nyu.edu> Date: 3 Apr 91 19:34:02 GMT References: <167:Mar3121:32:0891@kramden.acf.nyu.edu> <49605@nigel.ee.udel.edu> Organization: IR Lines: 20 In article <49605@nigel.ee.udel.edu> new@ee.udel.edu (Darren New) writes: > In article <167:Mar3121:32:0891@kramden.acf.nyu.edu> brnstnd@kramden.acf.nyu.edu (Dan Bernstein) writes: > >Does anyone have an example of a heterogeneous list---something beyond > >unions and callback functions---used in a real program? > What about Pascal's WRITELN function? Please separate what the language > defines from the compiler's implementation of that functionality. I have never read the Pascal language definition. As far as I know, writeln can only take values of certain types, as defined beforehand by the implementation. [ further comments ] So you agree that C++, which provides the union types and callback functions (a.k.a. objects) with a reasonable syntax, suffices for everything you can think of to do with heterogeneous lists? In other words, you agree that people don't use heterogeneous lists except in ways handled by a *statically* typed language? ---Dan