Subject: Re: [SWIPL] That must be because of a Standard

From: "Richard A. O'Keefe" <[email-masked]>
Date: Thu, 10 May 2001 09:00:08 +1200 (NZST)

?- assert(my_predicate_with_zero('Yes sure', 0.0)).

	?- my_predicate_with_zero(X,  0).
	
=> no

The reason is simple:  SWI Prolog ***correctly*** regards 0.0 and 0
as different objects.  They do not behave the same, so it would be
very VERY wrong to unify them.  For more information on how numbers
behave, see the IEEE 754 standard, or better the LIA-1 standard.
Amongst other things, -0.0 is not the same object as 0.0,
but -0 IS the same object as 0.