fix lambdas and add a test to prevent rotting
Lambdas rotted because there wasn't any test for them, and after return type moved to the end, lambdas stayed assumning it in the front. We fix this and add test program
This commit is contained in:
@@ -380,8 +380,8 @@ forms, and what remains."
|
||||
(map arg-type (remove comment-form? form)))
|
||||
|
||||
(define (walk-function form)
|
||||
;; (fn ret-type name arglist body) -> normal function
|
||||
;; (fn ret-type name arglist) -> prototype
|
||||
;; (fn name arglist ret-type body) -> normal function
|
||||
;; (fn name arglist ret-type) -> prototype
|
||||
(if (>= (length form) 5)
|
||||
(walk-fn-def form)
|
||||
(cons '%prototype (cdr (walk-fn-def form)))))
|
||||
|
||||
Reference in New Issue
Block a user