Reuse `case-lambda' syntax in optimizer.

original commit: d6f1c35e1b615e3fc554e310de7ba2bb18217dd6
This commit is contained in:
Sam Tobin-Hochstadt 2011-08-23 12:07:26 -04:00
parent 4a3fbfd4ca
commit d81dd2f811

View File

@ -49,7 +49,7 @@
(cons (car l)
(map (optimize) (cdr l)))))
#'([formals e ...] ...))
#:with opt (syntax/loc/origin this-syntax #'op (case-lambda opt-parts ...)))
#:with opt (syntax/loc/origin this-syntax #'op (op opt-parts ...)))
(pattern ((~and op (~or (~literal let-values) (~literal letrec-values)))
([ids e-rhs:expr] ...) e-body:expr ...)
#:with (opt-rhs ...) (syntax-map (optimize) #'(e-rhs ...))