Sha256: 522e61eb34611aeec91ce2d08805d2ca4efe444dd61a6a72d1163abe495a7570
Contents?: true
Size: 500 Bytes
Versions: 1
Compression:
Stored size: 500 Bytes
Contents
#-- # DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE # Version 2, December 2004 # # DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE # TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION # # 0. You just DO WHAT THE FUCK YOU WANT TO. #++ require 'thread/promise' class Thread::Future < Thread::Promise def initialize (&block) Thread.new { deliver block.call } end end module Kernel def future (&block) Thread::Future.new(&block) end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
thread-0.0.2 | lib/thread/future.rb |