Package org.jruby.ir.instructions

Examples of org.jruby.ir.instructions.ThrowExceptionInstr


                // Allocate GEB if necessary for popping binding
                if (geb == null && (scopeHasLocalVarStores || scopeHasUnrescuedExceptions)) {
                    Variable exc = scope.getNewTemporaryVariable();
                    geb = new BasicBlock(cfg, new Label("_GLOBAL_ENSURE_BLOCK"));
                    geb.addInstr(new ReceiveExceptionInstr(exc, false)); // No need to check type since it is not used before rethrowing
                    geb.addInstr(new ThrowExceptionInstr(exc));
                    cfg.addGlobalEnsureBB(geb);
                }

                // Pop on all scope-exit paths
                BasicBlock exitBB = cfg.getExitBB();
View Full Code Here


                    value = cfgScope.getNewTemporaryVariable("%t_" + v.getName());
                    varRenameMap.put(v, value);
                }
                geb.addInstr(new StoreLocalVarInstr(value, (IRClosure) cfgScope, v));
            }
            geb.addInstr(new ThrowExceptionInstr(exc));
            cfg.addGlobalEnsureBB(geb);
        }
    }
View Full Code Here

            BasicBlock geb = cfg.getGlobalEnsureBB();
            if (geb == null) {
                Variable exc = cfgScope.createTemporaryVariable();
                geb = new BasicBlock(cfg, Label.getGlobalEnsureBlockLabel());
                geb.addInstr(new ReceiveJRubyExceptionInstr(exc)); // JRuby implementation exception handling
                geb.addInstr(new ThrowExceptionInstr(exc));
                cfg.addGlobalEnsureBB(geb);
            }

            instrs = geb.getInstrs().listIterator(geb.getInstrs().size());
            Instr i = instrs.previous();
View Full Code Here

TOP

Related Classes of org.jruby.ir.instructions.ThrowExceptionInstr

Copyright © 2018 www.massapicom. 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.