From: Robert Klemme Date: 2003-03-21T23:42:28+09:00 Subject: Re: infinite Time Maybe this approach helps: class TimeInfinity include Comparable def <=>(o) if o.kind_of? Time then 1 elsif o.kind_of? TimeInfinity then 0 else -1 end end def to_s() "Infinity"; end end class Time alias __compare__ <=> def <=>(o) o.kind_of?( TimeInfinity ) ? (0-(o<=>self)) : __compare__(o) end end times=[Time.now, TimeInfinity.new, Time.now] puts times.join ", " puts times.sort.join ", " "Yukihiro Matsumoto" schrieb im Newsbeitrag news:1048255598.253957.30111.nullmailer@picachu.netlab.jp... > Hi, > > In message "infinite Time" > on 03/03/21, ahoward writes: > > |anyone know of a way to get at infinite times (if they exist) as one can for > |Floats? > > Unfortunately, Time is a limited resource. We cannot have times > further than 2038-01-19 on most platforms. > > matz. > >