Path: utzoo!utgpu!news-server.csri.toronto.edu!rpi!zaphod.mps.ohio-state.edu!sdd.hp.com!think.com!paperboy!hsdndev!cmcl2!kramden.acf.nyu.edu!brnstnd From: brnstnd@kramden.acf.nyu.edu (Dan Bernstein) Newsgroups: comp.lang.misc Subject: Re: CHALLENGE: heterogeneous collections Message-ID: <25655:Mar2803:50:2491@kramden.acf.nyu.edu> Date: 28 Mar 91 03:50:24 GMT References: <48805@nigel.ee.udel.edu> <7689:Mar2623:28:5091@kramden.acf.nyu.edu> <49087@nigel.ee.udel.edu> Organization: IR Lines: 45 In article <49087@nigel.ee.udel.edu> new@ee.udel.edu (Darren New) writes: > Am I crazy, or isn't (void *) impossible to indirect? Don't you have > to type-cast it first? Isn't this dynamic typing implemented on top of > C? YES. People are tossing around the term ``dynamic typing'' as if it were some truly important feature. ``Yeah, Bob, not only does the language have *loops*, but it has *dynamic typing*!'' ``Wow! *Dynamic typing*? Really?'' Dynamic typing isn't a semantic feature. It's a state of mind. If you want to use the pair (type,value) as a value with certain constraints, you can, whether the language supports it or not. It takes at most a good preprocessor to make this just as convenient as in any ``dynamically typed'' language. I accept that people want to use dynamic typing now and then. Fine! What I'm reacting to is this delusion that you need dynamic typing in the language to use it conveniently. Sure, I use associative arrays now and then, and I have an associative array library for the job. Why should I want the language to support associative arrays directly? > Do you > really think that I, like you, willfully misinterpret what is being > said to support a different point of view without trying either to make > a point or learn something from somebody else? Look, kid, I'm not misinterpreting what's being said here. People are saying that languages with built-in support for dynamic typing are somehow better than languages without such support. I'm reacting to that statement. On the occasions when I want dynamically typed variables, I can use them without trouble in C. Sure, this requires a void pointer type. SO WHAT? As I pointed out when I entered this discussion, the language does need *some* type that can represent *all* values if it's going to support dynamic typing. C has such a type, and adequate macros, and that's enough for me to get work done. *You* are misinterpreting my comments as something like ``Dynamic typing is useless. Anyone who wants to use dynamic typing is a fool.'' I'm just saying that it's pointless to have the compiler support dynamic typing, as it's just as easy to do in a library. ---Dan