GNU bug report logs - #20945
One guile test failed

Previous Next

Package: guile;

Reported by: Christopher White <ceedave <at> me.com>

Date: Tue, 30 Jun 2015 20:05:03 UTC

Severity: normal

Done: Andy Wingo <wingo <at> pobox.com>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: Andy Wingo <wingo <at> pobox.com>
To: Christopher White <ceedave <at> me.com>
Cc: 20945 <at> debbugs.gnu.org
Subject: bug#20945: One guile test failed
Date: Fri, 24 Jun 2016 09:16:02 +0200
Thanks for the report.

On Tue 30 Jun 2015 21:43, Christopher White <ceedave <at> me.com> writes:

> For your information, make check produced one error, on OS X Yosemite.
>
> FAIL: numbers.test: string->number: valid complex number strings

Does this still happen for you?

If so, can you paste this at a REPL or in a file and see what it prints
out?

    (for-each (lambda (triple)
                (apply
                 (lambda (str re im)
                   (let ((z (string->number str)))
                     (if (or (eq? z #f)
                             (not (and (eqv? (real-part z) re)
                                       (eqv? (imag-part z) im))))
			 (begin 
			   (pk str re im)
			   (throw 'fail)))))
                 triple))
              `(("1 <at> 0" 1 0) ("1@+0" 1 0) ("1@-0" 1 0) ("1/2 <at> 0" 1/2 0)
                ("1.0 <at> 0" 1.0 0) ("1.0@-0" 1.0 0)
                ("#e1 <at> 0" 1 0) ("#e1@+0" 1 0) ("#e1@-0" 1 0) ("#e0.5 <at> 0.0" 1/2 0)
                ("#e1.0 <at> 0" 1 0) ("#e1.0@-0" 1 0)
                ("#i1 <at> 0" 1.0 0.0) ("#i1@+0" 1.0 0.0) ("#i1@-0" 1.0 -0.0) ("#i1/2 <at> 0" 0.5 0.0)
                ("#i1.0 <at> 0" 1.0 0.0) ("#i1.0@-0" 1.0 -0.0)
                ("1@+0.0" 1.0 0.0) ("1.0@-0.0" 1.0 -0.0)
                ("2+3i" 2.0 3.0) ("4-5i" 4.0 -5.0)
                ("1+i" 1.0 1.0) ("1-i" 1.0 -1.0) ("+1i" 0.0 1.0) ("-1i" 0.0 -1.0)
                ("+i" 0.0 1.0) ("-i" 0.0 -1.0)
		("1.0+.1i" 1.0 0.1) ("1.0-.1i" 1.0 -0.1)
		(".1+.0i" 0.1 0.0) ("1.+.0i" 1.0 0.0) (".1+.1i" 0.1 0.1)
		("1e1+.1i" 10.0 0.1)
                ("0@+nan.0" 0 0) ("0@+inf.0" 0 0) ("0@-inf.0" 0 0)
                ("0.0@+nan.0" 0.0 0.0) ("0.0@+inf.0" 0.0 0.0) ("0.0@-inf.0" 0.0 0.0)
                ("#i0@+nan.0" 0.0 0.0) ("#i0@+inf.0" 0.0 0.0) ("#i0@-inf.0" 0.0 0.0)
                ("0.0 <at> 1" 0.0 0.0) ("0.0 <at> 2" -0.0 0.0) ("0.0 <at> 4" -0.0 -0.0) ("0.0 <at> 5" 0.0 -0.0)
		))

Cheers,

Andy




This bug report was last modified 8 years and 85 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.