Path: utzoo!utgpu!news-server.csri.toronto.edu!rutgers!usc!zaphod.mps.ohio-state.edu!lavaca.uh.edu!menudo.uh.edu!sugar!ficc!peter From: peter@ficc.ferranti.com (Peter da Silva) Newsgroups: comp.lang.misc Subject: Re: Re^2: Some things that pointer-less languages can't do efficiently Message-ID: <+CI6:YD@xds13.ferranti.com> Date: 18 Oct 90 20:35:43 GMT References: <26739:Oct1023:44:2690@kramden.acf.nyu.edu> <65450@lanl.gov> <10397:Oct1212:55:1090@kramden.acf.nyu.edu> <3975@goanna.cs.rmit.oz.au> <415@data.UUCP> Reply-To: peter@ficc.ferranti.com (Peter da Silva) Organization: Xenix Support, FICC Lines: 25 In article <415@data.UUCP> kend@data.UUCP (Ken Dickey) writes: > There are a number of programming languages, Scheme and ML among them, > which do not have a pointer abstraction. The *only* abstractions in scheme are a pair of pointers or a value. > [After programming in Scheme for a few days, no > one ever "falls off the end of a pointer chain" or "defererences a > bogus pointer"]. Sure. If you've got data in a list, say: ("da Silva" "Peter" "ferranti.com" "peter") And you accidentally return (cdr list) instead of list, you have all the problems as you do in C when you return a pointer to the middle of the array. Oh, sure, the *symptoms* are different, but when you have an object (a C pointer, or a dotted pair) that can point to any arbitrary place in any non-atomic language object (a string, or a list) you have the exact same problem. This is not to say that scheme doesn't make the consequences of falling off a list or taking the cdr of a bogus pair less dire, but claiming that languages like scheme "don't have a pointer abstraction" is going a bit far. -- Peter da Silva. `-_-' +1 713 274 5180. 'U` peter@ferranti.com