Path: utzoo!attcan!uunet!mcsun!ukc!dcl-cs!aber-cs!athene!pcg From: pcg@cs.aber.ac.uk (Piercarlo Grandi) Newsgroups: comp.lang.lisp Subject: Re: Virtues of Lisp syntax Message-ID: Date: 23 Sep 90 18:28:29 GMT References: <33709@cup.portal.com> <1990Sep10.091911.20877@hellgate.utah.edu> <1990Sep18.002137.10940@cbnewsc.att.com> Sender: pcg@aber-cs.UUCP Organization: Coleg Prifysgol Cymru Lines: 48 Nntp-Posting-Host: teachc In-reply-to: peter@ficc.ferranti.com's message of 22 Sep 90 15:35:21 GMT On 22 Sep 90 15:35:21 GMT, peter@ficc.ferranti.com (Peter da Silva) said: peter> In article , peter> pcg@cs.aber.ac.uk (Piercarlo Grandi) writes: pcg> The real challenge here is that we want some syntax that says, pcg> apply this operator symbol to these arguments and return these pcg> value_s_. Even lisp syntax does not really allow us to easily pcg> produce multiple values. In other words there is some difference between say (f (a b c d e)) vs. (f a b c d e) (return (a b c)) vs. (return a b c) For example, (lambda (x y) (list (div x y) (rem x y))) could be rewritten as (lambda (x y) (div x y) (rem x y)) if we removed the implicit-progn rule. But this opens up other questions... peter> I may be being more than usually dense, here, but what's wrong peter> with returning a list? What could be more natural? That it is not returning multiple values -- it is returning a single value. You can always get out of the multiple value difficulty like that. Unfortunately it is also a good reason to also require functions to have a single parameter. Maybe this is the right way to do things, or maybe a function over a cartesian product or a curried function is not quite the same thing as a function over a list. One argument I could make is that Aleph or Forth seem to handle, each in their way, the multiple-parameter/multiple-result problem more elegantly, in a more fundamental way than passing around lists and multiple-bind. The effect may be largely the same, though. -- Piercarlo "Peter" Grandi | ARPA: pcg%uk.ac.aber.cs@nsfnet-relay.ac.uk Dept of CS, UCW Aberystwyth | UUCP: ...!mcsun!ukc!aber-cs!pcg Penglais, Aberystwyth SY23 3BZ, UK | INET: pcg@cs.aber.ac.uk