final boolean alive() { RubyThread thread = this.thread; if (thread == null || !thread.isAlive() || data.queue.isShutdown()) { return false; } return true; }
final boolean alive() { RubyThread thread = this.thread; if (thread == null || !thread.isAlive() || data.queue.isShutdown()) { return false; } return true; }
@JRubyMethod(meta = true) public static IRubyObject yield(ThreadContext context, IRubyObject recv, IRubyObject value) { Ruby runtime = context.runtime; FiberData currentFiberData = context.getFiber().data; if (currentFiberData.parent == null) throw runtime.newFiberError("can't yield from root fiber"); if (currentFiberData.prev == null) throw runtime.newFiberError("BUG: yield occurred with null previous fiber. Report this at http://bugs.jruby.org"); if (currentFiberData.queue.isShutdown()) throw runtime.newFiberError("dead fiber yielded"); FiberData prevFiberData = currentFiberData.prev.data; return exchangeWithFiber(context, currentFiberData, prevFiberData, value); }
if (currentFiberData.queue.isShutdown()) { throw re; if (targetFiberData.queue.isShutdown()) { throw re;
@JRubyMethod(meta = true) public static IRubyObject yield(ThreadContext context, IRubyObject recv, IRubyObject value) { Ruby runtime = context.runtime; FiberData currentFiberData = context.getFiber().data; if (currentFiberData.parent == null) throw runtime.newFiberError("can't yield from root fiber"); if (currentFiberData.prev == null) throw runtime.newFiberError("BUG: yield occurred with null previous fiber. Report this at http://bugs.jruby.org"); if (currentFiberData.queue.isShutdown()) throw runtime.newFiberError("dead fiber yielded"); FiberData prevFiberData = currentFiberData.prev.data; return exchangeWithFiber(context, currentFiberData, prevFiberData, value); }
if (currentFiberData.queue.isShutdown()) { throw re; if (targetFiberData.queue.isShutdown()) { throw re;