-
Notifications
You must be signed in to change notification settings - Fork 153
Description
Hello!
From what I understand of R7RS, the templates beginning with ellipses, like (... a b c etc) are expressed as a list, but not expanded as one (that is, they should be spliced into the code generated from the template).
A template of the form
(<ellipsis> <template>)is identical to<template>, except that ellipses within the template have no special meaning
That the text says "(<ellipsis> <template>) is identical to <template>" seems to indicate that the list should be spliced (no?)
Also,
In particular, the template
(<ellipsis> <ellipsis>)produces a single<ellipsis>
seems to be concordant with that.
For example:
(define-syntax f
(syntax-rules ()
((f) '(a b (... c ... d) e))))would splice the (c ... d) list into the expanded form:
(f) => (a b c ... d e)But Chibi seems to not splice the list:
(define-syntax f
(syntax-rules ()
((f) '(a b (... c ... d) e))))
(f) => (a b (c ... d) e)unless it's a single ellipsis (?)
(define-syntax f
(syntax-rules ()
((f) '(a (... ...) b))))
(f) => (a ... b)Maybe I didn't get some detail (sorry for the noise if this is the case).