mirror of
https://github.com/ashinn/chibi-scheme.git
synced 2025-05-19 05:39:18 +02:00
remove superfluous + when printing complex numbers with negative ratio imaginary parts
This commit is contained in:
parent
05ca40fa51
commit
8247e13baf
1 changed files with 8 additions and 5 deletions
|
@ -1046,7 +1046,10 @@ SEXP_API sexp sexp_make_unsigned_integer(sexp ctx, sexp_luint_t x);
|
||||||
#define sexp_negativep(x) (sexp_exact_negativep(x) || \
|
#define sexp_negativep(x) (sexp_exact_negativep(x) || \
|
||||||
(sexp_flonump(x) && sexp_flonum_value(x) < 0))
|
(sexp_flonump(x) && sexp_flonum_value(x) < 0))
|
||||||
#define sexp_positivep(x) (!(sexp_negativep(x)))
|
#define sexp_positivep(x) (!(sexp_negativep(x)))
|
||||||
#define sexp_pedantic_negativep(x) (sexp_exact_negativep(x) || \
|
#define sexp_pedantic_negativep(x) ( \
|
||||||
|
sexp_exact_negativep(x) || \
|
||||||
|
(sexp_ratiop(x) && \
|
||||||
|
sexp_exact_negativep(sexp_ratio_numerator(x))) || \
|
||||||
(sexp_flonump(x) && \
|
(sexp_flonump(x) && \
|
||||||
((sexp_flonum_value(x) < 0) || \
|
((sexp_flonum_value(x) < 0) || \
|
||||||
(sexp_flonum_value(x) == 0 && \
|
(sexp_flonum_value(x) == 0 && \
|
||||||
|
|
Loading…
Add table
Reference in a new issue