summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--libguile/ChangeLog1
-rw-r--r--libguile/num2float.i.c4
-rw-r--r--libguile/numbers.c2
3 files changed, 6 insertions, 1 deletions
diff --git a/libguile/ChangeLog b/libguile/ChangeLog
index 525562c39..c0430a5b2 100644
--- a/libguile/ChangeLog
+++ b/libguile/ChangeLog
@@ -1,6 +1,7 @@
2002-08-29 Han-Wen Nienhuys <hanwen@cs.uu.nl>
* numbers.c (scm_make_real): prevent reordering of statements
+ num2float.i.c (FLOAT2NUM): idem
2002-08-27 Han-Wen Nienhuys <hanwen@cs.uu.nl>
diff --git a/libguile/num2float.i.c b/libguile/num2float.i.c
index b393ba9b7..5fd9180c7 100644
--- a/libguile/num2float.i.c
+++ b/libguile/num2float.i.c
@@ -33,6 +33,10 @@ FLOAT2NUM (FTYPE n)
{
SCM z;
z = scm_double_cell (scm_tc16_real, 0, 0, 0);
+ /*
+ See scm_make_real().
+ */
+ scm_remember_upto_here_1 (z);
SCM_REAL_VALUE (z) = n;
return z;
}
diff --git a/libguile/numbers.c b/libguile/numbers.c
index ebdacdc8f..8393c62ca 100644
--- a/libguile/numbers.c
+++ b/libguile/numbers.c
@@ -3021,7 +3021,7 @@ scm_make_real (double x)
OK to interchange the initialization above and the one below. We
don't want that, of course.
*/
- scm_remember_1 (z);
+ scm_remember_upto_here_1 (z);
SCM_REAL_VALUE (z) = x;
return z;
}