Module: TruthyBooleanOperators

Included in:
NullClass
Defined in:
lib/null.rb

Overview

Define boolean operators based on truthiness.

Instance Method Summary collapse

Instance Method Details

#&(obj) ⇒ Object



112
# File 'lib/null.rb', line 112

def &(obj) truthy? & obj end

#^(obj) ⇒ Object



114
# File 'lib/null.rb', line 114

def ^(obj) truthy? ^ obj end

#|(obj) ⇒ Object



113
# File 'lib/null.rb', line 113

def |(obj) truthy? | obj end