[plt-scheme] Smallest set of operators

From: hendrik at topoi.pooq.com (hendrik at topoi.pooq.com)
Date: Fri Feb 2 15:50:34 EST 2007

On Fri, Feb 02, 2007 at 07:13:08PM +0000, Paulo J. Matos wrote:
> On 2/2/07, Dave Griffiths <dave at pawfal.org> wrote:
> >
> >I found this an interesting read when pondering such questions myself:
> >http://www.paulgraham.com/rootsoflisp.html
> >
> >The answer does seem to be around 7...
> >
> Well, I have already read that some years ago... hummf, maybe that's
> where my '7' came from... heh. But if I remember correctly that was
> more directed to Lisp / Common Lisp than Scheme itself. Well, better
> read it again. Thank you for the reference.

A few nits -- if you want primitives for Scheme, you'll need lambda to 
work a little differently, so that you get to write

((lambda (f) (f '(b c)))
  (lambda (x) (cons 'a x)))

instead of

((lambda (f) (f '(b c)))
  '(lambda (x) (cons 'a x)))

Second, if you want to be practical, you'll need some mechanism of 
interacting with the real world -- some form of input and output.  Yes, 
possibly a few functions with so-called "side-effects".

You might also be interested in looking at Guy Lewis Steele's master's 
thesis, which describes Rabbit, a compiler for Scheme.  I consider it 
one of the more inspiring compilers ever written.

-- hendrik

Posted on the users mailing list.