Merge branch 'master' of github.com:ashinn/chibi-scheme

This commit is contained in:
Alex Shinn 2022-05-29 08:03:48 +09:00
commit 05ee42804a
2 changed files with 11 additions and 2 deletions

View file

@ -17,8 +17,8 @@
(define fl- -) (define fl- -)
(define fl* *) (define fl* *)
(define fl/ /) (define fl/ /)
(define flmax max) (define (flmax . args) (if (null? args) -inf.0 (apply max args)))
(define flmin min) (define (flmin . args) (if (null? args) +inf.0 (apply min args)))
(define (flabsdiff x y) (abs (- x y))) (define (flabsdiff x y) (abs (- x y)))
(define flnumerator numerator) (define flnumerator numerator)
(define fldenominator denominator) (define fldenominator denominator)

View file

@ -95,4 +95,13 @@
(test -0.781212821 (flsecond-bessel 1 1.)) (test -0.781212821 (flsecond-bessel 1 1.))
(test 0.842700793 (flerf 1.)) (test 0.842700793 (flerf 1.))
(test 0.157299207 (flerfc 1.)) (test 0.157299207 (flerfc 1.))
(test #t (< 0.0
fl-least
fl-epsilon
1.0
(+ 1.0 fl-epsilon)
fl-greatest
+inf.0))
(test +inf.0 (flmin))
(test -inf.0 (flmax))
(test-end)))) (test-end))))