module MonadIntegration
	class Maybe
		def self.something value
			Something.new value
		end

		def self.nothing
			Nothing.new
		end

		def initialize context
			@context = context
		end

		class Something
			def initialize value
				@value = value
			end
		end

		class Nothing
		end
	end

	def self.maybe &block
		lambda { block.call Maybe.new(binding) }
	end
end