bug-guile
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: A passing test case


From: Neil Jerram
Subject: Re: A passing test case
Date: Sat, 26 Jan 2008 18:58:30 +0000
User-agent: Gnus/5.110006 (No Gnus v0.6) Emacs/21.4 (gnu/linux)

Gregory Marton <address@hidden> writes:

> The differences are not significant.  I guess I wanted to make clear
> in the test case that this isn't something to do with literal
> rationals, and I didn't want the test case to be printing things to
> the console.

OK, thanks for explaining that.  I assume that this test relates to
the following NEWS item (for 1.8.2):

** Fractions were not `equal?' if stored in unreduced form.
(A subtle problem, since printing a value reduced it, making it work.)

But doesn't that mean that your test needs to use an unreduced
fraction, e.g. 2/4 instead of 1/2 ?

(Or does Guile have a strange idea of reduction which means that 1/2
is not already a reduced form?)

Regards,
        Neil

>>> --- test-suite/tests/fractions.test.1.8.3   2008-01-25 20:08:57.000000000 
>>> -0500
>>> +++ test-suite/tests/fractions.test 2008-01-25 20:09:07.000000000 -0500
>>> @@ -400,3 +400,8 @@
>>>  (with-test-prefix "fraction generics"
>>>    (testeq (G 1) 'integer)
>>>    (testeq (G 2/3) 'fraction))
>>> +
>>> +(pass-if (let ((x (/ 1 2)))
>>> +      (with-output-to-string (lambda () (display x)))
>>> +      (equal? x (/ 1 2))))
>>> +





reply via email to

[Prev in Thread] Current Thread [Next in Thread]