Package org.jruby.compiler

Examples of org.jruby.compiler.NotCompilableException


            }
            buildMultipleAsgnAssignment(childNode, s, null, valuesArg);
            break;
        }
        default:
            throw new NotCompilableException("Can't build assignment node: " + node);
        }
    }
View Full Code Here


                int depth = localVariable.getDepth();
                s.addInstr(new CopyInstr(s.getLocalVariable(localVariable.getName(), depth), rhsVal));
                break;
            }
            case ZEROARGNODE:
                throw new NotCompilableException("Shouldn't get here; zeroarg does not do assignment: " + node);
            default:
                buildVersionSpecificAssignment(node, s, rhsVal);
        }
    }
View Full Code Here

                }
                // Build
                buildMultipleAsgnAssignment(childNode, s, argsArray, null);
                break;
            }
            default: throw new NotCompilableException("Can't build assignment node: " + node);
        }
    }
View Full Code Here

                v = getBlockArgVariable((IRClosure)s, localVariable.getName(), depth);
                receiveBlockArg(s, v, argsArray, argIndex, isClosureArg, isSplat);
                break;
            }
            case ZEROARGNODE:
                throw new NotCompilableException("Shouldn't get here; zeroarg does not do assignment: " + node);
            default:
                buildVersionSpecificBlockArgsAssignment(node, s, argsArray, argIndex, isMasgnRoot, isClosureArg, isSplat);
        }
    }
View Full Code Here

        Operand v2 = build(argsCatNode.getSecondNode(), s);
        return new CompoundArray(v1, v2);
    }

    public Operand buildArgsPush(final ArgsPushNode node, IRScope s) {
        throw new NotCompilableException("ArgsPush should never be encountered bare in 1.8" + node);
    }
View Full Code Here

            Instr         callInstr  = CallInstr.create(callResult, new MethAddr(c2mNode.getName()),
                    null, args.toArray(new Operand[args.size()]), null);
            s.addInstr(callInstr);
            return callResult;
        } else {
            throw new NotCompilableException("Not compilable: " + iVisited);
        }
    }
View Full Code Here

            case ITERNODE:
                return build((IterNode)node, s);
            case BLOCKPASSNODE:
                return build(((BlockPassNode)node).getBodyNode(), s);
            default:
                throw new NotCompilableException("ERROR: Encountered a method with a non-block, non-blockpass iter node at: " + node);
        }
    }
View Full Code Here

        // First, build an assignment for a splat, if any, with the rest of the args!
        Node argsNode = multipleAsgnNode.getArgsNode();
        if (argsNode == null) {
            if (sourceArray == null)
                throw new NotCompilableException("Something's wrong, multiple assignment with no head or args at: " + multipleAsgnNode.getPosition());
        } else if (argsNode instanceof StarNode) {
            // do nothing
        } else if (values != null) {
            Variable rhsVal = s.getNewTemporaryVariable();
            s.addInstr(new RestArgMultipleAsgnInstr(rhsVal, values, i));
View Full Code Here

    protected Operand buildVersionSpecificNodes(Node node, IRScope s) {
        switch (node.getNodeType()) {
            case ENCODINGNODE: return buildEncoding((EncodingNode)node, s);
            case MULTIPLEASGN19NODE: return buildMultipleAsgn19((MultipleAsgn19Node) node, s);
            case LAMBDANODE: return buildLambda((LambdaNode)node, s);
            default: throw new NotCompilableException("Unknown node encountered in builder: " + node.getClass());
        }
    }
View Full Code Here

    protected LocalVariable getBlockArgVariable(IRScope s, String name, int depth) {
        IRClosure cl = (IRClosure)s;
        if (cl.isForLoopBody()) {
            return cl.getLocalVariable(name, depth);
        } else {
            throw new NotCompilableException("Cannot ask for block-arg variable in 1.9 mode");
        }
    }
View Full Code Here

TOP

Related Classes of org.jruby.compiler.NotCompilableException

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.