On Fri, Aug 15, 2008 at 1:04 PM, Emmanuel Oga
<oga_emmanuel_oga / yahoo.com.ar> wrote:
>> The trick is that Ruby evaluates all subclasses of NilClass to false.
>
> The problem is that, if I extend NilClass, I wont be able to use new
> anymore
>
> class Test < NilClass; end;
>
> Test.new # NoMethodError: undefined method `new' for Test:Class
>
>
> --
> Posted via http://www.ruby-forum.com/.
>
>


I'm not sure I understand what you're looking for, but this passes your specs.

http://gist.github.com/5619

Actually, I think there was a typo on line 94.

-  @recognizer.mknows?(1).or?(3).or?(5).should be_true
+ @recognizer.mknows?(1).or?(3).or?(6).should be_true

After I fixed that, it passes the specs.