Method: Fr::Reader.unit
- Defined in:
- lib/fr/monad/reader.rb
.unit(value) ⇒ Object
Combinators
22 23 24 25 26 |
# File 'lib/fr/monad/reader.rb', line 22 def unit(value) lambda do |state| Hash[state: state, value: value] end end |
Combinators
22 23 24 25 26 |
# File 'lib/fr/monad/reader.rb', line 22 def unit(value) lambda do |state| Hash[state: state, value: value] end end |