Sha256: b4f832ccb6cd7cc0feb4f6965865612760ad13e3c7434076739e2ee3805677cf
Contents?: true
Size: 799 Bytes
Versions: 3
Compression:
Stored size: 799 Bytes
Contents
require "iolite/adaptor" module Iolite class Lazy < BasicObject # include ::Iolite::Adaptor::All include ::Iolite::Adaptor::Callable include ::Iolite::Adaptor::Bind include ::Iolite::Adaptor::Send include ::Iolite::Adaptor::MethodMissing include ::Iolite::Adaptor::ToProc include ::Iolite::Adaptor::Apply include ::Iolite::Adaptor::Operators include ::Iolite::Adaptor::ToLazy def initialize &block @block = block end def call *args @block.call(*args) end # iolite_define_send_original_methods end def lazy &block Iolite::Lazy.new &block end module_function :lazy # def wrap value # Iolite.lazy { |*args| value } # end # module_function :wrap # # def lazy_func func # Iolite.lazy { |*args| func.call(*args) } # end # module_function :wrap end
Version data entries
3 entries across 3 versions & 1 rubygems
Version | Path |
---|---|
iolite-0.0.3 | lib/iolite/lazy.rb |
iolite-0.0.2 | lib/iolite/lazy.rb |
iolite-0.0.1 | lib/iolite/lazy.rb |