void-packages/srcpkgs/sagemath/patches/36235-ecl_23.9.9.patch

40 lines
1.2 KiB
Diff

diff --git a/src/sage/libs/ecl.pyx b/src/sage/libs/ecl.pyx
index 8f46570313d..a8e73e57b52 100644
--- a/src/sage/libs/ecl.pyx
+++ b/src/sage/libs/ecl.pyx
@@ -563,15 +563,15 @@ cdef class EclObject:
Floats in Python are IEEE double, which LISP has as well. However,
the printing of floating point types in LISP depends on settings::
- sage: a = EclObject(float(10^40))
+ sage: a = EclObject(float(1.234e40))
sage: ecl_eval("(setf *read-default-float-format* 'single-float)")
<ECL: SINGLE-FLOAT>
sage: a
- <ECL: 1.d40>
+ <ECL: 1.234d40>
sage: ecl_eval("(setf *read-default-float-format* 'double-float)")
<ECL: DOUBLE-FLOAT>
sage: a
- <ECL: 1.e40>
+ <ECL: 1.234e40>
Tuples are translated to dotted lists::
diff --git a/src/sage/libs/eclsig.h b/src/sage/libs/eclsig.h
index e249ccf6874..005b2d99d0b 100644
--- a/src/sage/libs/eclsig.h
+++ b/src/sage/libs/eclsig.h
@@ -45,7 +45,11 @@ static inline void ecl_sig_off(void)
sig_off();
}
+#if ECL_VERSION_NUMBER < 230909
#define ecl_mpz_from_bignum(obj) ((obj)->big.big_num)
+#else
+#define ecl_mpz_from_bignum(obj) ecl_bignum(obj)
+#endif
cl_object ecl_bignum_from_mpz(mpz_t num)
{