From: "Florian Groß" Date: 2006-03-31T23:10:37+09:00 Subject: Re: TrueClass/FalseClass vs. Boolean PrimaryKey wrote: > I am wondering why there are two separate classes (TrueClass and > FalseClass) to deal with boolean types insead of one class (something > like Boolean?). Do you know > why the library designer desided to use this approach? I think it is because true and false don't really have anything in common in Ruby. No way to share code. You can always fix it pretty easily: module Boolean; end [true, false].each do |obj| obj.extend(Boolean) end true.is_a?(Boolean) # => true false.is_a?(Boolean) # => true But note that in Ruby all objects (except false and nil) can be used as true values. And they are used for just that even in the standard library. -- http://flgr.0x42.net/