Hi.
Since Vast 6.0.4 the implementation of Integer>>even changed from this:
Integer>>even
"Answer a Boolean, true if the
receiver is an even number;
answer false otherwise. Even means divisible
by 2 with no remainder."
^(self rem: 2 ) = 0
to this:
Integer>>even
"Answer a Boolean true if the receiver is an even number;
answer false otherwise. Even means divisible by 2 with
no remainder."
^(self bitAnd: 1) ~= 0
But not the implementation of Integer>>odd, which is this:
Integer>>odd
"Answer a Boolean indicating true if
the receiver is an odd number; answer
false otherwise. Odd is defined as
divisable by 2 with a non-zero remainder."
^(self rem: 2 ) ~= 0
Is there any reason for it?
Thanks,
JP