Bugfixes for pure varargs

More is still needed, but this is enough to at least get the compiler to build.
This commit is contained in:
Justin Ethier 2015-06-29 21:06:49 -04:00
parent e19ad9230f
commit 96e777743c
2 changed files with 4 additions and 2 deletions

View file

@ -913,7 +913,9 @@
(lambda->formals exp)
(lambda-formals-type exp)))
(tmp-ident (if (> (length (lambda-formals->list exp)) 0)
(mangle (car (lambda->formals exp)))
(mangle (if (pair? (lambda->formals exp))
(car (lambda->formals exp))
(lambda->formals exp)))
""))
(has-closure?
(and

View file

@ -387,7 +387,7 @@
(define (lambda-varargs-var exp)
(if (lambda-varargs? exp)
(if (equal? (lambda-formals-type exp) 'args:varargs)
(lambda-formals exp) ; take symbol directly
(lambda->formals exp) ; take symbol directly
(car (reverse (lambda-formals->list exp)))) ; Last arg is varargs
#f))