rebirth: relibprebirth: Negate unary -

* build-aux/bootstrap/rebirth/relibprebirth.scm (-): Negate when given only
    a single argment.
master
Mike Gerwitz 2018-09-10 20:53:13 -04:00
parent 6daa3501b6
commit a76327ca0f
Signed by: mikegerwitz
GPG Key ID: 8C917B7F5DC51BA2
1 changed files with 6 additions and 4 deletions

View File

@ -142,10 +142,12 @@
0
xs))
(define (- . xs)
(fold (lambda (y x)
(string->es "$$x - $$y"))
(car xs)
(cdr xs)))
(if (= (length xs) 1)
(- 0 (car xs))
(fold (lambda (y x)
(string->es "$$x - $$y"))
(car xs)
(cdr xs))))
(define (zero? x)
(eq? x 0))