Commits

Anonymous committed 554b816

Fixed the List monad.

  • Participants
  • Parent commits ab7ef7e

Comments (0)

Files changed (1)

File lib/tweed/monads/list.rb

       end
       
       def +(other)
-        self.to_a == other.to_a
+        self.class.new(self.to_a + other.to_a)
       end
       
       def inspect
       def to_a
         @sequence.to_a
       end
+      
+      def ==(other)
+        self.to_a == other.to_a
+      end
     end # class List
   end # module Monads
 end # module Tweed