mirror of
https://github.com/ashinn/chibi-scheme.git
synced 2025-07-07 05:06:37 +02:00
fixing rest parsing
This commit is contained in:
parent
014aa253d1
commit
28d119426c
1 changed files with 13 additions and 13 deletions
|
@ -541,11 +541,10 @@ div#footer {padding-bottom: 50px}
|
|||
(lp (cdr ls) (cons (cons (car ls) i) vars) (+ i 1)))
|
||||
(else
|
||||
(extract body vars i)))))
|
||||
(else
|
||||
(let ((opts (map car (sort vars < cdr)))
|
||||
(rest-var? (contains? x o)))
|
||||
(append (reverse pre)
|
||||
(cond
|
||||
(_
|
||||
(let* ((opts (map car (sort vars < cdr)))
|
||||
(rest-var? (contains? x o))
|
||||
(tail (cond
|
||||
((and (pair? opts) rest-var?)
|
||||
(list (append opts o)))
|
||||
(rest-var?
|
||||
|
@ -553,7 +552,8 @@ div#footer {padding-bottom: 50px}
|
|||
((pair? opts)
|
||||
(list opts))
|
||||
(else
|
||||
'()))))))))))))
|
||||
o))))
|
||||
(append (reverse pre) tail))))))))))
|
||||
|
||||
(define (get-procedure-signature mod id proc)
|
||||
(protect (exn (else '()))
|
||||
|
|
Loading…
Add table
Reference in a new issue