Email list hosting service & mailing list manager

Alternative formulations of keywords John Cowan (11 Apr 2006 22:35 UTC)
Re: Alternative formulations of keywords Marc Feeley (12 Apr 2006 01:58 UTC)
Re: Alternative formulations of keywords John Cowan (12 Apr 2006 02:54 UTC)
Re: Alternative formulations of keywords Per Bothner (12 Apr 2006 03:05 UTC)
Re: Alternative formulations of keywords John Cowan (12 Apr 2006 03:12 UTC)
Re: Alternative formulations of keywords Eli Barzilay (12 Apr 2006 03:17 UTC)
Re: Alternative formulations of keywords Eli Barzilay (12 Apr 2006 03:20 UTC)
Re: Alternative formulations of keywords John Cowan (12 Apr 2006 03:27 UTC)
Re: Alternative formulations of keywords Per Bothner (12 Apr 2006 03:20 UTC)
Re: Alternative formulations of keywords Marc Feeley (12 Apr 2006 04:20 UTC)
Re: Alternative formulations of keywords John Cowan (12 Apr 2006 04:32 UTC)
Re: Alternative formulations of keywords Marc Feeley (12 Apr 2006 05:11 UTC)
Re: Alternative formulations of keywords John Cowan (12 Apr 2006 12:16 UTC)
Re: Alternative formulations of keywords Eli Barzilay (12 Apr 2006 12:29 UTC)
Re: Alternative formulations of keywords Marc Feeley (12 Apr 2006 13:07 UTC)
Re: Alternative formulations of keywords John Cowan (12 Apr 2006 13:36 UTC)
Re: Alternative formulations of keywords Marc Feeley (12 Apr 2006 14:25 UTC)
Re: Alternative formulations of keywords John Cowan (12 Apr 2006 14:28 UTC)
Re: Alternative formulations of keywords Marc Feeley (12 Apr 2006 14:57 UTC)
Re: Alternative formulations of keywords John Cowan (12 Apr 2006 16:26 UTC)
Re: Alternative formulations of keywords Per Bothner (12 Apr 2006 16:49 UTC)
Re: Alternative formulations of keywords John Cowan (12 Apr 2006 16:56 UTC)
Re: Alternative formulations of keywords Eli Barzilay (12 Apr 2006 13:37 UTC)
Re: Alternative formulations of keywords Marc Feeley (12 Apr 2006 04:54 UTC)
Re: Alternative formulations of keywords John Cowan (12 Apr 2006 16:07 UTC)

Alternative formulations of keywords John Cowan 11 Apr 2006 22:35 UTC

Here are two alternative formulations of keywords, both based on the
idea that keywords are pure syntax, with no representation at run time.

1) Keyword-value arguments are sorted into order corresponding to
the alphabetical order of the keywords.  Thus  (foo 'bar foo: 32 bar: 54)
comes out at run time as (foo 'bar 54 32).  Similar treatment is
given to keywords in lambda lists.  (Note: forcer came up with this
one independently.)

2) Keywords are syntactic sugar for a single argument in the form of an
a-list.  This maps (foo 'bar foo: 32 bar: 54) to
(foo 'bar '((foo: . 32) (bar: . 54))).  Keywords in lambda lists are
initialized by unpacking the a-list when the procedure is invoked.

--
John Cowan                                <xxxxxx@ccil.org>
Yakka foob mog.  Grug pubbawup zink wattoom gazork.  Chumble spuzz.
    -- Calvin, giving Newton's First Law "in his own words"