Sha256: 713f44a3a748632878e250f82aa53432163b5bff4dd7bc623c7a284f28522fe3
Contents?: true
Size: 424 Bytes
Versions: 7
Compression:
Stored size: 424 Bytes
Contents
# frozen_string_literal: true class Ultravisor::Child::CallReceiver < BasicObject def initialize(&blk) @blk = blk end def method_missing(name, *args, &blk) rv_q = ::Queue.new rv_fail = ::Object.new callback = ::Ultravisor::Child::Call.new(name, args, blk, rv_q, rv_fail) @blk.call(callback) rv_q.pop.tap { |rv| ::Kernel.raise ::Ultravisor::ChildRestartedError.new if rv == rv_fail } end end
Version data entries
7 entries across 7 versions & 1 rubygems