Email list hosting service & mailing list manager

Or Alternatively ... ? Paul Schlie (08 Apr 2006 14:55 UTC)
Re: Or Alternatively ... ? Marcin 'Qrczak' Kowalczyk (08 Apr 2006 15:27 UTC)
Re: Or Alternatively ... ? Paul Schlie (08 Apr 2006 17:19 UTC)

Or Alternatively ... ? Paul Schlie 08 Apr 2006 14:55 UTC

Possibly extend the definition of procedural evaluation to allow the
syntactic decomposition of a list of values into a sequence of values
then evaluated as arguments, in a manner somewhat analogous to the use
of unquote-splicing to enable:

  (<proc> . (<value> ...) ...) :: (<proc> <value> ...)

Such that doted arguments are evaluated and spliced prior to procedural
evaluation:

  (define some-values '(1 2 3))

  (+ . some-values) :: (+ 1 2 3) => 6

  (+ . some-values . '(10 20)) :: (+ 1 2 3 10 20) => 36

Where then further:

  (let ([(a . b) some-values]) (+ a . b . '(10 20))) => 36

  (+ . some-values . (lambda () (list 10 20))) => 36

And correspondingly:

  (define (function-values) (list 10 20))

  (+ . some-values . (function-values)) :: (+ 1 2 3 10 20) => 36

Thereby enabling the (values ...) construct et al. to be eliminated.