change R5RS to allow splicing unquote at tail when expression is not a list; merge to 4.2.4

svn: r17811
This commit is contained in:
Matthew Flatt 2010-01-25 13:33:42 +00:00
parent aee10699ae
commit 530a3eb5e8

View File

@ -209,7 +209,9 @@
form)]
[((unquote-splicing e) . rest)
(if (zero? depth)
#`(mappend e #,(loop #'rest depth))
(if (null? (syntax-e #'rest))
#'e ;; Note: we're not check for a list
#`(mappend e #,(loop #'rest depth)))
#`(mcons (mcons 'unquote-splicing
#,(loop #'(e) (sub1 depth)))
#,(loop #'rest depth)))]