Class: Left
Instance Method Summary collapse
- #==(other) ⇒ Object
-
#left? ⇒ Boolean
always true.
Methods included from Either
#<=>, #bimap, #each, #flat_map, #get_or_else, #initialize, #left_map, lefts, #map, #or_else, partition, #right?, rights, #to_a, #to_s, #~@
Methods included from UnionType
Methods included from Helper
Methods included from Control::Monad
Methods included from Control::Functor
Instance Method Details
#==(other) ⇒ Object
223 224 225 226 227 228 229 230 |
# File 'lib/data.either.rb', line 223 def == other case other when Left other.left_map { |v| return v == @v } else false end end |
#left? ⇒ Boolean
always true
219 220 221 |
# File 'lib/data.either.rb', line 219 def left? true end |