From: Eric Hodel Date: 2002-10-26T03:27:27+09:00 Subject: Re: How come true, false don't support <=> (comparison) operator? --0eh6TmSyL6TZE2Uz Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Rudi Cilibrasi (cilibrar@ugcs.caltech.edu) wrote: > class TrueClass > def to_i() 1 end > def <=3D>(b) > to_i <=3D> b.to_i > end > end > class FalseClass > def to_i() 0 end 0 =3D=3D true in Ruby > def <=3D>(b) > to_i <=3D> b.to_i > end > end --=20 Eric Hodel - drbrain@segment7.net - http://segment7.net All messages signed with fingerprint: FEC2 57F1 D465 EB15 5D6E 7C11 332A 551C 796C 9F04 --0eh6TmSyL6TZE2Uz Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.2.0 (FreeBSD) iD8DBQE9uY0LMypVHHlsnwQRAg1UAKCC2h/2GYD7QZ9mSVyCeAjzRNFflQCgn9pt Mxu1aoh9fYuU2UUJIuSFdgw= =wsYg -----END PGP SIGNATURE----- --0eh6TmSyL6TZE2Uz--