Class: Mal::AnythingT

Inherits:
Object
  • Object
show all
Defined in:
lib/mal.rb

Instance Method Summary collapse

Instance Method Details

#&(another) ⇒ Object



60
61
62
# File 'lib/mal.rb', line 60

def &(another)
  another # Another is automatically considered more specific, and replaces Anything
end

#===(value) ⇒ Object



49
50
51
# File 'lib/mal.rb', line 49

def ===(value)
  true
end

#inspectObject



52
53
54
# File 'lib/mal.rb', line 52

def inspect
  'Anything()'
end

#|(another) ⇒ Object



56
57
58
# File 'lib/mal.rb', line 56

def |(another)
  self
end