Newsgroups: comp.lang.beta,comp.lang.lisp Path: news.daimi.aau.dk!news.uni-c.dk!sunic!trane.uninett.no!eunet.no!nuug!EU.net!uunet!brunix!cs!rv From: rv@cs.brown.edu (rodrigo vanegas) Subject: Re: Comparison: Beta - Lisp In-Reply-To: haible@ma2s2.mathematik.uni-karlsruhe.de's message of 9 Sep 1994 15:50:06 GMT Content-Type: text/plain Message-ID: Sender: news@cs.brown.edu Organization: Dept. of Computer Science, Brown University References: <34n2qe$d74@nz12.rz.uni-karlsruhe.de> <34q07e$n16@nz12.rz.uni-karlsruhe.de> Mime-Version: 1.0 Date: Fri, 9 Sep 1994 17:25:10 GMT Lines: 36 Xref: news.daimi.aau.dk comp.lang.beta:22 comp.lang.lisp:13175 In article <34q07e$n16@nz12.rz.uni-karlsruhe.de>, haible@ma2s2.mathematik.uni-karlsruhe.de (Bruno Haible) writes: >> So what are these "patterns" anyway? It sounds as if they are very >> close if not identical to lisp closures. After all, can't each of the >> above lisp stuff can be implemented as sugar for closures. > From the point of view of a Lisp programmer, a pattern consists of > > * a specification of variables (call them "variables" or "closure variables" > or "slots"), and > > * a piece of code which is executed after the storage for the variables has > been allocated (call it "initialization method" or simply "program"). Ok, so consider the following: (lambda (x y) (print "whatever...") (funcall x y)) This lambda abstraction, which evaluates to a closure, has "a specification of variables", X and Y, and "a piece of code which is executed after the storage for the variables has been allocated", the PRINT followed by the FUNCALL. I don't see any difference yet... > But that's only one of many aspects of patterns... Why is it that every explanation of patterns i've come across so far always includes a "more to come" disclaimer at the end?! I'm beginning to wonder if these so called "patterns" can be defined at all! rodrigo "tired of playing detective" vanegas rv@cs.brown.edu