Examples of newLocalJumpError()


Examples of org.jruby.Ruby.newLocalJumpError()

                return Interpreter.interpretSimpleEval(runtime, file, lineNumber, "(eval)", node, self);
            } else {
                return INTERPRET_EVAL(runtime, context, file, lineNumber, node, "(eval)", self, Block.NULL_BLOCK);
            }
        } catch (JumpException.BreakJump bj) {
            throw runtime.newLocalJumpError(RubyLocalJumpError.Reason.BREAK, (IRubyObject)bj.getValue(), "unexpected break");
        } catch (StackOverflowError soe) {
            throw runtime.newSystemStackError("stack level too deep", soe);
        }
    }
View Full Code Here

Examples of org.jruby.Ruby.newLocalJumpError()

                    result = block.yieldArray(context, result, null, null);
                } catch (JumpException.RetryJump rtry) {
                    // FIXME: technically this should happen before the block is executed
                    parent.raise(new IRubyObject[]{runtime.newSyntaxError("Invalid retry").getException()}, Block.NULL_BLOCK);
                } catch (JumpException.BreakJump brk) {
                    parent.raise(new IRubyObject[]{runtime.newLocalJumpError(Reason.BREAK, runtime.getNil(), "break from proc-closure").getException()}, Block.NULL_BLOCK);
                } catch (JumpException.ReturnJump ret) {
                    parent.raise(new IRubyObject[]{runtime.newLocalJumpError(Reason.RETURN, runtime.getNil(), "unexpected return").getException()}, Block.NULL_BLOCK);
                } catch (RaiseException re) {
                    // re-raise exception in parent thread
                    parent.raise(new IRubyObject[]{re.getException()}, Block.NULL_BLOCK);
View Full Code Here

Examples of org.jruby.Ruby.newLocalJumpError()

                    // FIXME: technically this should happen before the block is executed
                    parent.raise(new IRubyObject[]{runtime.newSyntaxError("Invalid retry").getException()}, Block.NULL_BLOCK);
                } catch (JumpException.BreakJump brk) {
                    parent.raise(new IRubyObject[]{runtime.newLocalJumpError(Reason.BREAK, runtime.getNil(), "break from proc-closure").getException()}, Block.NULL_BLOCK);
                } catch (JumpException.ReturnJump ret) {
                    parent.raise(new IRubyObject[]{runtime.newLocalJumpError(Reason.RETURN, runtime.getNil(), "unexpected return").getException()}, Block.NULL_BLOCK);
                } catch (RaiseException re) {
                    // re-raise exception in parent thread
                    parent.raise(new IRubyObject[]{re.getException()}, Block.NULL_BLOCK);
                } finally {
                    state = ThreadFiberState.FINISHED;
View Full Code Here

Examples of org.jruby.Ruby.newLocalJumpError()

            }
        } catch (JumpException.RetryJump rtry) {
            // FIXME: technically this should happen before the block is executed
            context.getThread().raise(new IRubyObject[]{runtime.newSyntaxError("Invalid retry").getException()}, Block.NULL_BLOCK);
        } catch (JumpException.BreakJump brk) {
            context.getThread().raise(new IRubyObject[]{runtime.newLocalJumpError(Reason.BREAK, runtime.getNil(), "break from proc-closure").getException()}, Block.NULL_BLOCK);
        } catch (JumpException.ReturnJump ret) {
            context.getThread().raise(new IRubyObject[]{runtime.newLocalJumpError(Reason.RETURN, runtime.getNil(), "unexpected return").getException()}, Block.NULL_BLOCK);
        }

        // back from fiber, poll events and proceed out of resume
View Full Code Here

Examples of org.jruby.Ruby.newLocalJumpError()

            // FIXME: technically this should happen before the block is executed
            context.getThread().raise(new IRubyObject[]{runtime.newSyntaxError("Invalid retry").getException()}, Block.NULL_BLOCK);
        } catch (JumpException.BreakJump brk) {
            context.getThread().raise(new IRubyObject[]{runtime.newLocalJumpError(Reason.BREAK, runtime.getNil(), "break from proc-closure").getException()}, Block.NULL_BLOCK);
        } catch (JumpException.ReturnJump ret) {
            context.getThread().raise(new IRubyObject[]{runtime.newLocalJumpError(Reason.RETURN, runtime.getNil(), "unexpected return").getException()}, Block.NULL_BLOCK);
        }

        // back from fiber, poll events and proceed out of resume
        context.pollThreadEvents();
        return slot;
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.