(/ -3/8) => 8/-3, (= 8/-3 (/ -3/8)) => #f

Bug #831582 reported by John David Stone on 2011-08-22
14
This bug affects 3 people
Affects Status Importance Assigned to Milestone
Ikarus Scheme
Undecided
Unassigned

Bug Description

I expected to see (/ -3/8) => -8/3, but 8/-3 is OK even though it's not a valid R6RS numeric literal. But then (= 8/-3 (/ -3/8)) should be true. Other weirdness:

(- 8/-3 (/ -3/8)) => 0

(= -8/3 (/ -3/8)) => #f

(- -8/3 (/ -3/8)) => 0

(= -8/3 (/ 1 -3/8)) => #t

(= (/ -3/8) (/ 1 -3/8)) => #f

Göran Weinholt (weinholt) wrote :

This seems a bit related:

(expt 1/2 0) => 1/1

To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers