Exception Fact Sheet for "jython"

The goal of an Exception Fact Sheet is to reveal the design of exception handling in an application.

--Maxence, Martin

For feedback, please contact Martin

Table of contents

Basic Statistics

Number of Classes 961
Number of Domain Exception Types (Thrown or Caught) 10
Number of Domain Checked Exception Types 1
Number of Domain Runtime Exception Types 9
Number of Domain Unknown Exception Types 0
nTh = Number of Throw 4163
nTh = Number of Throw in Catch 713
Number of Catch-Rethrow (may not be correct) 436
nC = Number of Catch 874
nCTh = Number of Catch with Throw 685
Number of Empty Catch (really Empty) 20
Number of Empty Catch (with comments) 38
Number of Empty Catch 58
nM = Number of Methods 19495
nbFunctionWithCatch = Number of Methods with Catch 739 / 19495
nbFunctionWithThrow = Number of Methods with Throw 3413 / 19495
nbFunctionWithThrowS = Number of Methods with ThrowS 715 / 19495
nbFunctionTransmitting = Number of Methods with "Throws" but NO catch, NO throw (only transmitting) 622 / 19495
P1 = nCTh / nC 78.4% (0.784)
P2 = nMC / nM 3.8% (0.038)
P3 = nbFunctionWithThrow / nbFunction 17.5% (0.175)
P4 = nbFunctionTransmitting / nbFunction 3.2% (0.032)
P5 = nbThrowInCatch / nbThrow 17.1% (0.171)
R2 = nCatch / nThrow 0.21
A1 = Number of Caught Exception Types From External Libraries 45
A2 = Number of Reused Exception Types From External Libraries (thrown from application code) 22

W1 is a rough estimation of the richness of the exception model. It does not take into account the inheritance relationships between domain exceptions.

Proportion P1 measures the overall exception flow. According to our experience, it varies from 5% to 70%. Early-catch design generally yields a low P1, libraries that must warn clients about errors (e.g. databases) generally have a high P1.

Proportion P2 measures the dispersion of catch blocks in the application. According to our experience, it varies from 2% to 15%. A small P2 indicates a rather centralized management of errors.

R1 shows how many exceptions types from libraries (incl. JDK) are thrown from application code. For instance, IllegalArgumentException comes from the JDK but is used in many applications.

A1 measures the awareness of the application to library exceptions. A high value of A1 means either that the application is polluted with checked exceptions or that it is able to apply specific recovery depending on the library exception.

Exception Hierachy

Exception Map

Each exception that is used at least once in the project is a dot. A orange dot represents a domain exception that is defined in the application. A blue dot exception is defined in the JDK or in a library. The x-axis represents the number of times an exception is caught, the y-axis the number of times an exception is thrown.

Exceptions With State

State means fields. Number of exceptions with state: 5
PyException
              package org.python.core;public class PyException extends RuntimeException
{

    /**
     * The python exception class (for class exception) or identifier (for string exception).
     */
    public PyObject type;

    /**
     * The exception instance (for class exception) or exception value (for string exception).
     */
    public PyObject value = Py.None;

    /** The exception traceback object. */
    public PyTraceback traceback;

    /**
     * Whether the exception was re-raised, such as when a traceback is specified to
     * 'raise', or via a 'finally' block.
     */
    private boolean isReRaise = false;

    private boolean normalized = false;

    public PyException() {
        this(Py.None, Py.None);
    }

    public PyException(PyObject type) {
        this(type, Py.None);
    }

    public PyException(PyObject type, PyObject value) {
        this(type, value, null);
    }

    public PyException(PyObject type, PyObject value, PyTraceback traceback) {
        this.type = type;
        this.value = value;
        if (traceback != null) {
            this.traceback = traceback;
            isReRaise = true;
        } else {
            PyFrame frame = Py.getFrame();
            if (frame != null && frame.tracefunc != null) {
                frame.tracefunc = frame.tracefunc.traceException(frame, this);
            }
        }
    }

    public PyException(PyObject type, String value) {
        this(type, new PyString(value));
    }

    private boolean printingStackTrace = false;
    public void printStackTrace() {
        Py.printException(this);
    }

    public Throwable fillInStackTrace() {
        return Options.includeJavaStackInExceptions ? super.fillInStackTrace() : this;
    }

    public synchronized void printStackTrace(PrintStream s) {
        if (printingStackTrace) {
            super.printStackTrace(s);
        } else {
            try {
                printingStackTrace = true;
                Py.displayException(type, value, traceback, new PyFile(s));
            } finally {
                printingStackTrace = false;
            }
        }
    }

    public synchronized void super__printStackTrace(PrintWriter w) {
        try {
            printingStackTrace = true;
            super.printStackTrace(w);
        } finally {
            printingStackTrace = false;
        }
    }

    public synchronized String toString() {
        ByteArrayOutputStream buf = new ByteArrayOutputStream();
        if (!printingStackTrace) {
            printStackTrace(new PrintStream(buf));
        }
        return buf.toString();
    }

    /**
     * Instantiates the exception value if it is not already an
     * instance.
     *
     */
    public void normalize() {
        if (normalized) {
            return;
        }
        PyObject inClass = null;
        if (isExceptionInstance(value)) {
            inClass = value.fastGetClass();
        }

        if (isExceptionClass(type)) {
            if (inClass == null || !Py.isSubClass(inClass, type)) {
                PyObject[] args;

                // Don't decouple a tuple into args when it's a
                // KeyError, pass it on through below
                if (value == Py.None) {
                    args = Py.EmptyObjects;
                } else if (value instanceof PyTuple && type != Py.KeyError) {
                    args = ((PyTuple)value).getArray();
                } else {
                    args = new PyObject[] {value};
                }

                value = type.__call__(args);
            } else if (inClass != type) {
                type = inClass;
            }
        }
        normalized = true;
    }

    /**
     * Register frame as having been visited in the traceback.
     *
     * @param here the current PyFrame
     */
    public void tracebackHere(PyFrame here) {
        tracebackHere(here, false);
    }

    /**
     * Register frame as having been visited in the traceback.
     *
     * @param here the current PyFrame
     * @param isFinally whether caller is a Python finally block
     */
    public void tracebackHere(PyFrame here, boolean isFinally) {
        if (!isReRaise && here != null) {
            // the frame is either inapplicable or already registered (from a finally)
            // during a re-raise
            traceback = new PyTraceback(traceback, here);
        }
        // finally blocks immediately tracebackHere: so they toggle isReRaise to skip the
        // next tracebackHere hook
        isReRaise = isFinally;
    }

    /**
     * Logic for the raise statement
     *
     * @param type the first arg to raise, a type or an instance
     * @param value the second arg, the instance of the class or arguments to its
     * constructor
     * @param traceback a traceback object
     * @return a PyException wrapper
     */
    public static PyException doRaise(PyObject type, PyObject value, PyObject traceback) {
        if (type == null) {
            ThreadState state = Py.getThreadState();
            type = state.exception.type;
            value = state.exception.value;
            traceback = state.exception.traceback;
        }

        if (traceback == Py.None) {
            traceback = null;
        } else if (traceback != null && !(traceback instanceof PyTraceback)) {
            throw Py.TypeError("raise: arg 3 must be a traceback or None");
        }

        if (value == null) {
            value = Py.None;
        }

        // Repeatedly, replace a tuple exception with its first item
        while (type instanceof PyTuple && ((PyTuple)type).size() > 0) {
            type = type.__getitem__(0);
        }

        if (isExceptionClass(type)) {
            PyException pye = new PyException(type, value, (PyTraceback)traceback);
            pye.normalize();
            return pye;
        } else if (isExceptionInstance(type)) {
            // Raising an instance.  The value should be a dummy.
            if (value != Py.None) {
                throw Py.TypeError("instance exception may not have a separate value");
            } else {
                // Normalize to raise <class>, <instance>
                value = type;
                type = type.fastGetClass();
            }
        } else {
            // Not something you can raise.  You get an exception
            // anyway, just not what you specified :-)
            throw Py.TypeError("exceptions must be old-style classes or derived from "
                               + "BaseException, not " + type.getType().fastGetName());
        }

        if (Options.py3kwarning && type instanceof PyClass) {
            Py.DeprecationWarning("exceptions must derive from BaseException in 3.x");
        }

        return new PyException(type, value, (PyTraceback)traceback);
    }

    /**
     * Determine if this PyException is a match for exc.
     *
     * @param exc a PyObject exception type
     * @return true if a match
     */
    public boolean match(PyObject exc) {
        if (exc instanceof PyTuple) {
            for (PyObject item : ((PyTuple)exc).getArray()) {
                if (match(item)) {
                    return true;
                }
            }
            return false;
        }

        if (exc instanceof PyString) {
            Py.DeprecationWarning("catching of string exceptions is deprecated");
        } else if (Options.py3kwarning && !isPy3kExceptionClass(exc)) {
            Py.DeprecationWarning("catching classes that don't inherit from BaseException is not "
                                  + "allowed in 3.x");
        }

        normalize();
        // FIXME, see bug 737978
        //
        // A special case for IOError's to allow them to also match
        // java.io.IOExceptions.  This is a hack for 1.0.x until I can do
        // it right in 1.1
        if (exc == Py.IOError) {
            if (__builtin__.isinstance(value, PyType.fromClass(IOException.class))) {
                return true;
            }
        }
        // FIXME too, same approach for OutOfMemoryError
        if (exc == Py.MemoryError) {
            if (__builtin__.isinstance(value,
                                       PyType.fromClass(OutOfMemoryError.class))) {
                return true;
            }
        }

        if (isExceptionClass(type) && isExceptionClass(exc)) {
            try {
                return Py.isSubClass(type, exc);
            } catch (PyException pye) {
                // This function must not fail, so print the error here
                Py.writeUnraisable(pye, type);
                return false;
            }
        }

        return type == exc;
    }

    /**
     * Determine whether obj is a Python exception class
     *
     * @param obj a PyObject
     * @return true if an exception
     */
    public static boolean isExceptionClass(PyObject obj) {
        if (obj instanceof PyClass) {
            return true;
        }
        return isPy3kExceptionClass(obj);
    }

    /**
     * Determine whether obj is a Python 3 exception class
     *
     * @param obj a PyObject
     * @return true if an exception
     */
    private static boolean isPy3kExceptionClass(PyObject obj) {
        if (!(obj instanceof PyType)) {
            return false;
        }
        PyType type = ((PyType)obj);
        if (type.isSubType(PyBaseException.TYPE)) {
            return true;
        }
        return type.getProxyType() != null
                && Throwable.class.isAssignableFrom(type.getProxyType());
    }

    /**
     * Determine whether obj is an Python exception instance
     *
     * @param obj a PyObject
     * @return true if an exception instance
     */
    public static boolean isExceptionInstance(PyObject obj) {
        return obj instanceof PyInstance || obj instanceof PyBaseException
           || obj.getJavaProxy() instanceof Throwable;
    }

    /**
     * Get the name of the exception's class
     *
     * @param obj a PyObject exception
     * @return String exception name
     */
    public static String exceptionClassName(PyObject obj) {
        return obj instanceof PyClass ? ((PyClass)obj).__name__ : ((PyType)obj).fastGetName();
    }
}
            
PySyntaxError
              package org.python.core;public class PySyntaxError extends PyException {
    int lineno;
    int column;
    String text;
    String filename;


    public PySyntaxError(String s, int line, int column, String text,
                         String filename)
    {
        super(Py.SyntaxError);
        //XXX: null text causes Java error, though I bet I'm not supposed to
        //     get null text.
        if (text == null) {
            text = "";
        }
        PyObject[] tmp = new PyObject[] {
            new PyString(filename), new PyInteger(line),
            new PyInteger(column), new PyString(text)
        };

        this.value = new PyTuple(new PyString(s), new PyTuple(tmp));

        this.lineno = line;
        this.column = column;
        this.text = text;
        this.filename = filename;
    }
}
            
PyIndentationError
              package org.python.core;public class PyIndentationError extends PyException {
    int lineno, column;
    String text;
    String filename;

    public PyIndentationError(String s, int line, int column, String text,
                         String filename)
    {
        super(Py.IndentationError);
        PyObject[] tmp = new PyObject[] {
            new PyString(filename), new PyInteger(line),
            new PyInteger(column), new PyString(text)
        };

        this.value = new PyTuple(new PyString(s), new PyTuple(tmp));

        this.lineno = line;
        this.column = column;
        this.text = text;
        this.filename = filename;
    }
}
            
ParseException
              package org.python.antlr;public class ParseException extends RuntimeException {
	public transient IntStream input;
	public int index;
	public Token token;
	public Object node;
	public int c;
	public int line;
	public int charPositionInLine;
	public boolean approximateLineInfo;

    private PyObject type = Py.SyntaxError;

    public ParseException() {
        super();
    }

    public ParseException(String message, int lin, int charPos) {
        super(message);
        this.line = lin;
        this.charPositionInLine = charPos;
    }

    public ParseException(String message) {
        this(message, 0, 0);
    }

    /**
     * n must not be null to use this constructor
     */
    public ParseException(String message, PythonTree n) {
        this(message, n.getLine(), n.getCharPositionInLine());
        this.node = n;
        this.token = n.getToken();
    }

    public ParseException(String message, RecognitionException r) {
        super(message);
        this.input = r.input;
        this.index = r.index;
        this.token = r.token;
        this.node = r.node;
        this.c = r.c;
        this.line = r.line;
        this.charPositionInLine = r.charPositionInLine;
        this.approximateLineInfo = r.approximateLineInfo;
    }

    public void setType(PyObject t) {
        this.type = t;
    }

    public PyObject getType() {
        return this.type;
    }

}
            
ConversionException
              package org.python.core;public static class ConversionException extends Exception {

        public int index;

        public ConversionException(int index) {
            this.index = index;
        }

    }
            

Thrown Exceptions Summary

A (Domain) exception is defined in the application. A (Lib) exception is defined in the JDK or in a library. An exception can be thrown, thrown from within a catch, or declared in the signature of a method (usually for checked exceptions). Hovering over a number triggers showing code snippets from the application code.

Type Exception Thrown Thrown
from Catch
Declared
- Unknown 3857
              
//in src/com/ziclix/python/sql/Fetch.java
throw e;

              
//in src/com/ziclix/python/sql/Fetch.java
throw zxJDBC.makeException(e);

              
//in src/com/ziclix/python/sql/Fetch.java
throw e;

              
//in src/com/ziclix/python/sql/Fetch.java
throw zxJDBC.makeException(e);

              
//in src/com/ziclix/python/sql/Fetch.java
throw zxJDBC.makeException(zxJDBC.DatabaseError, "no results");

              
//in src/com/ziclix/python/sql/Fetch.java
throw zxJDBC.makeException(zxJDBC.ProgrammingError, "invalid cursor scroll mode ["
                                       + mode + "]");

              
//in src/com/ziclix/python/sql/Fetch.java
throw zxJDBC.makeException(Py.IndexError, "cursor index [" + pos + "] out of range");

              
//in src/com/ziclix/python/sql/Fetch.java
throw zxJDBC.makeException(zxJDBC.getString("onlyOneResultSet"));

              
//in src/com/ziclix/python/sql/Fetch.java
throw e;

              
//in src/com/ziclix/python/sql/Fetch.java
throw zxJDBC.makeException(e);

              
//in src/com/ziclix/python/sql/Fetch.java
throw zxJDBC.makeException(zxJDBC.NotSupportedError,
                                   zxJDBC.getString("nocallprocsupport"));

              
//in src/com/ziclix/python/sql/Fetch.java
throw zxJDBC.makeException(zxJDBC.DatabaseError, "no results");

              
//in src/com/ziclix/python/sql/Fetch.java
throw zxJDBC.makeException(zxJDBC.NotSupportedError,
                                       zxJDBC.getString("nodynamiccursors"));

              
//in src/com/ziclix/python/sql/Fetch.java
throw e;

              
//in src/com/ziclix/python/sql/Fetch.java
throw zxJDBC.makeException(e);

              
//in src/com/ziclix/python/sql/Fetch.java
throw zxJDBC.makeException(Py.IndexError, "cursor index [" + value
                                                   + "] out of range");

              
//in src/com/ziclix/python/sql/Fetch.java
throw zxJDBC.makeException(zxJDBC.ProgrammingError,
                                               "invalid cursor scroll mode [" + mode + "]");

              
//in src/com/ziclix/python/sql/Fetch.java
throw zxJDBC.makeException(Py.IndexError, "cursor index [" + value
                                                   + "] out of range");

              
//in src/com/ziclix/python/sql/Fetch.java
throw zxJDBC.makeException(zxJDBC.NotSupportedError, msg);

              
//in src/com/ziclix/python/sql/Fetch.java
throw zxJDBC.makeException(zxJDBC.NotSupportedError,
                                       zxJDBC.getString("nodynamiccursors"));

              
//in src/com/ziclix/python/sql/Fetch.java
throw zxJDBC.makeException(e);

              
//in src/com/ziclix/python/sql/Fetch.java
throw zxJDBC.makeException(t);

              
//in src/com/ziclix/python/sql/zxJDBC.java
throw makeException(t);

              
//in src/com/ziclix/python/sql/zxJDBC.java
throw info.unexpectedCall(1, false);

              
//in src/com/ziclix/python/sql/zxJDBC.java
throw info.unexpectedCall(3, false);

              
//in src/com/ziclix/python/sql/zxJDBC.java
throw info.unexpectedCall(args.length, false);

              
//in src/com/ziclix/python/sql/PyConnection.java
throw zxJDBC.makeException(zxJDBC.DatabaseError, e);

              
//in src/com/ziclix/python/sql/PyConnection.java
throw zxJDBC.makeException(zxJDBC.DatabaseError, e);

              
//in src/com/ziclix/python/sql/PyConnection.java
throw zxJDBC.makeException(zxJDBC.DatabaseError, e);

              
//in src/com/ziclix/python/sql/PyConnection.java
throw zxJDBC.makeException(zxJDBC.DatabaseError, e);

              
//in src/com/ziclix/python/sql/PyConnection.java
throw zxJDBC.makeException(zxJDBC.DatabaseError, e);

              
//in src/com/ziclix/python/sql/PyConnection.java
throw zxJDBC.makeException(zxJDBC.DatabaseError, e);

              
//in src/com/ziclix/python/sql/PyConnection.java
throw zxJDBC.makeException(zxJDBC.DatabaseError, e);

              
//in src/com/ziclix/python/sql/PyConnection.java
throw zxJDBC.makeException(zxJDBC.ProgrammingError, "connection is closed");

              
//in src/com/ziclix/python/sql/PyConnection.java
throw zxJDBC.makeException(e);

              
//in src/com/ziclix/python/sql/PyConnection.java
throw zxJDBC.makeException(zxJDBC.ProgrammingError, "connection is closed");

              
//in src/com/ziclix/python/sql/PyConnection.java
throw zxJDBC.makeException(e);

              
//in src/com/ziclix/python/sql/PyConnection.java
throw zxJDBC.makeException(zxJDBC.ProgrammingError, "connection is closed");

              
//in src/com/ziclix/python/sql/PyConnection.java
throw zxJDBC.makeException(e);

              
//in src/com/ziclix/python/sql/PyConnection.java
throw zxJDBC.makeException(zxJDBC.ProgrammingError, "connection is closed");

              
//in src/com/ziclix/python/sql/PyConnection.java
throw zxJDBC.makeException(e);

              
//in src/com/ziclix/python/sql/PyConnection.java
throw zxJDBC.makeException(zxJDBC.ProgrammingError, "connection is closed");

              
//in src/com/ziclix/python/sql/PyConnection.java
throw info.unexpectedCall(0, false);

              
//in src/com/ziclix/python/sql/PyConnection.java
throw info.unexpectedCall(1, false);

              
//in src/com/ziclix/python/sql/PyConnection.java
throw info.unexpectedCall(3, false);

              
//in src/com/ziclix/python/sql/PyConnection.java
throw info.unexpectedCall(args.length, true);

              
//in src/com/ziclix/python/sql/DataHandler.java
throw ex;

              
//in src/com/ziclix/python/sql/DataHandler.java
throw ex;

              
//in src/com/ziclix/python/sql/DataHandler.java
throw createUnsupportedTypeSQLException("ARRAY", col);

              
//in src/com/ziclix/python/sql/DataHandler.java
throw createUnsupportedTypeSQLException("DATALINK", col);

              
//in src/com/ziclix/python/sql/DataHandler.java
throw createUnsupportedTypeSQLException("DISTINCT", col);

              
//in src/com/ziclix/python/sql/DataHandler.java
throw createUnsupportedTypeSQLException("REF", col);

              
//in src/com/ziclix/python/sql/DataHandler.java
throw createUnsupportedTypeSQLException("STRUCT", col);

              
//in src/com/ziclix/python/sql/DataHandler.java
throw createUnsupportedTypeSQLException("STRUCT", col);

              
//in src/com/ziclix/python/sql/DataHandler.java
throw createUnsupportedTypeSQLException(new Integer(type), col);

              
//in src/com/ziclix/python/sql/DataHandler.java
throw ex;

              
//in src/com/ziclix/python/sql/DataHandler.java
throw zxJDBC.makeException(ioe);

              
//in src/com/ziclix/python/sql/DataHandler.java
throw zxJDBC.makeException(ioe);

              
//in src/com/ziclix/python/sql/DataHandler.java
throw zxJDBC.makeException(ioe);

              
//in src/com/ziclix/python/sql/DataHandler.java
throw zxJDBC.makeException(ioe);

              
//in src/com/ziclix/python/sql/PyExtendedCursor.java
throw zxJDBC.makeException(e);

              
//in src/com/ziclix/python/sql/PyExtendedCursor.java
throw zxJDBC.makeException(e);

              
//in src/com/ziclix/python/sql/PyExtendedCursor.java
throw zxJDBC.makeException(e);

              
//in src/com/ziclix/python/sql/PyExtendedCursor.java
throw zxJDBC.makeException(e);

              
//in src/com/ziclix/python/sql/PyExtendedCursor.java
throw zxJDBC.makeException(e);

              
//in src/com/ziclix/python/sql/PyExtendedCursor.java
throw zxJDBC.makeException(e);

              
//in src/com/ziclix/python/sql/PyExtendedCursor.java
throw zxJDBC.makeException(e);

              
//in src/com/ziclix/python/sql/PyExtendedCursor.java
throw zxJDBC.makeException(e);

              
//in src/com/ziclix/python/sql/PyExtendedCursor.java
throw zxJDBC.makeException(e);

              
//in src/com/ziclix/python/sql/PyExtendedCursor.java
throw zxJDBC.makeException(e);

              
//in src/com/ziclix/python/sql/PyExtendedCursor.java
throw zxJDBC.makeException(e);

              
//in src/com/ziclix/python/sql/PyExtendedCursor.java
throw info.unexpectedCall(0, false);

              
//in src/com/ziclix/python/sql/PyExtendedCursor.java
throw info.unexpectedCall(1, false);

              
//in src/com/ziclix/python/sql/PyExtendedCursor.java
throw info.unexpectedCall(3, false);

              
//in src/com/ziclix/python/sql/PyExtendedCursor.java
throw info.unexpectedCall(args.length, true);

              
//in src/com/ziclix/python/sql/PyExtendedCursor.java
throw info.unexpectedCall(4, false);

              
//in src/com/ziclix/python/sql/Jython22DataHandler.java
throw ex;

              
//in src/com/ziclix/python/sql/Jython22DataHandler.java
throw ex;

              
//in src/com/ziclix/python/sql/Jython22DataHandler.java
throw createUnsupportedTypeSQLException(new Integer(type), col);

              
//in src/com/ziclix/python/sql/Jython22DataHandler.java
throw createUnsupportedTypeSQLException(new Integer(type), col);

              
//in src/com/ziclix/python/sql/Jython22DataHandler.java
throw ex;

              
//in src/com/ziclix/python/sql/connect/Connectx.java
throw zxJDBC.makeException(zxJDBC.DatabaseError, "unable to instantiate datasource");

              
//in src/com/ziclix/python/sql/connect/Connectx.java
throw zxJDBC.makeException(zxJDBC.DatabaseError, e);

              
//in src/com/ziclix/python/sql/connect/Connectx.java
throw zxJDBC.makeException(zxJDBC.DatabaseError, "unable to establish connection");

              
//in src/com/ziclix/python/sql/connect/Connectx.java
throw zxJDBC.makeException(zxJDBC.DatabaseError, e);

              
//in src/com/ziclix/python/sql/connect/Connectx.java
throw zxJDBC.makeException("no such " + exceptionMsg);

              
//in src/com/ziclix/python/sql/connect/Connectx.java
throw zxJDBC.makeException("illegal access for " + exceptionMsg);

              
//in src/com/ziclix/python/sql/connect/Connectx.java
throw zxJDBC.makeException("invocation target exception for " + exceptionMsg);

              
//in src/com/ziclix/python/sql/connect/Connect.java
throw zxJDBC.makeException(zxJDBC.DatabaseError, "no url specified");

              
//in src/com/ziclix/python/sql/connect/Connect.java
throw zxJDBC.makeException(zxJDBC.DatabaseError, "no driver specified");

              
//in src/com/ziclix/python/sql/connect/Connect.java
throw zxJDBC.makeException(zxJDBC.DatabaseError, "driver [" + driver + "] not found");

              
//in src/com/ziclix/python/sql/connect/Connect.java
throw zxJDBC.makeException(zxJDBC.DatabaseError, e);

              
//in src/com/ziclix/python/sql/connect/Connect.java
throw zxJDBC.makeException(zxJDBC.DatabaseError, "unable to establish connection");

              
//in src/com/ziclix/python/sql/connect/Connect.java
throw zxJDBC.makeException(zxJDBC.DatabaseError, e);

              
//in src/com/ziclix/python/sql/connect/Lookup.java
throw zxJDBC.makeException(zxJDBC.DatabaseError, "lookup name is null");

              
//in src/com/ziclix/python/sql/connect/Lookup.java
throw zxJDBC.makeException(zxJDBC.ProgrammingError, e);

              
//in src/com/ziclix/python/sql/connect/Lookup.java
throw zxJDBC.makeException(zxJDBC.DatabaseError, e);

              
//in src/com/ziclix/python/sql/connect/Lookup.java
throw zxJDBC.makeException(zxJDBC.ProgrammingError,
                                       "object [" + jndiName + "] not found in JNDI");

              
//in src/com/ziclix/python/sql/connect/Lookup.java
throw zxJDBC.makeException(zxJDBC.DatabaseError, e);

              
//in src/com/ziclix/python/sql/connect/Lookup.java
throw zxJDBC.makeException(zxJDBC.DatabaseError, "unable to establish connection");

              
//in src/com/ziclix/python/sql/connect/Lookup.java
throw zxJDBC.makeException(zxJDBC.DatabaseError, e);

              
//in src/com/ziclix/python/sql/PyStatement.java
throw zxJDBC.makeException(e);

              
//in src/com/ziclix/python/sql/PyStatement.java
throw zxJDBC.makeException(zxJDBC.ProgrammingError, "statement is closed");

              
//in src/com/ziclix/python/sql/PyStatement.java
throw zxJDBC.makeException(zxJDBC.ProgrammingError,
                                           zxJDBC.getString("invalidStyle"));

              
//in src/com/ziclix/python/sql/PyStatement.java
throw zxJDBC.makeException(zxJDBC.ProgrammingError,
                                                   zxJDBC.getString("bindingValue"));

              
//in src/com/ziclix/python/sql/PyStatement.java
throw zxJDBC.makeException(e);

              
//in src/com/ziclix/python/sql/pipe/Pipe.java
throw zxJDBC.makeException(e);

              
//in src/com/ziclix/python/sql/pipe/Pipe.java
throw zxJDBC.makeException(e);

              
//in src/com/ziclix/python/sql/pipe/Pipe.java
throw zxJDBC.makeException(sourceRunner.getException().toString());

              
//in src/com/ziclix/python/sql/pipe/Pipe.java
throw zxJDBC.makeException(sinkRunner.getException().toString());

              
//in src/com/ziclix/python/sql/pipe/db/DBSink.java
throw zxJDBC.makeException(zxJDBC.getString("noColInfo"));

              
//in src/com/ziclix/python/sql/pipe/db/DBSink.java
throw zxJDBC.makeException(zxJDBC.ProgrammingError, zxJDBC.getString("excludedAllCols"));

              
//in src/com/ziclix/python/sql/pipe/db/BaseDB.java
throw zxJDBC.makeException(msg);

              
//in src/com/ziclix/python/sql/util/PyArgParser.java
throw Py.KeyError(kw);

              
//in src/com/ziclix/python/sql/util/PyArgParser.java
throw Py.IndexError("index out of range");

              
//in src/com/ziclix/python/sql/util/BCP.java
throw Py.ValueError(zxJDBC.getString("invalidTableName"));

              
//in src/com/ziclix/python/sql/util/BCP.java
throw info.unexpectedCall(1, false);

              
//in src/com/ziclix/python/sql/util/BCP.java
throw Py.ValueError(zxJDBC.getString("invalidTableName"));

              
//in src/com/ziclix/python/sql/util/BCP.java
throw info.unexpectedCall(2, false);

              
//in src/com/ziclix/python/sql/util/BCP.java
throw Py.ValueError(zxJDBC.getString("invalidTableName"));

              
//in src/com/ziclix/python/sql/util/BCP.java
throw info.unexpectedCall(3, false);

              
//in src/com/ziclix/python/sql/util/BCP.java
throw Py.ValueError(zxJDBC.getString("invalidTableName"));

              
//in src/com/ziclix/python/sql/util/BCP.java
throw info.unexpectedCall(3, false);

              
//in src/com/ziclix/python/sql/Procedure.java
throw e;

              
//in src/com/ziclix/python/sql/Procedure.java
throw zxJDBC.makeException(zxJDBC.NotSupportedError, "procedureColumnUnknown");

              
//in src/com/ziclix/python/sql/Procedure.java
throw zxJDBC.makeException(zxJDBC.NotSupportedError, "procedureColumnResult");

              
//in src/com/ziclix/python/sql/Procedure.java
throw zxJDBC.makeException(zxJDBC.DataError, "unknown column type [" + colType + "]");

              
//in src/com/ziclix/python/sql/PyCursor.java
throw Py.StopIteration("");

              
//in src/com/ziclix/python/sql/PyCursor.java
throw zxJDBC.makeException(zxJDBC.NotSupportedError,
                                       zxJDBC.getString("nodynamiccursors"));

              
//in src/com/ziclix/python/sql/PyCursor.java
throw e;

              
//in src/com/ziclix/python/sql/PyCursor.java
throw zxJDBC.makeException(e);

              
//in src/com/ziclix/python/sql/PyCursor.java
throw zxJDBC.makeException(zxJDBC.NotSupportedError,
                                               "sequence of sequences is not supported");

              
//in src/com/ziclix/python/sql/PyCursor.java
throw zxJDBC.makeException(zxJDBC.NotSupportedError,
                                           zxJDBC.getString("noStoredProc"));

              
//in src/com/ziclix/python/sql/PyCursor.java
throw zxJDBC.makeException(t);

              
//in src/com/ziclix/python/sql/PyCursor.java
throw zxJDBC.makeException(zxJDBC.Error, t, rowIndex);

              
//in src/com/ziclix/python/sql/PyCursor.java
throw e;

              
//in src/com/ziclix/python/sql/PyCursor.java
throw zxJDBC.makeException(e);

              
//in src/com/ziclix/python/sql/PyCursor.java
throw zxJDBC.makeException(sqle);

              
//in src/com/ziclix/python/sql/PyCursor.java
throw zxJDBC.makeException(zxJDBC.ProgrammingError,
                                       zxJDBC.getString("optionalSecond"));

              
//in src/com/ziclix/python/sql/PyCursor.java
throw zxJDBC.makeException(zxJDBC.ProgrammingError, "cursor is closed");

              
//in src/com/ziclix/python/sql/PyCursor.java
throw info.unexpectedCall(0, false);

              
//in src/com/ziclix/python/sql/PyCursor.java
throw info.unexpectedCall(1, false);

              
//in src/com/ziclix/python/sql/PyCursor.java
throw info.unexpectedCall(2, false);

              
//in src/com/ziclix/python/sql/PyCursor.java
throw info.unexpectedCall(3, false);

              
//in src/com/ziclix/python/sql/PyCursor.java
throw info.unexpectedCall(args.length, true);

              
//in src/org/python/indexer/ast/NNode.java
throw ix;

              
//in src/org/python/compiler/Module.java
throw e;

              
//in src/org/python/compiler/ScopesCompiler.java
throw ParserFacade.fixParseError(null, t, code_compiler.getFilename());

              
//in src/org/python/antlr/ast/aliasDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/antlr/ast/aliasDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/aliasDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/aliasDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/aliasDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/aliasDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/aliasDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/aliasDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/antlr/ast/aliasDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/aliasDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/antlr/ast/aliasDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/antlr/ast/aliasDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/antlr/ast/aliasDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/antlr/ast/aliasDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/antlr/ast/aliasDerived.java
throw exc;

              
//in src/org/python/antlr/ast/aliasDerived.java
throw exc;

              
//in src/org/python/antlr/ast/aliasDerived.java
throw exc;

              
//in src/org/python/antlr/ast/aliasDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/antlr/ast/aliasDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/antlr/ast/aliasDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/antlr/ast/aliasDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/AttributeDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/antlr/ast/AttributeDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/AttributeDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/AttributeDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/AttributeDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/AttributeDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/AttributeDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/AttributeDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/antlr/ast/AttributeDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/AttributeDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/antlr/ast/AttributeDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/antlr/ast/AttributeDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/antlr/ast/AttributeDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/antlr/ast/AttributeDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/antlr/ast/AttributeDerived.java
throw exc;

              
//in src/org/python/antlr/ast/AttributeDerived.java
throw exc;

              
//in src/org/python/antlr/ast/AttributeDerived.java
throw exc;

              
//in src/org/python/antlr/ast/AttributeDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/antlr/ast/AttributeDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/antlr/ast/AttributeDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/antlr/ast/AttributeDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/UnaryOpDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/antlr/ast/UnaryOpDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/UnaryOpDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/UnaryOpDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/UnaryOpDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/UnaryOpDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/UnaryOpDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/UnaryOpDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/antlr/ast/UnaryOpDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/UnaryOpDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/antlr/ast/UnaryOpDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/antlr/ast/UnaryOpDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/antlr/ast/UnaryOpDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/antlr/ast/UnaryOpDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/antlr/ast/UnaryOpDerived.java
throw exc;

              
//in src/org/python/antlr/ast/UnaryOpDerived.java
throw exc;

              
//in src/org/python/antlr/ast/UnaryOpDerived.java
throw exc;

              
//in src/org/python/antlr/ast/UnaryOpDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/antlr/ast/UnaryOpDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/antlr/ast/UnaryOpDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/antlr/ast/UnaryOpDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/BreakDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/antlr/ast/BreakDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/BreakDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/BreakDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/BreakDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/BreakDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/BreakDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/BreakDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/antlr/ast/BreakDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/BreakDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/antlr/ast/BreakDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/antlr/ast/BreakDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/antlr/ast/BreakDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/antlr/ast/BreakDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/antlr/ast/BreakDerived.java
throw exc;

              
//in src/org/python/antlr/ast/BreakDerived.java
throw exc;

              
//in src/org/python/antlr/ast/BreakDerived.java
throw exc;

              
//in src/org/python/antlr/ast/BreakDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/antlr/ast/BreakDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/antlr/ast/BreakDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/antlr/ast/BreakDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/BoolOpDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/antlr/ast/BoolOpDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/BoolOpDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/BoolOpDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/BoolOpDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/BoolOpDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/BoolOpDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/BoolOpDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/antlr/ast/BoolOpDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/BoolOpDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/antlr/ast/BoolOpDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/antlr/ast/BoolOpDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/antlr/ast/BoolOpDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/antlr/ast/BoolOpDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/antlr/ast/BoolOpDerived.java
throw exc;

              
//in src/org/python/antlr/ast/BoolOpDerived.java
throw exc;

              
//in src/org/python/antlr/ast/BoolOpDerived.java
throw exc;

              
//in src/org/python/antlr/ast/BoolOpDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/antlr/ast/BoolOpDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/antlr/ast/BoolOpDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/antlr/ast/BoolOpDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ListCompDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/antlr/ast/ListCompDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ListCompDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ListCompDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ListCompDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ListCompDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ListCompDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ListCompDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/antlr/ast/ListCompDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ListCompDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/antlr/ast/ListCompDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/antlr/ast/ListCompDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/antlr/ast/ListCompDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/antlr/ast/ListCompDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/antlr/ast/ListCompDerived.java
throw exc;

              
//in src/org/python/antlr/ast/ListCompDerived.java
throw exc;

              
//in src/org/python/antlr/ast/ListCompDerived.java
throw exc;

              
//in src/org/python/antlr/ast/ListCompDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/antlr/ast/ListCompDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/antlr/ast/ListCompDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/antlr/ast/ListCompDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ContinueDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/antlr/ast/ContinueDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ContinueDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ContinueDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ContinueDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ContinueDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ContinueDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ContinueDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/antlr/ast/ContinueDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ContinueDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/antlr/ast/ContinueDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/antlr/ast/ContinueDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/antlr/ast/ContinueDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/antlr/ast/ContinueDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/antlr/ast/ContinueDerived.java
throw exc;

              
//in src/org/python/antlr/ast/ContinueDerived.java
throw exc;

              
//in src/org/python/antlr/ast/ContinueDerived.java
throw exc;

              
//in src/org/python/antlr/ast/ContinueDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/antlr/ast/ContinueDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/antlr/ast/ContinueDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/antlr/ast/ContinueDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/TupleDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/antlr/ast/TupleDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/TupleDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/TupleDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/TupleDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/TupleDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/TupleDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/TupleDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/antlr/ast/TupleDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/TupleDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/antlr/ast/TupleDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/antlr/ast/TupleDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/antlr/ast/TupleDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/antlr/ast/TupleDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/antlr/ast/TupleDerived.java
throw exc;

              
//in src/org/python/antlr/ast/TupleDerived.java
throw exc;

              
//in src/org/python/antlr/ast/TupleDerived.java
throw exc;

              
//in src/org/python/antlr/ast/TupleDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/antlr/ast/TupleDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/antlr/ast/TupleDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/antlr/ast/TupleDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/InteractiveDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/antlr/ast/InteractiveDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/InteractiveDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/InteractiveDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/InteractiveDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/InteractiveDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/InteractiveDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/InteractiveDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/antlr/ast/InteractiveDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/InteractiveDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/antlr/ast/InteractiveDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/antlr/ast/InteractiveDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/antlr/ast/InteractiveDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/antlr/ast/InteractiveDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/antlr/ast/InteractiveDerived.java
throw exc;

              
//in src/org/python/antlr/ast/InteractiveDerived.java
throw exc;

              
//in src/org/python/antlr/ast/InteractiveDerived.java
throw exc;

              
//in src/org/python/antlr/ast/InteractiveDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/antlr/ast/InteractiveDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/antlr/ast/InteractiveDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/antlr/ast/InteractiveDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/DeleteDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/antlr/ast/DeleteDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/DeleteDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/DeleteDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/DeleteDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/DeleteDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/DeleteDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/DeleteDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/antlr/ast/DeleteDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/DeleteDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/antlr/ast/DeleteDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/antlr/ast/DeleteDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/antlr/ast/DeleteDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/antlr/ast/DeleteDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/antlr/ast/DeleteDerived.java
throw exc;

              
//in src/org/python/antlr/ast/DeleteDerived.java
throw exc;

              
//in src/org/python/antlr/ast/DeleteDerived.java
throw exc;

              
//in src/org/python/antlr/ast/DeleteDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/antlr/ast/DeleteDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/antlr/ast/DeleteDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/antlr/ast/DeleteDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/IndexDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/antlr/ast/IndexDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/IndexDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/IndexDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/IndexDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/IndexDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/IndexDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/IndexDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/antlr/ast/IndexDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/IndexDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/antlr/ast/IndexDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/antlr/ast/IndexDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/antlr/ast/IndexDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/antlr/ast/IndexDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/antlr/ast/IndexDerived.java
throw exc;

              
//in src/org/python/antlr/ast/IndexDerived.java
throw exc;

              
//in src/org/python/antlr/ast/IndexDerived.java
throw exc;

              
//in src/org/python/antlr/ast/IndexDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/antlr/ast/IndexDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/antlr/ast/IndexDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/antlr/ast/IndexDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ModuleDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/antlr/ast/ModuleDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ModuleDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ModuleDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ModuleDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ModuleDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ModuleDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ModuleDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/antlr/ast/ModuleDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ModuleDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/antlr/ast/ModuleDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/antlr/ast/ModuleDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/antlr/ast/ModuleDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/antlr/ast/ModuleDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/antlr/ast/ModuleDerived.java
throw exc;

              
//in src/org/python/antlr/ast/ModuleDerived.java
throw exc;

              
//in src/org/python/antlr/ast/ModuleDerived.java
throw exc;

              
//in src/org/python/antlr/ast/ModuleDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/antlr/ast/ModuleDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/antlr/ast/ModuleDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/antlr/ast/ModuleDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/CallDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/antlr/ast/CallDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/CallDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/CallDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/CallDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/CallDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/CallDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/CallDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/antlr/ast/CallDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/CallDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/antlr/ast/CallDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/antlr/ast/CallDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/antlr/ast/CallDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/antlr/ast/CallDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/antlr/ast/CallDerived.java
throw exc;

              
//in src/org/python/antlr/ast/CallDerived.java
throw exc;

              
//in src/org/python/antlr/ast/CallDerived.java
throw exc;

              
//in src/org/python/antlr/ast/CallDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/antlr/ast/CallDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/antlr/ast/CallDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/antlr/ast/CallDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ReturnDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/antlr/ast/ReturnDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ReturnDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ReturnDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ReturnDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ReturnDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ReturnDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ReturnDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/antlr/ast/ReturnDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ReturnDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/antlr/ast/ReturnDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/antlr/ast/ReturnDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/antlr/ast/ReturnDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/antlr/ast/ReturnDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/antlr/ast/ReturnDerived.java
throw exc;

              
//in src/org/python/antlr/ast/ReturnDerived.java
throw exc;

              
//in src/org/python/antlr/ast/ReturnDerived.java
throw exc;

              
//in src/org/python/antlr/ast/ReturnDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/antlr/ast/ReturnDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/antlr/ast/ReturnDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/antlr/ast/ReturnDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ForDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/antlr/ast/ForDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ForDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ForDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ForDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ForDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ForDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ForDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/antlr/ast/ForDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ForDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/antlr/ast/ForDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/antlr/ast/ForDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/antlr/ast/ForDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/antlr/ast/ForDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/antlr/ast/ForDerived.java
throw exc;

              
//in src/org/python/antlr/ast/ForDerived.java
throw exc;

              
//in src/org/python/antlr/ast/ForDerived.java
throw exc;

              
//in src/org/python/antlr/ast/ForDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/antlr/ast/ForDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/antlr/ast/ForDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/antlr/ast/ForDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ExceptHandlerDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/antlr/ast/ExceptHandlerDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ExceptHandlerDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ExceptHandlerDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ExceptHandlerDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ExceptHandlerDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ExceptHandlerDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ExceptHandlerDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/antlr/ast/ExceptHandlerDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ExceptHandlerDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/antlr/ast/ExceptHandlerDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/antlr/ast/ExceptHandlerDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/antlr/ast/ExceptHandlerDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/antlr/ast/ExceptHandlerDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/antlr/ast/ExceptHandlerDerived.java
throw exc;

              
//in src/org/python/antlr/ast/ExceptHandlerDerived.java
throw exc;

              
//in src/org/python/antlr/ast/ExceptHandlerDerived.java
throw exc;

              
//in src/org/python/antlr/ast/ExceptHandlerDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/antlr/ast/ExceptHandlerDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/antlr/ast/ExceptHandlerDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/antlr/ast/ExceptHandlerDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/SubscriptDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/antlr/ast/SubscriptDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/SubscriptDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/SubscriptDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/SubscriptDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/SubscriptDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/SubscriptDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/SubscriptDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/antlr/ast/SubscriptDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/SubscriptDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/antlr/ast/SubscriptDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/antlr/ast/SubscriptDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/antlr/ast/SubscriptDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/antlr/ast/SubscriptDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/antlr/ast/SubscriptDerived.java
throw exc;

              
//in src/org/python/antlr/ast/SubscriptDerived.java
throw exc;

              
//in src/org/python/antlr/ast/SubscriptDerived.java
throw exc;

              
//in src/org/python/antlr/ast/SubscriptDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/antlr/ast/SubscriptDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/antlr/ast/SubscriptDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/antlr/ast/SubscriptDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/DictDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/antlr/ast/DictDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/DictDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/DictDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/DictDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/DictDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/DictDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/DictDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/antlr/ast/DictDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/DictDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/antlr/ast/DictDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/antlr/ast/DictDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/antlr/ast/DictDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/antlr/ast/DictDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/antlr/ast/DictDerived.java
throw exc;

              
//in src/org/python/antlr/ast/DictDerived.java
throw exc;

              
//in src/org/python/antlr/ast/DictDerived.java
throw exc;

              
//in src/org/python/antlr/ast/DictDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/antlr/ast/DictDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/antlr/ast/DictDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/antlr/ast/DictDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/LambdaDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/antlr/ast/LambdaDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/LambdaDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/LambdaDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/LambdaDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/LambdaDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/LambdaDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/LambdaDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/antlr/ast/LambdaDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/LambdaDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/antlr/ast/LambdaDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/antlr/ast/LambdaDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/antlr/ast/LambdaDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/antlr/ast/LambdaDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/antlr/ast/LambdaDerived.java
throw exc;

              
//in src/org/python/antlr/ast/LambdaDerived.java
throw exc;

              
//in src/org/python/antlr/ast/LambdaDerived.java
throw exc;

              
//in src/org/python/antlr/ast/LambdaDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/antlr/ast/LambdaDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/antlr/ast/LambdaDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/antlr/ast/LambdaDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/GlobalDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/antlr/ast/GlobalDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/GlobalDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/GlobalDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/GlobalDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/GlobalDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/GlobalDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/GlobalDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/antlr/ast/GlobalDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/GlobalDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/antlr/ast/GlobalDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/antlr/ast/GlobalDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/antlr/ast/GlobalDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/antlr/ast/GlobalDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/antlr/ast/GlobalDerived.java
throw exc;

              
//in src/org/python/antlr/ast/GlobalDerived.java
throw exc;

              
//in src/org/python/antlr/ast/GlobalDerived.java
throw exc;

              
//in src/org/python/antlr/ast/GlobalDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/antlr/ast/GlobalDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/antlr/ast/GlobalDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/antlr/ast/GlobalDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ListDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/antlr/ast/ListDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ListDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ListDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ListDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ListDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ListDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ListDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/antlr/ast/ListDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ListDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/antlr/ast/ListDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/antlr/ast/ListDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/antlr/ast/ListDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/antlr/ast/ListDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/antlr/ast/ListDerived.java
throw exc;

              
//in src/org/python/antlr/ast/ListDerived.java
throw exc;

              
//in src/org/python/antlr/ast/ListDerived.java
throw exc;

              
//in src/org/python/antlr/ast/ListDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/antlr/ast/ListDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/antlr/ast/ListDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/antlr/ast/ListDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/BinOpDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/antlr/ast/BinOpDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/BinOpDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/BinOpDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/BinOpDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/BinOpDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/BinOpDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/BinOpDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/antlr/ast/BinOpDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/BinOpDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/antlr/ast/BinOpDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/antlr/ast/BinOpDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/antlr/ast/BinOpDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/antlr/ast/BinOpDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/antlr/ast/BinOpDerived.java
throw exc;

              
//in src/org/python/antlr/ast/BinOpDerived.java
throw exc;

              
//in src/org/python/antlr/ast/BinOpDerived.java
throw exc;

              
//in src/org/python/antlr/ast/BinOpDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/antlr/ast/BinOpDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/antlr/ast/BinOpDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/antlr/ast/BinOpDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ClassDefDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/antlr/ast/ClassDefDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ClassDefDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ClassDefDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ClassDefDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ClassDefDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ClassDefDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ClassDefDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/antlr/ast/ClassDefDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ClassDefDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/antlr/ast/ClassDefDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/antlr/ast/ClassDefDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/antlr/ast/ClassDefDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/antlr/ast/ClassDefDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/antlr/ast/ClassDefDerived.java
throw exc;

              
//in src/org/python/antlr/ast/ClassDefDerived.java
throw exc;

              
//in src/org/python/antlr/ast/ClassDefDerived.java
throw exc;

              
//in src/org/python/antlr/ast/ClassDefDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/antlr/ast/ClassDefDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/antlr/ast/ClassDefDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/antlr/ast/ClassDefDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ExpressionDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/antlr/ast/ExpressionDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ExpressionDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ExpressionDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ExpressionDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ExpressionDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ExpressionDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ExpressionDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/antlr/ast/ExpressionDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ExpressionDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/antlr/ast/ExpressionDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/antlr/ast/ExpressionDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/antlr/ast/ExpressionDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/antlr/ast/ExpressionDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/antlr/ast/ExpressionDerived.java
throw exc;

              
//in src/org/python/antlr/ast/ExpressionDerived.java
throw exc;

              
//in src/org/python/antlr/ast/ExpressionDerived.java
throw exc;

              
//in src/org/python/antlr/ast/ExpressionDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/antlr/ast/ExpressionDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/antlr/ast/ExpressionDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/antlr/ast/ExpressionDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/SliceDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/antlr/ast/SliceDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/SliceDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/SliceDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/SliceDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/SliceDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/SliceDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/SliceDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/antlr/ast/SliceDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/SliceDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/antlr/ast/SliceDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/antlr/ast/SliceDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/antlr/ast/SliceDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/antlr/ast/SliceDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/antlr/ast/SliceDerived.java
throw exc;

              
//in src/org/python/antlr/ast/SliceDerived.java
throw exc;

              
//in src/org/python/antlr/ast/SliceDerived.java
throw exc;

              
//in src/org/python/antlr/ast/SliceDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/antlr/ast/SliceDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/antlr/ast/SliceDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/antlr/ast/SliceDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/NumDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/antlr/ast/NumDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/NumDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/NumDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/NumDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/NumDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/NumDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/NumDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/antlr/ast/NumDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/NumDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/antlr/ast/NumDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/antlr/ast/NumDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/antlr/ast/NumDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/antlr/ast/NumDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/antlr/ast/NumDerived.java
throw exc;

              
//in src/org/python/antlr/ast/NumDerived.java
throw exc;

              
//in src/org/python/antlr/ast/NumDerived.java
throw exc;

              
//in src/org/python/antlr/ast/NumDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/antlr/ast/NumDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/antlr/ast/NumDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/antlr/ast/NumDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ExprDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/antlr/ast/ExprDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ExprDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ExprDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ExprDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ExprDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ExprDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ExprDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/antlr/ast/ExprDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ExprDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/antlr/ast/ExprDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/antlr/ast/ExprDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/antlr/ast/ExprDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/antlr/ast/ExprDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/antlr/ast/ExprDerived.java
throw exc;

              
//in src/org/python/antlr/ast/ExprDerived.java
throw exc;

              
//in src/org/python/antlr/ast/ExprDerived.java
throw exc;

              
//in src/org/python/antlr/ast/ExprDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/antlr/ast/ExprDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/antlr/ast/ExprDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/antlr/ast/ExprDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/NameDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/antlr/ast/NameDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/NameDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/NameDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/NameDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/NameDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/NameDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/NameDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/antlr/ast/NameDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/NameDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/antlr/ast/NameDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/antlr/ast/NameDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/antlr/ast/NameDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/antlr/ast/NameDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/antlr/ast/NameDerived.java
throw exc;

              
//in src/org/python/antlr/ast/NameDerived.java
throw exc;

              
//in src/org/python/antlr/ast/NameDerived.java
throw exc;

              
//in src/org/python/antlr/ast/NameDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/antlr/ast/NameDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/antlr/ast/NameDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/antlr/ast/NameDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/TryFinallyDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/antlr/ast/TryFinallyDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/TryFinallyDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/TryFinallyDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/TryFinallyDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/TryFinallyDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/TryFinallyDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/TryFinallyDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/antlr/ast/TryFinallyDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/TryFinallyDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/antlr/ast/TryFinallyDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/antlr/ast/TryFinallyDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/antlr/ast/TryFinallyDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/antlr/ast/TryFinallyDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/antlr/ast/TryFinallyDerived.java
throw exc;

              
//in src/org/python/antlr/ast/TryFinallyDerived.java
throw exc;

              
//in src/org/python/antlr/ast/TryFinallyDerived.java
throw exc;

              
//in src/org/python/antlr/ast/TryFinallyDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/antlr/ast/TryFinallyDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/antlr/ast/TryFinallyDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/antlr/ast/TryFinallyDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/IfExpDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/antlr/ast/IfExpDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/IfExpDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/IfExpDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/IfExpDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/IfExpDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/IfExpDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/IfExpDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/antlr/ast/IfExpDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/IfExpDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/antlr/ast/IfExpDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/antlr/ast/IfExpDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/antlr/ast/IfExpDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/antlr/ast/IfExpDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/antlr/ast/IfExpDerived.java
throw exc;

              
//in src/org/python/antlr/ast/IfExpDerived.java
throw exc;

              
//in src/org/python/antlr/ast/IfExpDerived.java
throw exc;

              
//in src/org/python/antlr/ast/IfExpDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/antlr/ast/IfExpDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/antlr/ast/IfExpDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/antlr/ast/IfExpDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/AugAssignDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/antlr/ast/AugAssignDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/AugAssignDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/AugAssignDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/AugAssignDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/AugAssignDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/AugAssignDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/AugAssignDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/antlr/ast/AugAssignDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/AugAssignDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/antlr/ast/AugAssignDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/antlr/ast/AugAssignDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/antlr/ast/AugAssignDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/antlr/ast/AugAssignDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/antlr/ast/AugAssignDerived.java
throw exc;

              
//in src/org/python/antlr/ast/AugAssignDerived.java
throw exc;

              
//in src/org/python/antlr/ast/AugAssignDerived.java
throw exc;

              
//in src/org/python/antlr/ast/AugAssignDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/antlr/ast/AugAssignDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/antlr/ast/AugAssignDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/antlr/ast/AugAssignDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ImportDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/antlr/ast/ImportDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ImportDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ImportDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ImportDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ImportDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ImportDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ImportDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/antlr/ast/ImportDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ImportDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/antlr/ast/ImportDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/antlr/ast/ImportDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/antlr/ast/ImportDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/antlr/ast/ImportDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/antlr/ast/ImportDerived.java
throw exc;

              
//in src/org/python/antlr/ast/ImportDerived.java
throw exc;

              
//in src/org/python/antlr/ast/ImportDerived.java
throw exc;

              
//in src/org/python/antlr/ast/ImportDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/antlr/ast/ImportDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/antlr/ast/ImportDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/antlr/ast/ImportDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/IfDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/antlr/ast/IfDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/IfDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/IfDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/IfDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/IfDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/IfDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/IfDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/antlr/ast/IfDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/IfDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/antlr/ast/IfDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/antlr/ast/IfDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/antlr/ast/IfDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/antlr/ast/IfDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/antlr/ast/IfDerived.java
throw exc;

              
//in src/org/python/antlr/ast/IfDerived.java
throw exc;

              
//in src/org/python/antlr/ast/IfDerived.java
throw exc;

              
//in src/org/python/antlr/ast/IfDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/antlr/ast/IfDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/antlr/ast/IfDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/antlr/ast/IfDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/PassDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/antlr/ast/PassDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/PassDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/PassDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/PassDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/PassDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/PassDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/PassDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/antlr/ast/PassDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/PassDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/antlr/ast/PassDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/antlr/ast/PassDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/antlr/ast/PassDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/antlr/ast/PassDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/antlr/ast/PassDerived.java
throw exc;

              
//in src/org/python/antlr/ast/PassDerived.java
throw exc;

              
//in src/org/python/antlr/ast/PassDerived.java
throw exc;

              
//in src/org/python/antlr/ast/PassDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/antlr/ast/PassDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/antlr/ast/PassDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/antlr/ast/PassDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/FunctionDefDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/antlr/ast/FunctionDefDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/FunctionDefDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/FunctionDefDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/FunctionDefDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/FunctionDefDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/FunctionDefDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/FunctionDefDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/antlr/ast/FunctionDefDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/FunctionDefDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/antlr/ast/FunctionDefDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/antlr/ast/FunctionDefDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/antlr/ast/FunctionDefDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/antlr/ast/FunctionDefDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/antlr/ast/FunctionDefDerived.java
throw exc;

              
//in src/org/python/antlr/ast/FunctionDefDerived.java
throw exc;

              
//in src/org/python/antlr/ast/FunctionDefDerived.java
throw exc;

              
//in src/org/python/antlr/ast/FunctionDefDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/antlr/ast/FunctionDefDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/antlr/ast/FunctionDefDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/antlr/ast/FunctionDefDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/argumentsDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/antlr/ast/argumentsDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/argumentsDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/argumentsDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/argumentsDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/argumentsDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/argumentsDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/argumentsDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/antlr/ast/argumentsDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/argumentsDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/antlr/ast/argumentsDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/antlr/ast/argumentsDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/antlr/ast/argumentsDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/antlr/ast/argumentsDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/antlr/ast/argumentsDerived.java
throw exc;

              
//in src/org/python/antlr/ast/argumentsDerived.java
throw exc;

              
//in src/org/python/antlr/ast/argumentsDerived.java
throw exc;

              
//in src/org/python/antlr/ast/argumentsDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/antlr/ast/argumentsDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/antlr/ast/argumentsDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/antlr/ast/argumentsDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/WithDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/antlr/ast/WithDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/WithDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/WithDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/WithDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/WithDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/WithDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/WithDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/antlr/ast/WithDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/WithDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/antlr/ast/WithDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/antlr/ast/WithDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/antlr/ast/WithDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/antlr/ast/WithDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/antlr/ast/WithDerived.java
throw exc;

              
//in src/org/python/antlr/ast/WithDerived.java
throw exc;

              
//in src/org/python/antlr/ast/WithDerived.java
throw exc;

              
//in src/org/python/antlr/ast/WithDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/antlr/ast/WithDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/antlr/ast/WithDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/antlr/ast/WithDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ImportFromDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/antlr/ast/ImportFromDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ImportFromDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ImportFromDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ImportFromDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ImportFromDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ImportFromDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ImportFromDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/antlr/ast/ImportFromDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ImportFromDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/antlr/ast/ImportFromDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/antlr/ast/ImportFromDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/antlr/ast/ImportFromDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/antlr/ast/ImportFromDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/antlr/ast/ImportFromDerived.java
throw exc;

              
//in src/org/python/antlr/ast/ImportFromDerived.java
throw exc;

              
//in src/org/python/antlr/ast/ImportFromDerived.java
throw exc;

              
//in src/org/python/antlr/ast/ImportFromDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/antlr/ast/ImportFromDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/antlr/ast/ImportFromDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/antlr/ast/ImportFromDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/CompareDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/antlr/ast/CompareDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/CompareDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/CompareDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/CompareDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/CompareDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/CompareDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/CompareDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/antlr/ast/CompareDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/CompareDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/antlr/ast/CompareDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/antlr/ast/CompareDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/antlr/ast/CompareDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/antlr/ast/CompareDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/antlr/ast/CompareDerived.java
throw exc;

              
//in src/org/python/antlr/ast/CompareDerived.java
throw exc;

              
//in src/org/python/antlr/ast/CompareDerived.java
throw exc;

              
//in src/org/python/antlr/ast/CompareDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/antlr/ast/CompareDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/antlr/ast/CompareDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/antlr/ast/CompareDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ReprDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/antlr/ast/ReprDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ReprDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ReprDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ReprDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ReprDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ReprDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ReprDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/antlr/ast/ReprDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ReprDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/antlr/ast/ReprDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/antlr/ast/ReprDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/antlr/ast/ReprDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/antlr/ast/ReprDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/antlr/ast/ReprDerived.java
throw exc;

              
//in src/org/python/antlr/ast/ReprDerived.java
throw exc;

              
//in src/org/python/antlr/ast/ReprDerived.java
throw exc;

              
//in src/org/python/antlr/ast/ReprDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/antlr/ast/ReprDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/antlr/ast/ReprDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/antlr/ast/ReprDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/StrDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/antlr/ast/StrDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/StrDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/StrDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/StrDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/StrDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/StrDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/StrDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/antlr/ast/StrDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/StrDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/antlr/ast/StrDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/antlr/ast/StrDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/antlr/ast/StrDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/antlr/ast/StrDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/antlr/ast/StrDerived.java
throw exc;

              
//in src/org/python/antlr/ast/StrDerived.java
throw exc;

              
//in src/org/python/antlr/ast/StrDerived.java
throw exc;

              
//in src/org/python/antlr/ast/StrDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/antlr/ast/StrDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/antlr/ast/StrDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/antlr/ast/StrDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/YieldDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/antlr/ast/YieldDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/YieldDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/YieldDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/YieldDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/YieldDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/YieldDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/YieldDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/antlr/ast/YieldDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/YieldDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/antlr/ast/YieldDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/antlr/ast/YieldDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/antlr/ast/YieldDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/antlr/ast/YieldDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/antlr/ast/YieldDerived.java
throw exc;

              
//in src/org/python/antlr/ast/YieldDerived.java
throw exc;

              
//in src/org/python/antlr/ast/YieldDerived.java
throw exc;

              
//in src/org/python/antlr/ast/YieldDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/antlr/ast/YieldDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/antlr/ast/YieldDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/antlr/ast/YieldDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/EllipsisDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/antlr/ast/EllipsisDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/EllipsisDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/EllipsisDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/EllipsisDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/EllipsisDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/EllipsisDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/EllipsisDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/antlr/ast/EllipsisDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/EllipsisDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/antlr/ast/EllipsisDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/antlr/ast/EllipsisDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/antlr/ast/EllipsisDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/antlr/ast/EllipsisDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/antlr/ast/EllipsisDerived.java
throw exc;

              
//in src/org/python/antlr/ast/EllipsisDerived.java
throw exc;

              
//in src/org/python/antlr/ast/EllipsisDerived.java
throw exc;

              
//in src/org/python/antlr/ast/EllipsisDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/antlr/ast/EllipsisDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/antlr/ast/EllipsisDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/antlr/ast/EllipsisDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/RaiseDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/antlr/ast/RaiseDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/RaiseDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/RaiseDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/RaiseDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/RaiseDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/RaiseDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/RaiseDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/antlr/ast/RaiseDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/RaiseDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/antlr/ast/RaiseDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/antlr/ast/RaiseDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/antlr/ast/RaiseDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/antlr/ast/RaiseDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/antlr/ast/RaiseDerived.java
throw exc;

              
//in src/org/python/antlr/ast/RaiseDerived.java
throw exc;

              
//in src/org/python/antlr/ast/RaiseDerived.java
throw exc;

              
//in src/org/python/antlr/ast/RaiseDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/antlr/ast/RaiseDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/antlr/ast/RaiseDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/antlr/ast/RaiseDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/AssignDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/antlr/ast/AssignDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/AssignDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/AssignDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/AssignDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/AssignDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/AssignDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/AssignDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/antlr/ast/AssignDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/AssignDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/antlr/ast/AssignDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/antlr/ast/AssignDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/antlr/ast/AssignDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/antlr/ast/AssignDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/antlr/ast/AssignDerived.java
throw exc;

              
//in src/org/python/antlr/ast/AssignDerived.java
throw exc;

              
//in src/org/python/antlr/ast/AssignDerived.java
throw exc;

              
//in src/org/python/antlr/ast/AssignDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/antlr/ast/AssignDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/antlr/ast/AssignDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/antlr/ast/AssignDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/GeneratorExpDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/antlr/ast/GeneratorExpDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/GeneratorExpDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/GeneratorExpDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/GeneratorExpDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/GeneratorExpDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/GeneratorExpDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/GeneratorExpDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/antlr/ast/GeneratorExpDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/GeneratorExpDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/antlr/ast/GeneratorExpDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/antlr/ast/GeneratorExpDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/antlr/ast/GeneratorExpDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/antlr/ast/GeneratorExpDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/antlr/ast/GeneratorExpDerived.java
throw exc;

              
//in src/org/python/antlr/ast/GeneratorExpDerived.java
throw exc;

              
//in src/org/python/antlr/ast/GeneratorExpDerived.java
throw exc;

              
//in src/org/python/antlr/ast/GeneratorExpDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/antlr/ast/GeneratorExpDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/antlr/ast/GeneratorExpDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/antlr/ast/GeneratorExpDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/SuiteDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/antlr/ast/SuiteDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/SuiteDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/SuiteDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/SuiteDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/SuiteDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/SuiteDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/SuiteDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/antlr/ast/SuiteDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/SuiteDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/antlr/ast/SuiteDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/antlr/ast/SuiteDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/antlr/ast/SuiteDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/antlr/ast/SuiteDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/antlr/ast/SuiteDerived.java
throw exc;

              
//in src/org/python/antlr/ast/SuiteDerived.java
throw exc;

              
//in src/org/python/antlr/ast/SuiteDerived.java
throw exc;

              
//in src/org/python/antlr/ast/SuiteDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/antlr/ast/SuiteDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/antlr/ast/SuiteDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/antlr/ast/SuiteDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/AssertDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/antlr/ast/AssertDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/AssertDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/AssertDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/AssertDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/AssertDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/AssertDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/AssertDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/antlr/ast/AssertDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/AssertDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/antlr/ast/AssertDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/antlr/ast/AssertDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/antlr/ast/AssertDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/antlr/ast/AssertDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/antlr/ast/AssertDerived.java
throw exc;

              
//in src/org/python/antlr/ast/AssertDerived.java
throw exc;

              
//in src/org/python/antlr/ast/AssertDerived.java
throw exc;

              
//in src/org/python/antlr/ast/AssertDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/antlr/ast/AssertDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/antlr/ast/AssertDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/antlr/ast/AssertDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/TryExceptDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/antlr/ast/TryExceptDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/TryExceptDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/TryExceptDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/TryExceptDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/TryExceptDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/TryExceptDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/TryExceptDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/antlr/ast/TryExceptDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/TryExceptDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/antlr/ast/TryExceptDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/antlr/ast/TryExceptDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/antlr/ast/TryExceptDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/antlr/ast/TryExceptDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/antlr/ast/TryExceptDerived.java
throw exc;

              
//in src/org/python/antlr/ast/TryExceptDerived.java
throw exc;

              
//in src/org/python/antlr/ast/TryExceptDerived.java
throw exc;

              
//in src/org/python/antlr/ast/TryExceptDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/antlr/ast/TryExceptDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/antlr/ast/TryExceptDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/antlr/ast/TryExceptDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ExecDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/antlr/ast/ExecDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ExecDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ExecDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ExecDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ExecDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ExecDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ExecDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/antlr/ast/ExecDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ExecDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/antlr/ast/ExecDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/antlr/ast/ExecDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/antlr/ast/ExecDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/antlr/ast/ExecDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/antlr/ast/ExecDerived.java
throw exc;

              
//in src/org/python/antlr/ast/ExecDerived.java
throw exc;

              
//in src/org/python/antlr/ast/ExecDerived.java
throw exc;

              
//in src/org/python/antlr/ast/ExecDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/antlr/ast/ExecDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/antlr/ast/ExecDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/antlr/ast/ExecDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/WhileDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/antlr/ast/WhileDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/WhileDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/WhileDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/WhileDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/WhileDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/WhileDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/WhileDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/antlr/ast/WhileDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/WhileDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/antlr/ast/WhileDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/antlr/ast/WhileDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/antlr/ast/WhileDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/antlr/ast/WhileDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/antlr/ast/WhileDerived.java
throw exc;

              
//in src/org/python/antlr/ast/WhileDerived.java
throw exc;

              
//in src/org/python/antlr/ast/WhileDerived.java
throw exc;

              
//in src/org/python/antlr/ast/WhileDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/antlr/ast/WhileDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/antlr/ast/WhileDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/antlr/ast/WhileDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/keywordDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/antlr/ast/keywordDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/keywordDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/keywordDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/keywordDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/keywordDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/keywordDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/keywordDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/antlr/ast/keywordDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/keywordDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/antlr/ast/keywordDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/antlr/ast/keywordDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/antlr/ast/keywordDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/antlr/ast/keywordDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/antlr/ast/keywordDerived.java
throw exc;

              
//in src/org/python/antlr/ast/keywordDerived.java
throw exc;

              
//in src/org/python/antlr/ast/keywordDerived.java
throw exc;

              
//in src/org/python/antlr/ast/keywordDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/antlr/ast/keywordDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/antlr/ast/keywordDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/antlr/ast/keywordDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/comprehensionDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/antlr/ast/comprehensionDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/comprehensionDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/comprehensionDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/comprehensionDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/comprehensionDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/comprehensionDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/comprehensionDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/antlr/ast/comprehensionDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/comprehensionDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/antlr/ast/comprehensionDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/antlr/ast/comprehensionDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/antlr/ast/comprehensionDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/antlr/ast/comprehensionDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/antlr/ast/comprehensionDerived.java
throw exc;

              
//in src/org/python/antlr/ast/comprehensionDerived.java
throw exc;

              
//in src/org/python/antlr/ast/comprehensionDerived.java
throw exc;

              
//in src/org/python/antlr/ast/comprehensionDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/antlr/ast/comprehensionDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/antlr/ast/comprehensionDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/antlr/ast/comprehensionDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ExtSliceDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/antlr/ast/ExtSliceDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ExtSliceDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ExtSliceDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ExtSliceDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ExtSliceDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ExtSliceDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ExtSliceDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/antlr/ast/ExtSliceDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/ExtSliceDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/antlr/ast/ExtSliceDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/antlr/ast/ExtSliceDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/antlr/ast/ExtSliceDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/antlr/ast/ExtSliceDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/antlr/ast/ExtSliceDerived.java
throw exc;

              
//in src/org/python/antlr/ast/ExtSliceDerived.java
throw exc;

              
//in src/org/python/antlr/ast/ExtSliceDerived.java
throw exc;

              
//in src/org/python/antlr/ast/ExtSliceDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/antlr/ast/ExtSliceDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/antlr/ast/ExtSliceDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/antlr/ast/ExtSliceDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/PrintDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/antlr/ast/PrintDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/PrintDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/PrintDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/PrintDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/PrintDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/PrintDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/PrintDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/antlr/ast/PrintDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/ast/PrintDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/antlr/ast/PrintDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/antlr/ast/PrintDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/antlr/ast/PrintDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/antlr/ast/PrintDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/antlr/ast/PrintDerived.java
throw exc;

              
//in src/org/python/antlr/ast/PrintDerived.java
throw exc;

              
//in src/org/python/antlr/ast/PrintDerived.java
throw exc;

              
//in src/org/python/antlr/ast/PrintDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/antlr/ast/PrintDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/antlr/ast/PrintDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/antlr/ast/PrintDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/PowDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/antlr/op/PowDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/PowDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/PowDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/PowDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/PowDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/PowDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/PowDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/antlr/op/PowDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/PowDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/antlr/op/PowDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/antlr/op/PowDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/antlr/op/PowDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/antlr/op/PowDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/antlr/op/PowDerived.java
throw exc;

              
//in src/org/python/antlr/op/PowDerived.java
throw exc;

              
//in src/org/python/antlr/op/PowDerived.java
throw exc;

              
//in src/org/python/antlr/op/PowDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/antlr/op/PowDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/antlr/op/PowDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/antlr/op/PowDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/LtEDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/antlr/op/LtEDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/LtEDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/LtEDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/LtEDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/LtEDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/LtEDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/LtEDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/antlr/op/LtEDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/LtEDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/antlr/op/LtEDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/antlr/op/LtEDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/antlr/op/LtEDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/antlr/op/LtEDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/antlr/op/LtEDerived.java
throw exc;

              
//in src/org/python/antlr/op/LtEDerived.java
throw exc;

              
//in src/org/python/antlr/op/LtEDerived.java
throw exc;

              
//in src/org/python/antlr/op/LtEDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/antlr/op/LtEDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/antlr/op/LtEDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/antlr/op/LtEDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/ParamDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/antlr/op/ParamDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/ParamDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/ParamDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/ParamDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/ParamDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/ParamDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/ParamDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/antlr/op/ParamDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/ParamDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/antlr/op/ParamDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/antlr/op/ParamDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/antlr/op/ParamDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/antlr/op/ParamDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/antlr/op/ParamDerived.java
throw exc;

              
//in src/org/python/antlr/op/ParamDerived.java
throw exc;

              
//in src/org/python/antlr/op/ParamDerived.java
throw exc;

              
//in src/org/python/antlr/op/ParamDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/antlr/op/ParamDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/antlr/op/ParamDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/antlr/op/ParamDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/EqDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/antlr/op/EqDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/EqDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/EqDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/EqDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/EqDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/EqDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/EqDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/antlr/op/EqDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/EqDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/antlr/op/EqDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/antlr/op/EqDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/antlr/op/EqDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/antlr/op/EqDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/antlr/op/EqDerived.java
throw exc;

              
//in src/org/python/antlr/op/EqDerived.java
throw exc;

              
//in src/org/python/antlr/op/EqDerived.java
throw exc;

              
//in src/org/python/antlr/op/EqDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/antlr/op/EqDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/antlr/op/EqDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/antlr/op/EqDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/GtDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/antlr/op/GtDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/GtDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/GtDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/GtDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/GtDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/GtDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/GtDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/antlr/op/GtDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/GtDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/antlr/op/GtDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/antlr/op/GtDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/antlr/op/GtDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/antlr/op/GtDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/antlr/op/GtDerived.java
throw exc;

              
//in src/org/python/antlr/op/GtDerived.java
throw exc;

              
//in src/org/python/antlr/op/GtDerived.java
throw exc;

              
//in src/org/python/antlr/op/GtDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/antlr/op/GtDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/antlr/op/GtDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/antlr/op/GtDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/IsDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/antlr/op/IsDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/IsDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/IsDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/IsDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/IsDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/IsDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/IsDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/antlr/op/IsDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/IsDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/antlr/op/IsDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/antlr/op/IsDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/antlr/op/IsDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/antlr/op/IsDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/antlr/op/IsDerived.java
throw exc;

              
//in src/org/python/antlr/op/IsDerived.java
throw exc;

              
//in src/org/python/antlr/op/IsDerived.java
throw exc;

              
//in src/org/python/antlr/op/IsDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/antlr/op/IsDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/antlr/op/IsDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/antlr/op/IsDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/GtEDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/antlr/op/GtEDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/GtEDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/GtEDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/GtEDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/GtEDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/GtEDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/GtEDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/antlr/op/GtEDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/GtEDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/antlr/op/GtEDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/antlr/op/GtEDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/antlr/op/GtEDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/antlr/op/GtEDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/antlr/op/GtEDerived.java
throw exc;

              
//in src/org/python/antlr/op/GtEDerived.java
throw exc;

              
//in src/org/python/antlr/op/GtEDerived.java
throw exc;

              
//in src/org/python/antlr/op/GtEDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/antlr/op/GtEDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/antlr/op/GtEDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/antlr/op/GtEDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/StoreDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/antlr/op/StoreDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/StoreDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/StoreDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/StoreDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/StoreDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/StoreDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/StoreDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/antlr/op/StoreDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/StoreDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/antlr/op/StoreDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/antlr/op/StoreDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/antlr/op/StoreDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/antlr/op/StoreDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/antlr/op/StoreDerived.java
throw exc;

              
//in src/org/python/antlr/op/StoreDerived.java
throw exc;

              
//in src/org/python/antlr/op/StoreDerived.java
throw exc;

              
//in src/org/python/antlr/op/StoreDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/antlr/op/StoreDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/antlr/op/StoreDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/antlr/op/StoreDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/BitOrDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/antlr/op/BitOrDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/BitOrDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/BitOrDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/BitOrDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/BitOrDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/BitOrDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/BitOrDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/antlr/op/BitOrDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/BitOrDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/antlr/op/BitOrDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/antlr/op/BitOrDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/antlr/op/BitOrDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/antlr/op/BitOrDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/antlr/op/BitOrDerived.java
throw exc;

              
//in src/org/python/antlr/op/BitOrDerived.java
throw exc;

              
//in src/org/python/antlr/op/BitOrDerived.java
throw exc;

              
//in src/org/python/antlr/op/BitOrDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/antlr/op/BitOrDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/antlr/op/BitOrDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/antlr/op/BitOrDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/RShiftDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/antlr/op/RShiftDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/RShiftDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/RShiftDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/RShiftDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/RShiftDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/RShiftDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/RShiftDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/antlr/op/RShiftDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/RShiftDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/antlr/op/RShiftDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/antlr/op/RShiftDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/antlr/op/RShiftDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/antlr/op/RShiftDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/antlr/op/RShiftDerived.java
throw exc;

              
//in src/org/python/antlr/op/RShiftDerived.java
throw exc;

              
//in src/org/python/antlr/op/RShiftDerived.java
throw exc;

              
//in src/org/python/antlr/op/RShiftDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/antlr/op/RShiftDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/antlr/op/RShiftDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/antlr/op/RShiftDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/BitAndDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/antlr/op/BitAndDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/BitAndDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/BitAndDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/BitAndDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/BitAndDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/BitAndDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/BitAndDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/antlr/op/BitAndDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/BitAndDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/antlr/op/BitAndDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/antlr/op/BitAndDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/antlr/op/BitAndDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/antlr/op/BitAndDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/antlr/op/BitAndDerived.java
throw exc;

              
//in src/org/python/antlr/op/BitAndDerived.java
throw exc;

              
//in src/org/python/antlr/op/BitAndDerived.java
throw exc;

              
//in src/org/python/antlr/op/BitAndDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/antlr/op/BitAndDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/antlr/op/BitAndDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/antlr/op/BitAndDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/NotInDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/antlr/op/NotInDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/NotInDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/NotInDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/NotInDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/NotInDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/NotInDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/NotInDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/antlr/op/NotInDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/NotInDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/antlr/op/NotInDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/antlr/op/NotInDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/antlr/op/NotInDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/antlr/op/NotInDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/antlr/op/NotInDerived.java
throw exc;

              
//in src/org/python/antlr/op/NotInDerived.java
throw exc;

              
//in src/org/python/antlr/op/NotInDerived.java
throw exc;

              
//in src/org/python/antlr/op/NotInDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/antlr/op/NotInDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/antlr/op/NotInDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/antlr/op/NotInDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/LtDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/antlr/op/LtDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/LtDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/LtDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/LtDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/LtDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/LtDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/LtDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/antlr/op/LtDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/LtDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/antlr/op/LtDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/antlr/op/LtDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/antlr/op/LtDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/antlr/op/LtDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/antlr/op/LtDerived.java
throw exc;

              
//in src/org/python/antlr/op/LtDerived.java
throw exc;

              
//in src/org/python/antlr/op/LtDerived.java
throw exc;

              
//in src/org/python/antlr/op/LtDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/antlr/op/LtDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/antlr/op/LtDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/antlr/op/LtDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/FloorDivDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/antlr/op/FloorDivDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/FloorDivDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/FloorDivDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/FloorDivDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/FloorDivDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/FloorDivDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/FloorDivDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/antlr/op/FloorDivDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/FloorDivDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/antlr/op/FloorDivDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/antlr/op/FloorDivDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/antlr/op/FloorDivDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/antlr/op/FloorDivDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/antlr/op/FloorDivDerived.java
throw exc;

              
//in src/org/python/antlr/op/FloorDivDerived.java
throw exc;

              
//in src/org/python/antlr/op/FloorDivDerived.java
throw exc;

              
//in src/org/python/antlr/op/FloorDivDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/antlr/op/FloorDivDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/antlr/op/FloorDivDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/antlr/op/FloorDivDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/USubDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/antlr/op/USubDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/USubDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/USubDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/USubDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/USubDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/USubDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/USubDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/antlr/op/USubDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/USubDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/antlr/op/USubDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/antlr/op/USubDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/antlr/op/USubDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/antlr/op/USubDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/antlr/op/USubDerived.java
throw exc;

              
//in src/org/python/antlr/op/USubDerived.java
throw exc;

              
//in src/org/python/antlr/op/USubDerived.java
throw exc;

              
//in src/org/python/antlr/op/USubDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/antlr/op/USubDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/antlr/op/USubDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/antlr/op/USubDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/InvertDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/antlr/op/InvertDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/InvertDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/InvertDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/InvertDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/InvertDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/InvertDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/InvertDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/antlr/op/InvertDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/InvertDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/antlr/op/InvertDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/antlr/op/InvertDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/antlr/op/InvertDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/antlr/op/InvertDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/antlr/op/InvertDerived.java
throw exc;

              
//in src/org/python/antlr/op/InvertDerived.java
throw exc;

              
//in src/org/python/antlr/op/InvertDerived.java
throw exc;

              
//in src/org/python/antlr/op/InvertDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/antlr/op/InvertDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/antlr/op/InvertDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/antlr/op/InvertDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/AugLoadDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/antlr/op/AugLoadDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/AugLoadDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/AugLoadDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/AugLoadDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/AugLoadDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/AugLoadDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/AugLoadDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/antlr/op/AugLoadDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/AugLoadDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/antlr/op/AugLoadDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/antlr/op/AugLoadDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/antlr/op/AugLoadDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/antlr/op/AugLoadDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/antlr/op/AugLoadDerived.java
throw exc;

              
//in src/org/python/antlr/op/AugLoadDerived.java
throw exc;

              
//in src/org/python/antlr/op/AugLoadDerived.java
throw exc;

              
//in src/org/python/antlr/op/AugLoadDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/antlr/op/AugLoadDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/antlr/op/AugLoadDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/antlr/op/AugLoadDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/AugStoreDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/antlr/op/AugStoreDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/AugStoreDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/AugStoreDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/AugStoreDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/AugStoreDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/AugStoreDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/AugStoreDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/antlr/op/AugStoreDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/AugStoreDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/antlr/op/AugStoreDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/antlr/op/AugStoreDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/antlr/op/AugStoreDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/antlr/op/AugStoreDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/antlr/op/AugStoreDerived.java
throw exc;

              
//in src/org/python/antlr/op/AugStoreDerived.java
throw exc;

              
//in src/org/python/antlr/op/AugStoreDerived.java
throw exc;

              
//in src/org/python/antlr/op/AugStoreDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/antlr/op/AugStoreDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/antlr/op/AugStoreDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/antlr/op/AugStoreDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/LoadDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/antlr/op/LoadDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/LoadDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/LoadDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/LoadDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/LoadDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/LoadDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/LoadDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/antlr/op/LoadDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/LoadDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/antlr/op/LoadDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/antlr/op/LoadDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/antlr/op/LoadDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/antlr/op/LoadDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/antlr/op/LoadDerived.java
throw exc;

              
//in src/org/python/antlr/op/LoadDerived.java
throw exc;

              
//in src/org/python/antlr/op/LoadDerived.java
throw exc;

              
//in src/org/python/antlr/op/LoadDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/antlr/op/LoadDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/antlr/op/LoadDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/antlr/op/LoadDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/IsNotDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/antlr/op/IsNotDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/IsNotDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/IsNotDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/IsNotDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/IsNotDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/IsNotDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/IsNotDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/antlr/op/IsNotDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/IsNotDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/antlr/op/IsNotDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/antlr/op/IsNotDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/antlr/op/IsNotDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/antlr/op/IsNotDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/antlr/op/IsNotDerived.java
throw exc;

              
//in src/org/python/antlr/op/IsNotDerived.java
throw exc;

              
//in src/org/python/antlr/op/IsNotDerived.java
throw exc;

              
//in src/org/python/antlr/op/IsNotDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/antlr/op/IsNotDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/antlr/op/IsNotDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/antlr/op/IsNotDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/BitXorDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/antlr/op/BitXorDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/BitXorDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/BitXorDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/BitXorDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/BitXorDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/BitXorDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/BitXorDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/antlr/op/BitXorDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/BitXorDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/antlr/op/BitXorDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/antlr/op/BitXorDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/antlr/op/BitXorDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/antlr/op/BitXorDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/antlr/op/BitXorDerived.java
throw exc;

              
//in src/org/python/antlr/op/BitXorDerived.java
throw exc;

              
//in src/org/python/antlr/op/BitXorDerived.java
throw exc;

              
//in src/org/python/antlr/op/BitXorDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/antlr/op/BitXorDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/antlr/op/BitXorDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/antlr/op/BitXorDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/NotEqDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/antlr/op/NotEqDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/NotEqDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/NotEqDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/NotEqDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/NotEqDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/NotEqDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/NotEqDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/antlr/op/NotEqDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/NotEqDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/antlr/op/NotEqDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/antlr/op/NotEqDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/antlr/op/NotEqDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/antlr/op/NotEqDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/antlr/op/NotEqDerived.java
throw exc;

              
//in src/org/python/antlr/op/NotEqDerived.java
throw exc;

              
//in src/org/python/antlr/op/NotEqDerived.java
throw exc;

              
//in src/org/python/antlr/op/NotEqDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/antlr/op/NotEqDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/antlr/op/NotEqDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/antlr/op/NotEqDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/NotDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/antlr/op/NotDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/NotDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/NotDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/NotDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/NotDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/NotDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/NotDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/antlr/op/NotDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/NotDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/antlr/op/NotDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/antlr/op/NotDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/antlr/op/NotDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/antlr/op/NotDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/antlr/op/NotDerived.java
throw exc;

              
//in src/org/python/antlr/op/NotDerived.java
throw exc;

              
//in src/org/python/antlr/op/NotDerived.java
throw exc;

              
//in src/org/python/antlr/op/NotDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/antlr/op/NotDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/antlr/op/NotDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/antlr/op/NotDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/AndDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/antlr/op/AndDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/AndDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/AndDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/AndDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/AndDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/AndDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/AndDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/antlr/op/AndDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/AndDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/antlr/op/AndDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/antlr/op/AndDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/antlr/op/AndDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/antlr/op/AndDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/antlr/op/AndDerived.java
throw exc;

              
//in src/org/python/antlr/op/AndDerived.java
throw exc;

              
//in src/org/python/antlr/op/AndDerived.java
throw exc;

              
//in src/org/python/antlr/op/AndDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/antlr/op/AndDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/antlr/op/AndDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/antlr/op/AndDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/ModDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/antlr/op/ModDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/ModDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/ModDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/ModDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/ModDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/ModDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/ModDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/antlr/op/ModDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/ModDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/antlr/op/ModDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/antlr/op/ModDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/antlr/op/ModDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/antlr/op/ModDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/antlr/op/ModDerived.java
throw exc;

              
//in src/org/python/antlr/op/ModDerived.java
throw exc;

              
//in src/org/python/antlr/op/ModDerived.java
throw exc;

              
//in src/org/python/antlr/op/ModDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/antlr/op/ModDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/antlr/op/ModDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/antlr/op/ModDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/AddDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/antlr/op/AddDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/AddDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/AddDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/AddDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/AddDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/AddDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/AddDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/antlr/op/AddDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/AddDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/antlr/op/AddDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/antlr/op/AddDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/antlr/op/AddDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/antlr/op/AddDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/antlr/op/AddDerived.java
throw exc;

              
//in src/org/python/antlr/op/AddDerived.java
throw exc;

              
//in src/org/python/antlr/op/AddDerived.java
throw exc;

              
//in src/org/python/antlr/op/AddDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/antlr/op/AddDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/antlr/op/AddDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/antlr/op/AddDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/DelDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/antlr/op/DelDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/DelDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/DelDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/DelDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/DelDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/DelDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/DelDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/antlr/op/DelDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/DelDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/antlr/op/DelDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/antlr/op/DelDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/antlr/op/DelDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/antlr/op/DelDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/antlr/op/DelDerived.java
throw exc;

              
//in src/org/python/antlr/op/DelDerived.java
throw exc;

              
//in src/org/python/antlr/op/DelDerived.java
throw exc;

              
//in src/org/python/antlr/op/DelDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/antlr/op/DelDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/antlr/op/DelDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/antlr/op/DelDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/DivDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/antlr/op/DivDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/DivDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/DivDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/DivDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/DivDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/DivDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/DivDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/antlr/op/DivDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/DivDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/antlr/op/DivDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/antlr/op/DivDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/antlr/op/DivDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/antlr/op/DivDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/antlr/op/DivDerived.java
throw exc;

              
//in src/org/python/antlr/op/DivDerived.java
throw exc;

              
//in src/org/python/antlr/op/DivDerived.java
throw exc;

              
//in src/org/python/antlr/op/DivDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/antlr/op/DivDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/antlr/op/DivDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/antlr/op/DivDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/LShiftDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/antlr/op/LShiftDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/LShiftDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/LShiftDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/LShiftDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/LShiftDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/LShiftDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/LShiftDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/antlr/op/LShiftDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/LShiftDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/antlr/op/LShiftDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/antlr/op/LShiftDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/antlr/op/LShiftDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/antlr/op/LShiftDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/antlr/op/LShiftDerived.java
throw exc;

              
//in src/org/python/antlr/op/LShiftDerived.java
throw exc;

              
//in src/org/python/antlr/op/LShiftDerived.java
throw exc;

              
//in src/org/python/antlr/op/LShiftDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/antlr/op/LShiftDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/antlr/op/LShiftDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/antlr/op/LShiftDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/InDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/antlr/op/InDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/InDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/InDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/InDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/InDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/InDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/InDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/antlr/op/InDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/InDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/antlr/op/InDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/antlr/op/InDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/antlr/op/InDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/antlr/op/InDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/antlr/op/InDerived.java
throw exc;

              
//in src/org/python/antlr/op/InDerived.java
throw exc;

              
//in src/org/python/antlr/op/InDerived.java
throw exc;

              
//in src/org/python/antlr/op/InDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/antlr/op/InDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/antlr/op/InDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/antlr/op/InDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/MultDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/antlr/op/MultDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/MultDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/MultDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/MultDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/MultDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/MultDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/MultDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/antlr/op/MultDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/MultDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/antlr/op/MultDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/antlr/op/MultDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/antlr/op/MultDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/antlr/op/MultDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/antlr/op/MultDerived.java
throw exc;

              
//in src/org/python/antlr/op/MultDerived.java
throw exc;

              
//in src/org/python/antlr/op/MultDerived.java
throw exc;

              
//in src/org/python/antlr/op/MultDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/antlr/op/MultDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/antlr/op/MultDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/antlr/op/MultDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/UAddDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/antlr/op/UAddDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/UAddDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/UAddDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/UAddDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/UAddDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/UAddDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/UAddDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/antlr/op/UAddDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/UAddDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/antlr/op/UAddDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/antlr/op/UAddDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/antlr/op/UAddDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/antlr/op/UAddDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/antlr/op/UAddDerived.java
throw exc;

              
//in src/org/python/antlr/op/UAddDerived.java
throw exc;

              
//in src/org/python/antlr/op/UAddDerived.java
throw exc;

              
//in src/org/python/antlr/op/UAddDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/antlr/op/UAddDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/antlr/op/UAddDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/antlr/op/UAddDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/OrDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/antlr/op/OrDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/OrDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/OrDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/OrDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/OrDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/OrDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/OrDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/antlr/op/OrDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/OrDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/antlr/op/OrDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/antlr/op/OrDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/antlr/op/OrDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/antlr/op/OrDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/antlr/op/OrDerived.java
throw exc;

              
//in src/org/python/antlr/op/OrDerived.java
throw exc;

              
//in src/org/python/antlr/op/OrDerived.java
throw exc;

              
//in src/org/python/antlr/op/OrDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/antlr/op/OrDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/antlr/op/OrDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/antlr/op/OrDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/SubDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/antlr/op/SubDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/SubDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/SubDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/SubDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/SubDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/SubDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/SubDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/antlr/op/SubDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/op/SubDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/antlr/op/SubDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/antlr/op/SubDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/antlr/op/SubDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/antlr/op/SubDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/antlr/op/SubDerived.java
throw exc;

              
//in src/org/python/antlr/op/SubDerived.java
throw exc;

              
//in src/org/python/antlr/op/SubDerived.java
throw exc;

              
//in src/org/python/antlr/op/SubDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/antlr/op/SubDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/antlr/op/SubDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/antlr/op/SubDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/antlr/PythonTokenSource.java
throw p;

              
//in src/org/python/jsr223/PyScriptEngineScope.java
throw Py.KeyError(key);

              
//in src/org/python/jsr223/PyScriptEngine.java
throw scriptException(pye);

              
//in src/org/python/jsr223/PyScriptEngine.java
throw scriptException(pye);

              
//in src/org/python/jsr223/PyScriptEngine.java
throw scriptException(pye);

              
//in src/org/python/jsr223/PyScriptEngine.java
throw scriptException(pye);

              
//in src/org/python/jsr223/PyScriptEngine.java
throw scriptException(pye);

              
//in src/org/python/jsr223/PyScriptEngine.java
throw scriptException(pye);

              
//in src/org/python/modules/zipimport/zipimporterDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/modules/zipimport/zipimporterDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/modules/zipimport/zipimporterDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/modules/zipimport/zipimporterDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/modules/zipimport/zipimporterDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/modules/zipimport/zipimporterDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/modules/zipimport/zipimporterDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/modules/zipimport/zipimporterDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/modules/zipimport/zipimporterDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/modules/zipimport/zipimporterDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/modules/zipimport/zipimporterDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/modules/zipimport/zipimporterDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/modules/zipimport/zipimporterDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/modules/zipimport/zipimporterDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/modules/zipimport/zipimporterDerived.java
throw exc;

              
//in src/org/python/modules/zipimport/zipimporterDerived.java
throw exc;

              
//in src/org/python/modules/zipimport/zipimporterDerived.java
throw exc;

              
//in src/org/python/modules/zipimport/zipimporterDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/modules/zipimport/zipimporterDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/modules/zipimport/zipimporterDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/modules/zipimport/zipimporterDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/modules/zipimport/zipimporter.java
throw zipimport.ZipImportError("archive path is empty");

              
//in src/org/python/modules/zipimport/zipimporter.java
throw zipimport.ZipImportError("not a Zip file: " + path);

              
//in src/org/python/modules/zipimport/zipimporter.java
throw Py.IOError(path);

              
//in src/org/python/modules/zipimport/zipimporter.java
throw Py.IOError(ioe);

              
//in src/org/python/modules/zipimport/zipimporter.java
throw zipimport.ZipImportError(String.format("can't find module '%s'", fullname));

              
//in src/org/python/modules/zipimport/zipimporter.java
throw zipimport.ZipImportError(String.format("can't find module '%s'", fullname));

              
//in src/org/python/modules/zipimport/zipimporter.java
throw zipimport.ZipImportError("zipimport: can not open file: " + archive);

              
//in src/org/python/modules/zipimport/zipimporter.java
throw zipimport.ZipImportError("zipimport: can not open file: " + archive);

              
//in src/org/python/modules/zipimport/zipimporter.java
throw pye;

              
//in src/org/python/modules/zipimport/zipimporter.java
throw zipimport.ZipImportError(String.format("can't open Zip file: '%s'", archive));

              
//in src/org/python/modules/zipimport/zipimporter.java
throw zipimport.ZipImportError(String.format("can't read Zip file: '%s'", archive));

              
//in src/org/python/modules/zipimport/zipimporter.java
throw Py.IOError(ioe);

              
//in src/org/python/modules/zipimport/zipimporter.java
throw Py.IOError(ioe);

              
//in src/org/python/modules/_py_compile.java
throw Py.IOError(Errno.ENOENT, filename);

              
//in src/org/python/modules/struct.java
throw StructError("insufficient arguments to pack");

              
//in src/org/python/modules/struct.java
throw StructError("required argument is not an integer");

              
//in src/org/python/modules/struct.java
throw StructError("long int too long to convert");

              
//in src/org/python/modules/struct.java
throw StructError("unsigned long int too long to convert");

              
//in src/org/python/modules/struct.java
throw StructError("argument for 's' must be a string");

              
//in src/org/python/modules/struct.java
throw StructError("argument for 'p' must be a string");

              
//in src/org/python/modules/struct.java
throw StructError("char format require string of length 1");

              
//in src/org/python/modules/struct.java
throw StructError("can't convert negative long to unsigned");

              
//in src/org/python/modules/struct.java
throw StructError("can't convert negative long to unsigned");

              
//in src/org/python/modules/struct.java
throw Py.ValueError("can't unpack IEEE 754 special value on non-IEEE platform");

              
//in src/org/python/modules/struct.java
throw Py.ValueError("can't unpack IEEE 754 special value on non-IEEE platform");

              
//in src/org/python/modules/struct.java
throw Py.ValueError("can't unpack IEEE 754 special value on non-IEEE platform");

              
//in src/org/python/modules/struct.java
throw Py.ValueError("can't unpack IEEE 754 special value on non-IEEE platform");

              
//in src/org/python/modules/struct.java
throw StructError("bad char in struct format");

              
//in src/org/python/modules/struct.java
throw StructError("overflow in item count");

              
//in src/org/python/modules/struct.java
throw StructError("total struct size too long");

              
//in src/org/python/modules/struct.java
throw Py.TypeError("pack_into takes an array arg");

              
//in src/org/python/modules/struct.java
throw StructError("pack_into requires a buffer of at least " + res.pos + " bytes, got " + buffer.__len__());

              
//in src/org/python/modules/struct.java
throw StructError("too many arguments for pack format");

              
//in src/org/python/modules/struct.java
throw StructError("unpack str size does not match format");

              
//in src/org/python/modules/struct.java
throw StructError("unpack str size does not match format");

              
//in src/org/python/modules/struct.java
throw StructError("unpack_from str size does not match format");

              
//in src/org/python/modules/PyStruct.java
throw Py.TypeError("'" + keyword + "' is an invalid keyword argument for this function");

              
//in src/org/python/modules/PyStruct.java
throw Py.TypeError("Struct() takes exactly 1 argument (" + nargs + " given)");

              
//in src/org/python/modules/PyStruct.java
throw Py.TypeError("unpack of a str or array");

              
//in src/org/python/modules/PyStruct.java
throw struct.StructError("unpack str size does not match format");

              
//in src/org/python/modules/PyStruct.java
throw struct.StructError("unpack_from str size does not match format");

              
//in src/org/python/modules/sre/PatternObject.java
throw Py.RuntimeError("maximum recursion limit exceeded");

              
//in src/org/python/modules/sre/PatternObject.java
throw Py.RuntimeError("internal error in regular expression engine");

              
//in src/org/python/modules/sre/PatternObject.java
throw Py.TypeError("expected str or unicode but got " + obj.getType());

              
//in src/org/python/modules/sre/MatchObject.java
throw Py.TypeError("expand() takes exactly 1 argument (0 given)");

              
//in src/org/python/modules/sre/MatchObject.java
throw Py.IndexError("no such group");

              
//in src/org/python/modules/sre/MatchObject.java
throw Py.IndexError("no such group");

              
//in src/org/python/modules/sre/MatchObject.java
throw Py.IndexError("no such group");

              
//in src/org/python/modules/sre/MatchObject.java
throw Py.IndexError("no such group");

              
//in src/org/python/modules/binascii.java
throw Py.TypeError("Odd-length string");

              
//in src/org/python/modules/binascii.java
throw Py.TypeError("Non-hexadecimal digit found");

              
//in src/org/python/modules/binascii.java
throw Py.TypeError(errMsg);

              
//in src/org/python/modules/binascii.java
throw e;

              
//in src/org/python/modules/gc.java
throw Py.NotImplementedError("can't disable Java GC");

              
//in src/org/python/modules/gc.java
throw Py.NotImplementedError("not applicable to Java GC");

              
//in src/org/python/modules/gc.java
throw Py.NotImplementedError("not applicable to Java GC");

              
//in src/org/python/modules/gc.java
throw Py.NotImplementedError("not applicable to Java GC");

              
//in src/org/python/modules/gc.java
throw Py.NotImplementedError("not applicable to Java GC");

              
//in src/org/python/modules/gc.java
throw Py.NotImplementedError("not applicable to Java GC");

              
//in src/org/python/modules/gc.java
throw Py.NotImplementedError("not applicable to Java GC");

              
//in src/org/python/modules/gc.java
throw Py.NotImplementedError("not applicable to Java GC");

              
//in src/org/python/modules/math.java
throw Py.ValueError("math domain error");

              
//in src/org/python/modules/math.java
throw Py.OverflowError("math range error");

              
//in src/org/python/modules/math.java
throw Py.OverflowError("math range error");

              
//in src/org/python/modules/PyIOFileFactory.java
throw Py.ValueError("I/O operation on closed file");

              
//in src/org/python/modules/_weakref/AbstractReference.java
throw Py.ReferenceError("weakly-referenced object no longer exists");

              
//in src/org/python/modules/_weakref/GlobalRef.java
throw Py.TypeError("weak object has gone away");

              
//in src/org/python/modules/_weakref/ReferenceTypeDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/modules/_weakref/ReferenceTypeDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/modules/_weakref/ReferenceTypeDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/modules/_weakref/ReferenceTypeDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/modules/_weakref/ReferenceTypeDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/modules/_weakref/ReferenceTypeDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/modules/_weakref/ReferenceTypeDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/modules/_weakref/ReferenceTypeDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/modules/_weakref/ReferenceTypeDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/modules/_weakref/ReferenceTypeDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/modules/_weakref/ReferenceTypeDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/modules/_weakref/ReferenceTypeDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/modules/_weakref/ReferenceTypeDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/modules/_weakref/ReferenceTypeDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/modules/_weakref/ReferenceTypeDerived.java
throw exc;

              
//in src/org/python/modules/_weakref/ReferenceTypeDerived.java
throw exc;

              
//in src/org/python/modules/_weakref/ReferenceTypeDerived.java
throw exc;

              
//in src/org/python/modules/_weakref/ReferenceTypeDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/modules/_weakref/ReferenceTypeDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/modules/_weakref/ReferenceTypeDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/modules/_weakref/ReferenceTypeDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/modules/posix/PyStatResult.java
throw Py.TypeError(msg);

              
//in src/org/python/modules/posix/PyStatResult.java
throw Py.TypeError(msg);

              
//in src/org/python/modules/posix/PosixModule.java
throw pye;

              
//in src/org/python/modules/posix/PosixModule.java
throw Py.TypeError(String.format("coercing to Unicode: need string, '%s' type found",
                                             pathObj.getType().fastGetName()));

              
//in src/org/python/modules/posix/PosixModule.java
throw Py.OSError(Errno.ENOTDIR, path);

              
//in src/org/python/modules/posix/PosixModule.java
throw errorFromErrno(path);

              
//in src/org/python/modules/posix/PosixModule.java
throw errorFromErrno(path);

              
//in src/org/python/modules/posix/PosixModule.java
throw badFD();

              
//in src/org/python/modules/posix/PosixModule.java
throw Py.ValueError(String.format("invalid file mode '%s'", mode));

              
//in src/org/python/modules/posix/PosixModule.java
throw badFD();

              
//in src/org/python/modules/posix/PosixModule.java
throw pye;

              
//in src/org/python/modules/posix/PosixModule.java
throw Py.OSError(Errno.EINVAL);

              
//in src/org/python/modules/posix/PosixModule.java
throw Py.OSError(Errno.EINVAL);

              
//in src/org/python/modules/posix/PosixModule.java
throw Py.ValueError("I/O operation on closed file");

              
//in src/org/python/modules/posix/PosixModule.java
throw Py.OSError(ioe);

              
//in src/org/python/modules/posix/PosixModule.java
throw Py.IOError(Errno.EBADF);

              
//in src/org/python/modules/posix/PosixModule.java
throw Py.NotImplementedError("Integer file descriptor compatibility only "
                                             + "available for stdin, stdout and stderr (0-2)");

              
//in src/org/python/modules/posix/PosixModule.java
throw Py.TypeError("a file descriptor is required");

              
//in src/org/python/modules/posix/PosixModule.java
throw errorFromErrno();

              
//in src/org/python/modules/posix/PosixModule.java
throw errorFromErrno(path);

              
//in src/org/python/modules/posix/PosixModule.java
throw errorFromErrno(path);

              
//in src/org/python/modules/posix/PosixModule.java
throw Py.OSError(Errno.ENOTDIR, path);

              
//in src/org/python/modules/posix/PosixModule.java
throw Py.OSError(Errno.EACCES, path);

              
//in src/org/python/modules/posix/PosixModule.java
throw Py.OSError("listdir(): an unknown error occured: " + path);

              
//in src/org/python/modules/posix/PosixModule.java
throw badFD();

              
//in src/org/python/modules/posix/PosixModule.java
throw errorFromErrno(path);

              
//in src/org/python/modules/posix/PosixModule.java
throw Py.OSError(Errno.EINVAL, path);

              
//in src/org/python/modules/posix/PosixModule.java
throw Py.OSError(Errno.ENOENT, path);

              
//in src/org/python/modules/posix/PosixModule.java
throw Py.OSError(Errno.EEXIST, path);

              
//in src/org/python/modules/posix/PosixModule.java
throw Py.OSError(ioe);

              
//in src/org/python/modules/posix/PosixModule.java
throw Py.OSError(file.isDirectory() ? Errno.EISDIR : Errno.ENOENT, path);

              
//in src/org/python/modules/posix/PosixModule.java
throw badFD();

              
//in src/org/python/modules/posix/PosixModule.java
throw Py.OSError(ioe);

              
//in src/org/python/modules/posix/PosixModule.java
throw Py.OSError(Errno.ENOENT, path);

              
//in src/org/python/modules/posix/PosixModule.java
throw Py.OSError(Errno.ENOTDIR, path);

              
//in src/org/python/modules/posix/PosixModule.java
throw errorFromErrno();

              
//in src/org/python/modules/posix/PosixModule.java
throw errorFromErrno();

              
//in src/org/python/modules/posix/PosixModule.java
throw Py.OSError(Errno.EISDIR, path);

              
//in src/org/python/modules/posix/PosixModule.java
throw Py.OSError(Errno.EPERM, path);

              
//in src/org/python/modules/posix/PosixModule.java
throw Py.OSError("unlink(): an unknown error occured: " + path);

              
//in src/org/python/modules/posix/PosixModule.java
throw Py.TypeError("utime() arg 2 must be a tuple (atime, mtime)");

              
//in src/org/python/modules/posix/PosixModule.java
throw errorFromErrno();

              
//in src/org/python/modules/posix/PosixModule.java
throw errorFromErrno();

              
//in src/org/python/modules/posix/PosixModule.java
throw badFD();

              
//in src/org/python/modules/posix/PosixModule.java
throw pye;

              
//in src/org/python/modules/posix/PosixModule.java
throw Py.TypeError(String.format("coercing to Unicode: need string, %s type found",
                                             path.getType().fastGetName()));

              
//in src/org/python/modules/posix/PosixModule.java
throw Py.TypeError("coercing to Unicode: need string or buffer, NoneType found");

              
//in src/org/python/modules/posix/PosixModule.java
throw Py.TypeError(String.format("coercing to Unicode: need string or buffer, %s " +
                                                 "found", pathObj.getType().fastGetName()));

              
//in src/org/python/modules/posix/PosixModule.java
throw Py.TypeError(String.format("coercing to Unicode: need string or buffer, %s " +
                                                 "found", pathObj.getType().fastGetName()));

              
//in src/org/python/modules/posix/PythonPOSIXHandler.java
throw Py.OSError(error, extraData);

              
//in src/org/python/modules/posix/PythonPOSIXHandler.java
throw Py.NotImplementedError(methodName);

              
//in src/org/python/modules/cmath.java
throw Py.TypeError("__complex__ should return a complex object");

              
//in src/org/python/modules/thread/PyLocalDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/modules/thread/PyLocalDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/modules/thread/PyLocalDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/modules/thread/PyLocalDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/modules/thread/PyLocalDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/modules/thread/PyLocalDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/modules/thread/PyLocalDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/modules/thread/PyLocalDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/modules/thread/PyLocalDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/modules/thread/PyLocalDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/modules/thread/PyLocalDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/modules/thread/PyLocalDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/modules/thread/PyLocalDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/modules/thread/PyLocalDerived.java
throw exc;

              
//in src/org/python/modules/thread/PyLocalDerived.java
throw exc;

              
//in src/org/python/modules/thread/PyLocalDerived.java
throw exc;

              
//in src/org/python/modules/thread/PyLocalDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/modules/thread/PyLocalDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/modules/thread/PyLocalDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/modules/thread/PyLocalDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/modules/thread/thread.java
throw Py.ValueError("size not valid: " + proposed_stack_size + " bytes");

              
//in src/org/python/modules/thread/thread.java
throw Py.TypeError("stack_size() takes at most 1 argument (" + args.length + "given)");

              
//in src/org/python/modules/thread/PyLocal.java
throw Py.TypeError("Initialization arguments are not supported");

              
//in src/org/python/modules/thread/PyLock.java
throw Py.ValueError("lock not acquired");

              
//in src/org/python/modules/_marshal.java
throw Py.ValueError("Maximum marshal stack depth");

              
//in src/org/python/modules/_marshal.java
throw Py.TypeError("NULL object in marshal data");

              
//in src/org/python/modules/_marshal.java
throw Py.EOFError("EOF read where object expected");

              
//in src/org/python/modules/_marshal.java
throw Py.ValueError("bad marshal data");

              
//in src/org/python/modules/_marshal.java
throw Py.ValueError("Maximum marshal stack depth");

              
//in src/org/python/modules/_marshal.java
throw Py.ValueError("bad marshal data");

              
//in src/org/python/modules/_marshal.java
throw Py.ValueError("bad marshal data");

              
//in src/org/python/modules/_marshal.java
throw Py.ValueError("bad marshal data");

              
//in src/org/python/modules/cPickle.java
throw Py.TypeError("dict items iterator must return 2-tuples");

              
//in src/org/python/modules/cPickle.java
throw Py.ValueError("can't make hashtable of size: " +
                                    capacity);

              
//in src/org/python/modules/cPickle.java
throw Py.ValueError("unsupported pickle protocol: " + proto);

              
//in src/org/python/modules/cPickle.java
throw Py.ValueError("could not convert string to int");

              
//in src/org/python/modules/cPickle.java
throw Py.ValueError("insecure string pickle");

              
//in src/org/python/modules/cPickle.java
throw Py.ValueError("insecure string pickle");

              
//in src/org/python/modules/cPickle.java
throw Py.ValueError("insecure string pickle " + i);

              
//in src/org/python/modules/_csv/PyDialect.java
throw Py.TypeError("bad \"quoting\" value");

              
//in src/org/python/modules/_csv/PyDialect.java
throw Py.TypeError("delimiter must be set");

              
//in src/org/python/modules/_csv/PyDialect.java
throw Py.TypeError("quotechar must be set if quoting enabled");

              
//in src/org/python/modules/_csv/PyDialect.java
throw Py.TypeError("lineterminator must be set");

              
//in src/org/python/modules/_csv/PyDialect.java
throw Py.TypeError(String.format("\"%s\" must be an 1-character string", name));

              
//in src/org/python/modules/_csv/PyDialect.java
throw Py.TypeError(String.format("\"%s\" must be an integer", name));

              
//in src/org/python/modules/_csv/PyDialect.java
throw Py.TypeError(String.format("\"%s\" must be an string", name));

              
//in src/org/python/modules/_csv/PyDialect.java
throw Py.AttributeError(String.format("attribute '%s' of '%s' objects is not writable",
                                              "quoting", getType().fastGetName()));

              
//in src/org/python/modules/_csv/PyDialect.java
throw Py.AttributeError(String.format("attribute '%s' of '%s' objects is not writable",
                                              "quoting", getType().fastGetName()));

              
//in src/org/python/modules/_csv/PyWriter.java
throw _csv.Error("writerows() argument must be iterable");

              
//in src/org/python/modules/_csv/PyWriter.java
throw _csv.Error("sequence expected");

              
//in src/org/python/modules/_csv/PyWriter.java
throw _csv.Error("need to escape, but no escapechar set");

              
//in src/org/python/modules/_csv/PyWriter.java
throw _csv.Error("single empty field record must be quoted");

              
//in src/org/python/modules/_csv/_csv.java
throw Py.TypeError("register_dialect() expected at most 2 arguments, got " + argc);

              
//in src/org/python/modules/_csv/_csv.java
throw Py.TypeError("dialect name must be a string or unicode");

              
//in src/org/python/modules/_csv/_csv.java
throw Error("unknown dialect");

              
//in src/org/python/modules/_csv/_csv.java
throw Py.TypeError("argument 1 must have a \"write\" method");

              
//in src/org/python/modules/_csv/_csv.java
throw Py.TypeError("limit must be an integer");

              
//in src/org/python/modules/_csv/_csv.java
throw Error("unknown dialect");

              
//in src/org/python/modules/_csv/PyReader.java
throw _csv.Error("newline inside string");

              
//in src/org/python/modules/_csv/PyReader.java
throw _csv.Error("line contains NULL byte");

              
//in src/org/python/modules/_csv/PyReader.java
throw _csv.Error(String.format("'%c' expected after '%c'",
                                                   dialect.delimiter, dialect.quotechar));

              
//in src/org/python/modules/_csv/PyReader.java
throw _csv.Error(err);

              
//in src/org/python/modules/_csv/PyReader.java
throw _csv.Error(String.format("field larger than field limit (%d)",
                                           _csv.field_limit));

              
//in src/org/python/modules/_csv/PyDialectDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/modules/_csv/PyDialectDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/modules/_csv/PyDialectDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/modules/_csv/PyDialectDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/modules/_csv/PyDialectDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/modules/_csv/PyDialectDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/modules/_csv/PyDialectDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/modules/_csv/PyDialectDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/modules/_csv/PyDialectDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/modules/_csv/PyDialectDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/modules/_csv/PyDialectDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/modules/_csv/PyDialectDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/modules/_csv/PyDialectDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/modules/_csv/PyDialectDerived.java
throw exc;

              
//in src/org/python/modules/_csv/PyDialectDerived.java
throw exc;

              
//in src/org/python/modules/_csv/PyDialectDerived.java
throw exc;

              
//in src/org/python/modules/_csv/PyDialectDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/modules/_csv/PyDialectDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/modules/_csv/PyDialectDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/modules/_csv/PyDialectDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/modules/operator.java
throw info.unexpectedCall(1, false);

              
//in src/org/python/modules/operator.java
throw info.unexpectedCall(2, false);

              
//in src/org/python/modules/operator.java
throw info.unexpectedCall(3, false);

              
//in src/org/python/modules/operator.java
throw info.unexpectedCall(4, false);

              
//in src/org/python/modules/operator.java
throw Py.ValueError("sequence.index(x): x not in list");

              
//in src/org/python/modules/operator.java
throw Py.TypeError(String.format("attribute name must be string, not '%.200s'",
                                                 name.getType().fastGetName()));

              
//in src/org/python/modules/random/PyRandom.java
throw Py.TypeError(String.format("jumpahead requires an integer, not '%s'",
                                             arg0.getType().fastGetName()));

              
//in src/org/python/modules/random/PyRandom.java
throw Py.TypeError("state vector must be a tuple");

              
//in src/org/python/modules/random/PyRandom.java
throw Py.TypeError("state vector of unexpected type: "+
                            arr[i].getClass());

              
//in src/org/python/modules/random/PyRandom.java
throw Py.SystemError("state vector invalid: "+e.getMessage());

              
//in src/org/python/modules/random/PyRandom.java
throw Py.SystemError("state vector invalid: "+e.getMessage());

              
//in src/org/python/modules/random/PyRandom.java
throw Py.SystemError("creation of state vector failed: "+
                    e.getMessage());

              
//in src/org/python/modules/random/PyRandomDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/modules/random/PyRandomDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/modules/random/PyRandomDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/modules/random/PyRandomDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/modules/random/PyRandomDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/modules/random/PyRandomDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/modules/random/PyRandomDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/modules/random/PyRandomDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/modules/random/PyRandomDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/modules/random/PyRandomDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/modules/random/PyRandomDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/modules/random/PyRandomDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/modules/random/PyRandomDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/modules/random/PyRandomDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/modules/random/PyRandomDerived.java
throw exc;

              
//in src/org/python/modules/random/PyRandomDerived.java
throw exc;

              
//in src/org/python/modules/random/PyRandomDerived.java
throw exc;

              
//in src/org/python/modules/random/PyRandomDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/modules/random/PyRandomDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/modules/random/PyRandomDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/modules/random/PyRandomDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/modules/_collections/PyDefaultDict.java
throw Py.KeyError(key);

              
//in src/org/python/modules/_collections/PyDefaultDict.java
throw Py.TypeError("first argument must be callable");

              
//in src/org/python/modules/_collections/PyDefaultDict.java
throw Py.KeyError(key);

              
//in src/org/python/modules/_collections/PyDefaultDict.java
throw Py.KeyError(key);

              
//in src/org/python/modules/_collections/PyDequeDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/modules/_collections/PyDequeDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/modules/_collections/PyDequeDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/modules/_collections/PyDequeDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/modules/_collections/PyDequeDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/modules/_collections/PyDequeDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/modules/_collections/PyDequeDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/modules/_collections/PyDequeDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/modules/_collections/PyDequeDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/modules/_collections/PyDequeDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/modules/_collections/PyDequeDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/modules/_collections/PyDequeDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/modules/_collections/PyDequeDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/modules/_collections/PyDequeDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/modules/_collections/PyDequeDerived.java
throw exc;

              
//in src/org/python/modules/_collections/PyDequeDerived.java
throw exc;

              
//in src/org/python/modules/_collections/PyDequeDerived.java
throw exc;

              
//in src/org/python/modules/_collections/PyDequeDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/modules/_collections/PyDequeDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/modules/_collections/PyDequeDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/modules/_collections/PyDequeDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/modules/_collections/PyDefaultDictDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/modules/_collections/PyDefaultDictDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/modules/_collections/PyDefaultDictDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/modules/_collections/PyDefaultDictDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/modules/_collections/PyDefaultDictDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/modules/_collections/PyDefaultDictDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/modules/_collections/PyDefaultDictDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/modules/_collections/PyDefaultDictDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/modules/_collections/PyDefaultDictDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/modules/_collections/PyDefaultDictDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/modules/_collections/PyDefaultDictDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/modules/_collections/PyDefaultDictDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/modules/_collections/PyDefaultDictDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/modules/_collections/PyDefaultDictDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/modules/_collections/PyDefaultDictDerived.java
throw exc;

              
//in src/org/python/modules/_collections/PyDefaultDictDerived.java
throw exc;

              
//in src/org/python/modules/_collections/PyDefaultDictDerived.java
throw exc;

              
//in src/org/python/modules/_collections/PyDefaultDictDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/modules/_collections/PyDefaultDictDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/modules/_collections/PyDefaultDictDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/modules/_collections/PyDefaultDictDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/modules/_collections/PyDeque.java
throw Py.TypeError("deque() does not take keyword arguments");

              
//in src/org/python/modules/_collections/PyDeque.java
throw PyBuiltinCallable.DefaultInfo.unexpectedCall(nargs, false, "deque", 0, 1);

              
//in src/org/python/modules/_collections/PyDeque.java
throw Py.IndexError("pop from an empty deque");

              
//in src/org/python/modules/_collections/PyDeque.java
throw Py.IndexError("deque mutated during remove().");

              
//in src/org/python/modules/_collections/PyDeque.java
throw Py.ValueError("deque.remove(x): x not in deque");

              
//in src/org/python/modules/_collections/PyDeque.java
throw pe;

              
//in src/org/python/modules/_collections/PyDeque.java
throw Py.TypeError(String.format("sequence index must be integer, not '%.200s'",
                                             index.getType().fastGetName()));

              
//in src/org/python/modules/_collections/PyDeque.java
throw Py.IndexError("index out of range: " + index);

              
//in src/org/python/modules/_collections/PyDeque.java
throw Py.TypeError("deque objects are unhashable");

              
//in src/org/python/modules/_collections/PyDeque.java
throw Py.RuntimeError("deque changed size during iteration");

              
//in src/org/python/modules/jffi/Function.java
throw Py.TypeError("expected memory address");

              
//in src/org/python/modules/jffi/Function.java
throw Py.TypeError("wrong argument type (expected list or tuple)");

              
//in src/org/python/modules/jffi/Function.java
throw Py.NotImplementedError("variadic functions not supported yet;  specify a parameter list");

              
//in src/org/python/modules/jffi/InvalidMemory.java
throw ex();

              
//in src/org/python/modules/jffi/InvalidMemory.java
throw ex();

              
//in src/org/python/modules/jffi/InvalidMemory.java
throw ex();

              
//in src/org/python/modules/jffi/InvalidMemory.java
throw ex();

              
//in src/org/python/modules/jffi/InvalidMemory.java
throw ex();

              
//in src/org/python/modules/jffi/InvalidMemory.java
throw ex();

              
//in src/org/python/modules/jffi/InvalidMemory.java
throw ex();

              
//in src/org/python/modules/jffi/InvalidMemory.java
throw ex();

              
//in src/org/python/modules/jffi/InvalidMemory.java
throw ex();

              
//in src/org/python/modules/jffi/InvalidMemory.java
throw ex();

              
//in src/org/python/modules/jffi/InvalidMemory.java
throw ex();

              
//in src/org/python/modules/jffi/InvalidMemory.java
throw ex();

              
//in src/org/python/modules/jffi/InvalidMemory.java
throw ex();

              
//in src/org/python/modules/jffi/InvalidMemory.java
throw ex();

              
//in src/org/python/modules/jffi/InvalidMemory.java
throw ex();

              
//in src/org/python/modules/jffi/InvalidMemory.java
throw ex();

              
//in src/org/python/modules/jffi/InvalidMemory.java
throw ex();

              
//in src/org/python/modules/jffi/InvalidMemory.java
throw ex();

              
//in src/org/python/modules/jffi/InvalidMemory.java
throw ex();

              
//in src/org/python/modules/jffi/InvalidMemory.java
throw ex();

              
//in src/org/python/modules/jffi/InvalidMemory.java
throw ex();

              
//in src/org/python/modules/jffi/InvalidMemory.java
throw ex();

              
//in src/org/python/modules/jffi/InvalidMemory.java
throw ex();

              
//in src/org/python/modules/jffi/InvalidMemory.java
throw ex();

              
//in src/org/python/modules/jffi/InvalidMemory.java
throw ex();

              
//in src/org/python/modules/jffi/InvalidMemory.java
throw ex();

              
//in src/org/python/modules/jffi/InvalidMemory.java
throw ex();

              
//in src/org/python/modules/jffi/InvalidMemory.java
throw ex();

              
//in src/org/python/modules/jffi/InvalidMemory.java
throw ex();

              
//in src/org/python/modules/jffi/InvalidMemory.java
throw ex();

              
//in src/org/python/modules/jffi/InvalidMemory.java
throw ex();

              
//in src/org/python/modules/jffi/InvalidMemory.java
throw ex();

              
//in src/org/python/modules/jffi/InvalidMemory.java
throw ex();

              
//in src/org/python/modules/jffi/InvalidMemory.java
throw ex();

              
//in src/org/python/modules/jffi/InvalidMemory.java
throw ex();

              
//in src/org/python/modules/jffi/InvalidMemory.java
throw ex();

              
//in src/org/python/modules/jffi/InvalidMemory.java
throw ex();

              
//in src/org/python/modules/jffi/InvalidMemory.java
throw ex();

              
//in src/org/python/modules/jffi/InvalidMemory.java
throw ex();

              
//in src/org/python/modules/jffi/DynamicLibrary.java
throw Py.RuntimeError("Could not open " 
                    + libname != null ? libname : "[current process]"
                    + " " + Library.getLastError());

              
//in src/org/python/modules/jffi/DynamicLibrary.java
throw Py.NameError("Could not locate symbol '" + name.asString() + "' in " + this.name);

              
//in src/org/python/modules/jffi/DefaultInvokerFactory.java
throw Py.RuntimeError("Unsupported return type: " + returnType);

              
//in src/org/python/modules/jffi/DefaultInvokerFactory.java
throw Py.RuntimeError("Unsupported parameter type: " + type);

              
//in src/org/python/modules/jffi/DefaultInvokerFactory.java
throw Py.RuntimeError("Unsupported parameter type: " + type);

              
//in src/org/python/modules/jffi/DefaultInvokerFactory.java
throw Py.TypeError(String.format("expected %d args; got %d", arity, got));

              
//in src/org/python/modules/jffi/DefaultInvokerFactory.java
throw Py.TypeError("expected pointer argument");

              
//in src/org/python/modules/jffi/Util.java
throw Py.TypeError("invalid __long__() result");

              
//in src/org/python/modules/jffi/Util.java
throw Py.IndexError("Memory access offset="
                    + off + " size=" + len + " is out of bounds");

              
//in src/org/python/modules/jffi/Util.java
throw Py.TypeError("invalid address");

              
//in src/org/python/modules/jffi/CData.java
throw Py.TypeError("expected type");

              
//in src/org/python/modules/jffi/CData.java
throw Py.TypeError("invalid memory");

              
//in src/org/python/modules/jffi/CData.java
throw Py.TypeError("expected library, not " + lib.getType().fastGetName());

              
//in src/org/python/modules/jffi/MemoryOp.java
throw Py.TypeError("invalid memory access");

              
//in src/org/python/modules/jffi/MemoryOp.java
throw Py.TypeError("invalid memory access");

              
//in src/org/python/modules/jffi/MemoryOp.java
throw Py.TypeError("Attempting to write void to memory");

              
//in src/org/python/modules/jffi/MemoryOp.java
throw Py.TypeError("Attempting to read void from memory");

              
//in src/org/python/modules/jffi/MemoryOp.java
throw Py.RuntimeError("invalid pointer");

              
//in src/org/python/modules/jffi/MemoryOp.java
throw Py.NotImplementedError("Cannot set String");

              
//in src/org/python/modules/jffi/MemoryOp.java
throw Py.NotImplementedError("Cannot get String");

              
//in src/org/python/modules/jffi/MemoryOp.java
throw Py.TypeError("invalid _jffi_type for " + type.fastGetName() + "; should be instance of jffi.StructLayout");

              
//in src/org/python/modules/jffi/MemoryOp.java
throw Py.NotImplementedError("not implemented");

              
//in src/org/python/modules/jffi/PointerCData.java
throw Py.TypeError("expected " + pointerType.pyComponentType.getName() + " instead of " + value.getType().getName());

              
//in src/org/python/modules/jffi/PointerCData.java
throw Py.TypeError("invalid _jffi_type for " + subtype.getName());

              
//in src/org/python/modules/jffi/ArrayCData.java
throw Py.TypeError("invalid _jffi_type for " + subtype.getName());

              
//in src/org/python/modules/jffi/ArrayCData.java
throw Py.TypeError("Array does not support item deletion");

              
//in src/org/python/modules/jffi/ArrayCData.java
throw Py.TypeError("expected list or tuple");

              
//in src/org/python/modules/jffi/ArrayCData.java
throw Py.TypeError("Array does not support item deletion");

              
//in src/org/python/modules/jffi/ArrayCData.java
throw Py.TypeError("Array does not support item deletion");

              
//in src/org/python/modules/jffi/StructLayout.java
throw Py.TypeError("expected pointer");

              
//in src/org/python/modules/jffi/StructLayout.java
throw Py.TypeError("expected list of jffi.StructLayout.Field");

              
//in src/org/python/modules/jffi/StructLayout.java
throw Py.TypeError(String.format("element %d of field list is not an instance of jffi.StructLayout.Field", i));

              
//in src/org/python/modules/jffi/jffi.java
throw Py.TypeError("invalid memory address");

              
//in src/org/python/modules/jffi/AllocatedNativeMemory.java
throw Py.RuntimeError("failed to allocate " + size + " bytes");

              
//in src/org/python/modules/jffi/FastIntInvokerFactory.java
throw Py.RuntimeError("fast int invoker does not support functions with arity=" + parameterConverters.length);

              
//in src/org/python/modules/jffi/FastIntInvokerFactory.java
throw Py.TypeError("cannot convert objects of type " + type + " to int");

              
//in src/org/python/modules/jffi/FastIntInvokerFactory.java
throw Py.TypeError("cannot convert objects of type " + type + " to int");

              
//in src/org/python/modules/jffi/FastIntInvokerFactory.java
throw Py.TypeError(String.format("__call__() takes exactly %d arguments (%d given)", arity, got));

              
//in src/org/python/modules/jffi/FastIntInvokerFactory.java
throw Py.RuntimeError("invalid fast-int arity");

              
//in src/org/python/modules/jffi/Structure.java
throw Py.TypeError("invalid _jffi_type for " + subtype.fastGetName() + "; should be instance of jffi.StructLayout");

              
//in src/org/python/modules/jffi/Structure.java
throw Py.RuntimeError("reference memory already initialized");

              
//in src/org/python/modules/jffi/Structure.java
throw Py.NameError(String.format("struct %s has no field '%s'", getType().fastGetName(), key.toString()));

              
//in src/org/python/modules/jffi/CType.java
throw Py.TypeError("invalid _jffi_type");

              
//in src/org/python/modules/jffi/CType.java
throw Py.TypeError(String.format("__init__() takes exactly 2 arguments (%d given)", args.length));

              
//in src/org/python/modules/jffi/CType.java
throw Py.TypeError("invalid component type");

              
//in src/org/python/modules/jffi/CType.java
throw Py.TypeError("only scalar and struct types supported");

              
//in src/org/python/modules/jffi/CType.java
throw Py.TypeError("pointer only supported for scalar types");

              
//in src/org/python/modules/jffi/CType.java
throw Py.TypeError(String.format("__init__() takes exactly 1 argument (%d given)", args.length));

              
//in src/org/python/modules/jffi/CType.java
throw Py.TypeError("expected ctypes class");

              
//in src/org/python/modules/jffi/ScalarCData.java
throw Py.TypeError("invalid _jffi_type for " + subtype.getName());

              
//in src/org/python/modules/itertools.java
throw pyEx;

              
//in src/org/python/modules/itertools.java
throw Py.TypeError("imap requires at least two arguments");

              
//in src/org/python/modules/itertools.java
throw Py.ValueError(msg);

              
//in src/org/python/modules/itertools.java
throw pyEx;

              
//in src/org/python/modules/itertools.java
throw Py.ValueError("Indices for islice() must be non-negative integers");

              
//in src/org/python/modules/itertools.java
throw Py.ValueError("Step must be one or larger for islice()");

              
//in src/org/python/modules/itertools.java
throw Py.TypeError("izip argument #" + (i + 1)
                        + " must support iteration");

              
//in src/org/python/modules/itertools.java
throw Py.TypeError("starmap requires 2 arguments, got "
                    + starargs.length);

              
//in src/org/python/modules/itertools.java
throw Py.TypeError("iterator must return a tuple");

              
//in src/org/python/modules/itertools.java
throw Py.TypeError("groupby takes two arguments, iterable and key");

              
//in src/org/python/modules/_functools/PyPartialDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/modules/_functools/PyPartialDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/modules/_functools/PyPartialDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/modules/_functools/PyPartialDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/modules/_functools/PyPartialDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/modules/_functools/PyPartialDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/modules/_functools/PyPartialDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/modules/_functools/PyPartialDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/modules/_functools/PyPartialDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/modules/_functools/PyPartialDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/modules/_functools/PyPartialDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/modules/_functools/PyPartialDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/modules/_functools/PyPartialDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/modules/_functools/PyPartialDerived.java
throw exc;

              
//in src/org/python/modules/_functools/PyPartialDerived.java
throw exc;

              
//in src/org/python/modules/_functools/PyPartialDerived.java
throw exc;

              
//in src/org/python/modules/_functools/PyPartialDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/modules/_functools/PyPartialDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/modules/_functools/PyPartialDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/modules/_functools/PyPartialDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/modules/_functools/PyPartial.java
throw Py.TypeError("type 'partial' takes at least one argument");

              
//in src/org/python/modules/_functools/PyPartial.java
throw Py.TypeError("the first argument must be callable");

              
//in src/org/python/modules/_functools/PyPartial.java
throw Py.TypeError("setting partial object's dictionary to a non-dict");

              
//in src/org/python/modules/_functools/_functools.java
throw Py.TypeError("reduce of empty sequence with no initial value");

              
//in src/org/python/modules/cStringIO.java
throw Py.ValueError("I/O operation on closed file");

              
//in src/org/python/modules/cStringIO.java
throw Py.OverflowError("long int too large to convert to int");

              
//in src/org/python/modules/_threading/Lock.java
throw Py.AssertionError("release() of un-acquire()d lock");

              
//in src/org/python/modules/imp.java
throw Py.IOError(ioe);

              
//in src/org/python/modules/imp.java
throw Py.ImportError("No module named " + name);

              
//in src/org/python/modules/imp.java
throw Py.TypeError("must be a file-like object");

              
//in src/org/python/modules/imp.java
throw Py.TypeError("must be a file-like object");

              
//in src/org/python/modules/imp.java
throw Py.ImportError("No module named " + name);

              
//in src/org/python/modules/imp.java
throw Py.TypeError("must be a file-like object");

              
//in src/org/python/modules/imp.java
throw Py.ImportError("No module named " + name);

              
//in src/org/python/modules/imp.java
throw Py.RuntimeError("not holding the import lock");

              
//in src/org/python/modules/time/Time.java
throw info.unexpectedCall(0, false);

              
//in src/org/python/modules/time/Time.java
throw e;

              
//in src/org/python/modules/time/Time.java
throw Py.ValueError("timestamp out of range for platform time_t");

              
//in src/org/python/modules/time/Time.java
throw Py.TypeError("a float is required");

              
//in src/org/python/modules/time/Time.java
throw Py.TypeError("expected string of buffer");

              
//in src/org/python/modules/time/PyTimeTuple.java
throw Py.TypeError("time.struct_time() takes a 9-sequence (1-sequence given)");

              
//in src/org/python/modules/time/PyTimeTuple.java
throw Py.TypeError("time.struct_time() takes a 9-sequence (1-sequence given)");

              
//in src/org/python/modules/synchronize.java
throw Py.TypeError("synchronized callable called with 0 args");

              
//in src/org/python/modules/synchronize.java
throw Py.TypeError("synchronized callable called with 0 args");

              
//in src/org/python/modules/PyTeeIterator.java
throw Py.TypeError("tee expected 1 arguments, got " + nargs);

              
//in src/org/python/modules/PyTeeIterator.java
throw Py.ValueError("n must be >= 0");

              
//in src/org/python/modules/PyTeeIterator.java
throw pyEx;

              
//in src/org/python/modules/_codecs.java
throw Py.TypeError("character mapping must return " + "integer greater than 0 and less than sys.maxunicode");

              
//in src/org/python/modules/_codecs.java
throw Py.TypeError("character mapping must return " + "integer, None or str");

              
//in src/org/python/modules/_codecs.java
throw Py.TypeError(String.format("character mapping must be in range(0x%x)",
                                                     PySystemState.maxunicode + 1));

              
//in src/org/python/modules/_codecs.java
throw Py.TypeError("character mapping must return integer, None or unicode");

              
//in src/org/python/modules/_codecs.java
throw Py.UnicodeEncodeError("charmap",
                            str,
                            i,
                            i + 1,
                            "character maps to <undefined>");

              
//in src/org/python/modules/_codecs.java
throw Py.TypeError("character mapping must be in range(256)");

              
//in src/org/python/modules/_codecs.java
throw Py.TypeError("character mapping must return " + "integer, None or str");

              
//in src/org/python/modules/_codecs.java
throw Py.TypeError("bad argument type for built-in operation");

              
//in src/org/python/modules/_hashlib.java
throw Py.ValueError("unsupported hash type");

              
//in src/org/python/modules/_hashlib.java
throw Py.RuntimeError(String.format("_hashlib.HASH (%s) internal error", name));

              
//in src/org/python/modules/_hashlib.java
throw Py.TypeError("update() argument 1 must be string or read-only buffer, not "
                                   + obj.getType().fastGetName());

              
//in src/org/python/core/PyBuiltinMethodNarrow.java
throw info.unexpectedCall(args.length, true);

              
//in src/org/python/core/PyBuiltinMethodNarrow.java
throw info.unexpectedCall(args.length, false);

              
//in src/org/python/core/PyBuiltinMethodNarrow.java
throw info.unexpectedCall(0, false);

              
//in src/org/python/core/PyBuiltinMethodNarrow.java
throw info.unexpectedCall(1, false);

              
//in src/org/python/core/PyBuiltinMethodNarrow.java
throw info.unexpectedCall(2, false);

              
//in src/org/python/core/PyBuiltinMethodNarrow.java
throw info.unexpectedCall(3, false);

              
//in src/org/python/core/PyBuiltinMethodNarrow.java
throw info.unexpectedCall(4, false);

              
//in src/org/python/core/PyBeanProperty.java
throw Py.AttributeError("instance attr: "+__name__);

              
//in src/org/python/core/PyBeanProperty.java
throw Py.AttributeError("write-only attr: "+__name__);

              
//in src/org/python/core/PyBeanProperty.java
throw Py.JavaError(e);

              
//in src/org/python/core/PyBeanProperty.java
throw Py.AttributeError("instance attr: "+__name__);

              
//in src/org/python/core/PyBeanProperty.java
throw Py.AttributeError("read-only attr: "+__name__);

              
//in src/org/python/core/PyBeanProperty.java
throw Py.JavaError(t);

              
//in src/org/python/core/PyBeanProperty.java
throw Py.JavaError(e);

              
//in src/org/python/core/JavaImporter.java
throw Py.ImportError("unable to handle");

              
//in src/org/python/core/PyClassMethod.java
throw Py.TypeError("'" + callable.getType().fastGetName() + "' object is not callable");

              
//in src/org/python/core/PyClassMethod.java
throw Py.TypeError("classmethod does not accept keyword arguments");

              
//in src/org/python/core/PyClassMethod.java
throw Py.TypeError("classmethod expected 1 argument, got " + args.length);

              
//in src/org/python/core/PyObject.java
throw Py.TypeError("object.__new__() takes no parameters");

              
//in src/org/python/core/PyObject.java
throw Py.TypeError(String.format("Can't instantiate abstract class %s with abstract "
                                             + "methods %s", subtype.fastGetName(), methods));

              
//in src/org/python/core/PyObject.java
throw Py.TypeError("__class__ assignment: only for heap types");

              
//in src/org/python/core/PyObject.java
throw Py.TypeError("can't delete __class__ attribute");

              
//in src/org/python/core/PyObject.java
throw Py.SystemError("Automatic proxy initialization should only occur on proxy classes");

              
//in src/org/python/core/PyObject.java
throw Py.TypeError(msg);

              
//in src/org/python/core/PyObject.java
throw Py.TypeError("constructor requires arguments");

              
//in src/org/python/core/PyObject.java
throw Py.JavaError(exc);

              
//in src/org/python/core/PyObject.java
throw Py.TypeError("Proxy instance already initialized");

              
//in src/org/python/core/PyObject.java
throw Py.TypeError("Proxy initialized with another instance");

              
//in src/org/python/core/PyObject.java
throw pye;

              
//in src/org/python/core/PyObject.java
throw Py.TypeError(String.format("'%s' object is not callable", getType().fastGetName()));

              
//in src/org/python/core/PyObject.java
throw Py.TypeError(name
                        + "argument after ** must be a mapping");

              
//in src/org/python/core/PyObject.java
throw Py.TypeError(
                        name
                            + "got multiple values for "
                            + "keyword argument '"
                            + keyword
                            + "'");

              
//in src/org/python/core/PyObject.java
throw Py.TypeError(name + "keywords must be strings");

              
//in src/org/python/core/PyObject.java
throw Py.TypeError(String.format("object of type '%.200s' has no len()",
                                         getType().fastGetName()));

              
//in src/org/python/core/PyObject.java
throw Py.TypeError(String.format("'%.200s' object is unsubscriptable",
                                         getType().fastGetName()));

              
//in src/org/python/core/PyObject.java
throw Py.KeyError("" + key);

              
//in src/org/python/core/PyObject.java
throw Py.KeyError(key);

              
//in src/org/python/core/PyObject.java
throw Py.TypeError(String.format("'%.200s' object does not support item assignment",
                                         getType().fastGetName()));

              
//in src/org/python/core/PyObject.java
throw Py.TypeError(String.format("'%.200s' object doesn't support item deletion",
                                         getType().fastGetName()));

              
//in src/org/python/core/PyObject.java
throw Py.TypeError(String.format("'%.200s' object is not iterable",
                                         getType().fastGetName()));

              
//in src/org/python/core/PyObject.java
throw exc;

              
//in src/org/python/core/PyObject.java
throw Py.AttributeError(String.format("'%.50s' object has no attribute '%.400s'",
                                              getType().fastGetName(), name));

              
//in src/org/python/core/PyObject.java
throw Py.TypeError("readonly attribute");

              
//in src/org/python/core/PyObject.java
throw Py.AttributeError("__coerce__");

              
//in src/org/python/core/PyObject.java
throw Py.ValueError("can't order recursive values");

              
//in src/org/python/core/PyObject.java
throw Py.ValueError("can't order recursive values");

              
//in src/org/python/core/PyObject.java
throw Py.ValueError("can't order recursive values");

              
//in src/org/python/core/PyObject.java
throw Py.ValueError("can't order recursive values");

              
//in src/org/python/core/PyObject.java
throw Py.TypeError("hex() argument can't be converted to hex");

              
//in src/org/python/core/PyObject.java
throw Py.TypeError("oct() argument can't be converted to oct");

              
//in src/org/python/core/PyObject.java
throw Py.AttributeError("__int__");

              
//in src/org/python/core/PyObject.java
throw Py.AttributeError("__long__");

              
//in src/org/python/core/PyObject.java
throw Py.AttributeError("__float__");

              
//in src/org/python/core/PyObject.java
throw Py.AttributeError("__complex__");

              
//in src/org/python/core/PyObject.java
throw Py.TypeError(String.format("bad operand type for unary +: '%.200s'",
                                         getType().fastGetName()));

              
//in src/org/python/core/PyObject.java
throw Py.TypeError(String.format("bad operand type for unary -: '%.200s'",
                                         getType().fastGetName()));

              
//in src/org/python/core/PyObject.java
throw Py.TypeError(String.format("bad operand type for abs(): '%.200s'",
                                         getType().fastGetName()));

              
//in src/org/python/core/PyObject.java
throw Py.TypeError(String.format("bad operand type for unary ~: '%.200s'",
                                         getType().fastGetName()));

              
//in src/org/python/core/PyObject.java
throw Py.TypeError(String.format("'%.200s' object cannot be interpreted as an index",
                                         getType().fastGetName()));

              
//in src/org/python/core/PyObject.java
throw Py.TypeError(_unsupportedop(op, o2));

              
//in src/org/python/core/PyObject.java
throw Py.TypeError(_unsupportedop("+",o2));

              
//in src/org/python/core/PyObject.java
throw Py.TypeError(_unsupportedop("-",o2));

              
//in src/org/python/core/PyObject.java
throw Py.TypeError(_unsupportedop("*",o2));

              
//in src/org/python/core/PyObject.java
throw Py.TypeError(_unsupportedop("/",o2));

              
//in src/org/python/core/PyObject.java
throw Py.TypeError(_unsupportedop("//",o2));

              
//in src/org/python/core/PyObject.java
throw Py.TypeError(_unsupportedop("/",o2));

              
//in src/org/python/core/PyObject.java
throw Py.TypeError(_unsupportedop("%",o2));

              
//in src/org/python/core/PyObject.java
throw Py.TypeError(_unsupportedop("divmod",o2));

              
//in src/org/python/core/PyObject.java
throw Py.TypeError(_unsupportedop("**",o2));

              
//in src/org/python/core/PyObject.java
throw Py.TypeError(_unsupportedop("<<",o2));

              
//in src/org/python/core/PyObject.java
throw Py.TypeError(_unsupportedop(">>",o2));

              
//in src/org/python/core/PyObject.java
throw Py.TypeError(_unsupportedop("&",o2));

              
//in src/org/python/core/PyObject.java
throw Py.TypeError(_unsupportedop("|",o2));

              
//in src/org/python/core/PyObject.java
throw Py.TypeError(_unsupportedop("^",o2));

              
//in src/org/python/core/PyObject.java
throw (Throwable) t;

              
//in src/org/python/core/PyObject.java
throw e;

              
//in src/org/python/core/PyObject.java
throw (RuntimeException) t;

              
//in src/org/python/core/PyObject.java
throw (Error) t;

              
//in src/org/python/core/PyObject.java
throw Py.JavaError(t);

              
//in src/org/python/core/PyObject.java
throw Py.TypeError("can't set attribute '__dict__' of instance of " + getType().fastGetName());

              
//in src/org/python/core/PyObject.java
throw Py.TypeError("can't delete attribute '__dict__' of instance of '" + getType().fastGetName()+ "'");

              
//in src/org/python/core/PyObject.java
throw Py.AttributeError("object internal __set__ impl is abstract");

              
//in src/org/python/core/PyObject.java
throw Py.AttributeError("object internal __delete__ impl is abstract");

              
//in src/org/python/core/PyObject.java
throw Py.TypeError("attribute name must be a string");

              
//in src/org/python/core/PyObject.java
throw exc;

              
//in src/org/python/core/PyObject.java
throw Py.TypeError(String.format("can't apply this %s to %s object", what,
                                             objtype.fastGetName()));

              
//in src/org/python/core/PyObject.java
throw Py.TypeError("copy_reg._slotnames didn't return a list or None");

              
//in src/org/python/core/PyObject.java
throw Py.TypeError("__getnewargs__ should return a tuple");

              
//in src/org/python/core/PyObject.java
throw Py.AssertionError("slots not a list");

              
//in src/org/python/core/PyObject.java
throw Py.TypeError("expected a str");

              
//in src/org/python/core/PyObject.java
throw Py.TypeError("an integer is required");

              
//in src/org/python/core/PyObject.java
throw pye;

              
//in src/org/python/core/PyObject.java
throw Py.TypeError("nb_int should return int object");

              
//in src/org/python/core/PyObject.java
throw Py.TypeError("an integer is required");

              
//in src/org/python/core/PyObject.java
throw pye;

              
//in src/org/python/core/PyObject.java
throw Py.TypeError("integer conversion failed");

              
//in src/org/python/core/PyObject.java
throw Py.TypeError("a float is required");

              
//in src/org/python/core/PyObject.java
throw pye;

              
//in src/org/python/core/PyStringMap.java
throw Py.KeyError("'" + key + "'");

              
//in src/org/python/core/PyStringMap.java
throw Py.KeyError("'" + key.toString() + "'");

              
//in src/org/python/core/PyStringMap.java
throw Py.KeyError(key);

              
//in src/org/python/core/PyStringMap.java
throw Py.KeyError(key.toString());

              
//in src/org/python/core/PyStringMap.java
throw PyBuiltinCallable.DefaultInfo.unexpectedCall(nargs, false, "update", 0, 1);

              
//in src/org/python/core/PyStringMap.java
throw Py.TypeError(String.format("cannot convert dictionary update sequence "
                                                     + "element #%d to a sequence", i));

              
//in src/org/python/core/PyStringMap.java
throw pye;

              
//in src/org/python/core/PyStringMap.java
throw Py.ValueError(String.format("dictionary update sequence element #%d "
                                                  + "has length %d; 2 is required", i, n));

              
//in src/org/python/core/PyStringMap.java
throw Py.KeyError("popitem(): dictionary is empty");

              
//in src/org/python/core/PyStringMap.java
throw Py.KeyError("pop(): dictionary is empty");

              
//in src/org/python/core/PyStringMap.java
throw Py.KeyError(key.__repr__().toString());

              
//in src/org/python/core/PyStringMap.java
throw Py.TypeError(String.format("unhashable type: '%.200s'", getType().fastGetName()));

              
//in src/org/python/core/PyStringMap.java
throw Py.RuntimeError("dictionary changed size during iteration");

              
//in src/org/python/core/PyJavaPackage.java
throw Py.TypeError("cannot set java package __mgr__ to None");

              
//in src/org/python/core/PyList.java
throw Py.MemoryError("");

              
//in src/org/python/core/PyList.java
throw Py.MemoryError("");

              
//in src/org/python/core/PyList.java
throw Py.IndexError("index out of range: " + o);

              
//in src/org/python/core/PyList.java
throw Py.ValueError(message);

              
//in src/org/python/core/PyList.java
throw Py.ValueError(message);

              
//in src/org/python/core/PyList.java
throw Py.IndexError("pop from empty list");

              
//in src/org/python/core/PyList.java
throw Py.IndexError("pop index out of range");

              
//in src/org/python/core/PyList.java
throw pye;

              
//in src/org/python/core/PyList.java
throw Py.ValueError("list modified during sort");

              
//in src/org/python/core/PyList.java
throw Py.ValueError("list modified during sort");

              
//in src/org/python/core/PyList.java
throw Py.ValueError("list modified during sort");

              
//in src/org/python/core/PyList.java
throw Py.TypeError(String.format("unhashable type: '%.200s'", getType().fastGetName()));

              
//in src/org/python/core/PyProperty.java
throw Py.AttributeError("unreadable attribute");

              
//in src/org/python/core/PyProperty.java
throw Py.AttributeError("can't set attribute");

              
//in src/org/python/core/PyProperty.java
throw Py.AttributeError("can't delete attribute");

              
//in src/org/python/core/PyFloatDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/core/PyFloatDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyFloatDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyFloatDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyFloatDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyFloatDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyFloatDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyFloatDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/core/PyFloatDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyFloatDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/core/PyFloatDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/core/PyFloatDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/core/PyFloatDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/core/PyFloatDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/core/PyFloatDerived.java
throw exc;

              
//in src/org/python/core/PyFloatDerived.java
throw exc;

              
//in src/org/python/core/PyFloatDerived.java
throw exc;

              
//in src/org/python/core/PyFloatDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/core/PyFloatDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/core/PyFloatDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/core/PyFloatDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyUnicode.java
throw Py.TypeError("decoder did not return an unicode object (type=" +
                            decoded.getType().fastGetName() + ")");

              
//in src/org/python/core/PyUnicode.java
throw Py.TypeError("coercing to Unicode: need string or buffer, " +
                    o.getType().fastGetName() + "found");

              
//in src/org/python/core/PyUnicode.java
throw Py.TypeError("strip arg must be None, unicode or str");

              
//in src/org/python/core/PyUnicode.java
throw Py.ValueError("empty separator");

              
//in src/org/python/core/PyUnicode.java
throw Py.TypeError(function + "() argument 2 must be char, not str");

              
//in src/org/python/core/PySuper.java
throw PyBuiltinCallable.DefaultInfo.unexpectedCall(args.length, keywords.length != 0,
                                                               "super", 1, 2);

              
//in src/org/python/core/PySuper.java
throw Py.TypeError("super: argument 1 must be type");

              
//in src/org/python/core/PySuper.java
throw Py.TypeError("super(type, obj): obj must be an instance or subtype of type");

              
//in src/org/python/core/PyClass.java
throw Py.TypeError("PyClass_New: name must be a string");

              
//in src/org/python/core/PyClass.java
throw Py.TypeError("PyClass_New: dict must be a dictionary");

              
//in src/org/python/core/PyClass.java
throw Py.TypeError("PyClass_New: bases must be a tuple");

              
//in src/org/python/core/PyClass.java
throw Py.TypeError("PyClass_New: base must be a class");

              
//in src/org/python/core/PyClass.java
throw Py.AttributeError(String.format("class %.50s has no attribute '%.400s'", __name__,
                                              name));

              
//in src/org/python/core/PyClass.java
throw Py.TypeError("__dict__ must be a dictionary object");

              
//in src/org/python/core/PyClass.java
throw Py.TypeError("__bases__ must be a tuple object");

              
//in src/org/python/core/PyClass.java
throw Py.TypeError("__bases__ items must be classes");

              
//in src/org/python/core/PyClass.java
throw Py.TypeError("a __bases__ item causes an inheritance cycle");

              
//in src/org/python/core/PyClass.java
throw Py.TypeError("__name__ must be a string object");

              
//in src/org/python/core/PyClass.java
throw Py.TypeError("__name__ must not contain null bytes");

              
//in src/org/python/core/PyArrayDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/core/PyArrayDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyArrayDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyArrayDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyArrayDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyArrayDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyArrayDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyArrayDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/core/PyArrayDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyArrayDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/core/PyArrayDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/core/PyArrayDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/core/PyArrayDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/core/PyArrayDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/core/PyArrayDerived.java
throw exc;

              
//in src/org/python/core/PyArrayDerived.java
throw exc;

              
//in src/org/python/core/PyArrayDerived.java
throw exc;

              
//in src/org/python/core/PyArrayDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/core/PyArrayDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/core/PyArrayDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/core/PyArrayDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyReflectedConstructor.java
throw Py.JavaError(t);

              
//in src/org/python/core/PyReflectedConstructor.java
throw Py.TypeError("invalid self argument to constructor");

              
//in src/org/python/core/PyReflectedConstructor.java
throw Py.TypeError("self invalid - must be a Java subclass [self=" + self + "]");

              
//in src/org/python/core/PyReflectedConstructor.java
throw Py.TypeError("No visible constructors for class (" + javaClass.getName() + ")");

              
//in src/org/python/core/PyReflectedConstructor.java
throw Py.TypeError("self invalid - must implement: " + declaringClass.getName());

              
//in src/org/python/core/PyReflectedConstructor.java
throw Py.TypeError("can't instantiate interface (" + declaringClass.getName() + ")");

              
//in src/org/python/core/PyReflectedConstructor.java
throw Py.TypeError("can't instantiate abstract class (" + declaringClass.getName() + ")");

              
//in src/org/python/core/PyReflectedConstructor.java
throw Py.TypeError("instance already instantiated for " + sup.getName());

              
//in src/org/python/core/PyReflectedConstructor.java
throw Py.TypeError("constructor requires self argument");

              
//in src/org/python/core/PyReflectedConstructor.java
throw Py.TypeError(msg);

              
//in src/org/python/core/PyReflectedConstructor.java
throw Py.JavaError(e);

              
//in src/org/python/core/PyReflectedConstructor.java
throw Py.JavaError(t);

              
//in src/org/python/core/PyMethodDescr.java
throw Py.TypeError(name + " requires at least one argument");

              
//in src/org/python/core/PyTuple.java
throw Py.MemoryError("");

              
//in src/org/python/core/PyTuple.java
throw Py.IndexError("index out of range: " + index);

              
//in src/org/python/core/PyTuple.java
throw Py.TypeError("'tuple' object does not support item assignment");

              
//in src/org/python/core/PyTuple.java
throw Py.ValueError("tuple.index(x): x not in list");

              
//in src/org/python/core/PyEnumerateDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/core/PyEnumerateDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyEnumerateDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyEnumerateDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyEnumerateDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyEnumerateDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyEnumerateDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyEnumerateDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/core/PyEnumerateDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyEnumerateDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/core/PyEnumerateDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/core/PyEnumerateDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/core/PyEnumerateDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/core/PyEnumerateDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/core/PyEnumerateDerived.java
throw exc;

              
//in src/org/python/core/PyEnumerateDerived.java
throw exc;

              
//in src/org/python/core/PyEnumerateDerived.java
throw exc;

              
//in src/org/python/core/PyEnumerateDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/core/PyEnumerateDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/core/PyEnumerateDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/core/PyEnumerateDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PySystemState.java
throw Py.TypeError("readonly attribute");

              
//in src/org/python/core/PySystemState.java
throw Py.TypeError("readonly attribute");

              
//in src/org/python/core/PySystemState.java
throw Py.AttributeError(name);

              
//in src/org/python/core/PySystemState.java
throw Py.ValueError("Recursion limit must be positive");

              
//in src/org/python/core/PySystemState.java
throw Py.ValueError("call stack is not deep enough");

              
//in src/org/python/core/PySystemState.java
throw info.unexpectedCall(1, false);

              
//in src/org/python/core/PySystemState.java
throw info.unexpectedCall(3, false);

              
//in src/org/python/core/PyDataDescr.java
throw Py.TypeError(String.format("unsupported type for assignment to %s: '%.200s'",
                                             name, value.getType().fastGetName()));

              
//in src/org/python/core/MakeProxies.java
throw Py.JavaError(exc);

              
//in src/org/python/core/MakeProxies.java
throw Py.JavaError(exc);

              
//in src/org/python/core/BytecodeLoader.java
throw Py.JavaError(e);

              
//in src/org/python/core/PySet.java
throw PyBuiltinCallable.DefaultInfo.unexpectedCall(nargs, false, "Set", 0, 1);

              
//in src/org/python/core/PySet.java
throw Py.TypeError("set objects are unhashable");

              
//in src/org/python/core/PyDictionary.java
throw Py.TypeError("loop over non-sequence");

              
//in src/org/python/core/PyDictionary.java
throw Py.KeyError(key);

              
//in src/org/python/core/PyDictionary.java
throw Py.KeyError(key.toString());

              
//in src/org/python/core/PyDictionary.java
throw PyBuiltinCallable.DefaultInfo.unexpectedCall(nargs, false, methName, 0, 1);

              
//in src/org/python/core/PyDictionary.java
throw Py.TypeError(String.format("cannot convert dictionary update sequence "
                                                     + "element #%d to a sequence", i));

              
//in src/org/python/core/PyDictionary.java
throw pye;

              
//in src/org/python/core/PyDictionary.java
throw Py.ValueError(String.format("dictionary update sequence element #%d "
                                                  + "has length %d; 2 is required", i, n));

              
//in src/org/python/core/PyDictionary.java
throw Py.KeyError("popitem(): dictionary is empty");

              
//in src/org/python/core/PyDictionary.java
throw Py.KeyError("popitem(): dictionary is empty");

              
//in src/org/python/core/PyDictionary.java
throw Py.TypeError(String.format("unhashable type: '%.200s'", getType().fastGetName()));

              
//in src/org/python/core/PyDictionary.java
throw Py.RuntimeError("dictionary changed size during iteration");

              
//in src/org/python/core/PyDictionary.java
throw Py.RuntimeError("dictionary changed size during iteration");

              
//in src/org/python/core/PyFileWriter.java
throw Py.ValueError("I/O operation on closed file");

              
//in src/org/python/core/PyFileWriter.java
throw Py.IOError(e);

              
//in src/org/python/core/PyFileWriter.java
throw Py.IOError(e);

              
//in src/org/python/core/PyFileWriter.java
throw Py.TypeError("write requires a string as its argument");

              
//in src/org/python/core/PyFileWriter.java
throw Py.IOError(e);

              
//in src/org/python/core/PyFileWriter.java
throw Py.TypeError("writelines() argument must be a sequence of strings");

              
//in src/org/python/core/PyUnicodeDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/core/PyUnicodeDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyUnicodeDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyUnicodeDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyUnicodeDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyUnicodeDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyUnicodeDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyUnicodeDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/core/PyUnicodeDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyUnicodeDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/core/PyUnicodeDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/core/PyUnicodeDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/core/PyUnicodeDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/core/PyUnicodeDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/core/PyUnicodeDerived.java
throw exc;

              
//in src/org/python/core/PyUnicodeDerived.java
throw exc;

              
//in src/org/python/core/PyUnicodeDerived.java
throw exc;

              
//in src/org/python/core/PyUnicodeDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/core/PyUnicodeDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/core/PyUnicodeDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/core/PyFile.java
throw Py.TypeError("coercing to Unicode: need string, '" + name.getType().fastGetName()
                               + "' type found");

              
//in src/org/python/core/PyFile.java
throw Py.ValueError("unknown mode: '" + mode + "'");

              
//in src/org/python/core/PyFile.java
throw Py.ValueError("empty mode string");

              
//in src/org/python/core/PyFile.java
throw Py.ValueError("universal newline mode can only be used with modes starting "
                                    + "with 'r'");

              
//in src/org/python/core/PyFile.java
throw Py.ValueError("mode string must begin with one of 'r', 'w', 'a' or 'U', not '"
                                + origMode + "'");

              
//in src/org/python/core/PyFile.java
throw Py.StopIteration("");

              
//in src/org/python/core/PyFile.java
throw Py.TypeError(message);

              
//in src/org/python/core/PyFile.java
throw Py.TypeError("can't delete numeric/char attribute");

              
//in src/org/python/core/PyFastSequenceIter.java
throw pye;

              
//in src/org/python/core/PyTableCode.java
throw Py.TypeError("readonly attribute");

              
//in src/org/python/core/PyTableCode.java
throw Py.AttributeError(name);

              
//in src/org/python/core/PyTableCode.java
throw pye;

              
//in src/org/python/core/PyComplex.java
throw Py.TypeError("complex() can't take second arg if first is a string");

              
//in src/org/python/core/PyComplex.java
throw Py.TypeError("complex() second arg can't be a string");

              
//in src/org/python/core/PyComplex.java
throw pye;

              
//in src/org/python/core/PyComplex.java
throw Py.TypeError("complex() argument must be a string or a number");

              
//in src/org/python/core/PyComplex.java
throw pye;

              
//in src/org/python/core/PyComplex.java
throw Py.TypeError("complex() argument must be a string or a number");

              
//in src/org/python/core/PyComplex.java
throw pye;

              
//in src/org/python/core/PyComplex.java
throw Py.TypeError("cannot compare complex numbers using <, <=, >, >=");

              
//in src/org/python/core/PyComplex.java
throw Py.TypeError("xxx");

              
//in src/org/python/core/PyComplex.java
throw Py.ZeroDivisionError("complex division");

              
//in src/org/python/core/PyComplex.java
throw Py.ValueError("complex modulo");

              
//in src/org/python/core/PyComplex.java
throw Py.ZeroDivisionError("0.0 to a negative or complex power");

              
//in src/org/python/core/PyComplex.java
throw Py.TypeError("bad operand type for unary ~");

              
//in src/org/python/core/PyComplex.java
throw Py.TypeError("can't convert complex to int; use e.g. int(abs(z))");

              
//in src/org/python/core/PyComplex.java
throw Py.TypeError("can't convert complex to long; use e.g. long(abs(z))");

              
//in src/org/python/core/PyComplex.java
throw Py.TypeError("can't convert complex to float; use e.g. abs(z)");

              
//in src/org/python/core/PyReflectedField.java
throw Py.JavaError(exc);

              
//in src/org/python/core/PyReflectedField.java
throw Py.AttributeError("set instance variable as static: " + field.toString());

              
//in src/org/python/core/PyReflectedField.java
throw Py.JavaError(exc);

              
//in src/org/python/core/PyInstance.java
throw Py.TypeError("instance() second arg must be dictionary or None");

              
//in src/org/python/core/PyInstance.java
throw Py.ValueError("Can't find module for class: "+
                                instclass.__name__);

              
//in src/org/python/core/PyInstance.java
throw Py.ValueError("Can't find module for class with no name");

              
//in src/org/python/core/PyInstance.java
throw Py.TypeError("this constructor takes no arguments");

              
//in src/org/python/core/PyInstance.java
throw Py.TypeError("__init__() should return None");

              
//in src/org/python/core/PyInstance.java
throw Py.AttributeError(String.format("%.50s instance has no attribute '%.400s'",
                                              instclass.__name__, name));

              
//in src/org/python/core/PyInstance.java
throw Py.TypeError("__class__ must be set to a class");

              
//in src/org/python/core/PyInstance.java
throw Py.AttributeError("class " + instclass.__name__ +
                                        " has no attribute '" + name + "'");

              
//in src/org/python/core/PyInstance.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/core/PyInstance.java
throw Py.TypeError("__repr__ method must return a string");

              
//in src/org/python/core/PyInstance.java
throw Py.TypeError("__str__ method must return a string");

              
//in src/org/python/core/PyInstance.java
throw Py.TypeError("__unicode__ must return unicode or str");

              
//in src/org/python/core/PyInstance.java
throw Py.TypeError("unhashable instance");

              
//in src/org/python/core/PyInstance.java
throw Py.TypeError("__hash__() must really return int" + ret.getType() );

              
//in src/org/python/core/PyInstance.java
throw Py.TypeError("__cmp__() must return int");

              
//in src/org/python/core/PyInstance.java
throw Py.TypeError("__cmp__() must return int");

              
//in src/org/python/core/PyInstance.java
throw Py.TypeError("__len__() should return an int");

              
//in src/org/python/core/PyInstance.java
throw e;

              
//in src/org/python/core/PyInstance.java
throw exc;

              
//in src/org/python/core/PyInstance.java
throw Py.TypeError("instance has no next() method");

              
//in src/org/python/core/PyInstance.java
throw Py.TypeError("coercion should return None or 2-tuple");

              
//in src/org/python/core/PyInstance.java
throw pye;

              
//in src/org/python/core/PyInstance.java
throw Py.TypeError("object cannot be interpreted as an index");

              
//in src/org/python/core/PyInstance.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",
                                         ret.getType().fastGetName()));

              
//in src/org/python/core/PyInstance.java
throw Py.TypeError("__hex__() should return a string");

              
//in src/org/python/core/PyInstance.java
throw Py.TypeError("__oct__() should return a string");

              
//in src/org/python/core/PyInstance.java
throw Py.TypeError("__int__() should return a int");

              
//in src/org/python/core/PyInstance.java
throw Py.TypeError("__float__() should return a float");

              
//in src/org/python/core/PyInstance.java
throw Py.TypeError("__long__() should return a long");

              
//in src/org/python/core/PyInstance.java
throw Py.TypeError("__complex__() should return a complex");

              
//in src/org/python/core/PyInstance.java
throw Py.RuntimeError("maximum recursion depth exceeded");

              
//in src/org/python/core/PyInstance.java
throw Py.RuntimeError("maximum recursion depth exceeded");

              
//in src/org/python/core/PyInstance.java
throw Py.RuntimeError("maximum recursion depth exceeded");

              
//in src/org/python/core/PyInstance.java
throw Py.RuntimeError("maximum recursion depth exceeded");

              
//in src/org/python/core/PyInstance.java
throw Py.RuntimeError("maximum recursion depth exceeded");

              
//in src/org/python/core/PyInstance.java
throw Py.RuntimeError("maximum recursion depth exceeded");

              
//in src/org/python/core/PyInstance.java
throw Py.RuntimeError("maximum recursion depth exceeded");

              
//in src/org/python/core/PyInstance.java
throw Py.RuntimeError("maximum recursion depth exceeded");

              
//in src/org/python/core/PyInstance.java
throw Py.RuntimeError("maximum recursion depth exceeded");

              
//in src/org/python/core/PyInstance.java
throw Py.RuntimeError("maximum recursion depth exceeded");

              
//in src/org/python/core/PyInstance.java
throw Py.RuntimeError("maximum recursion depth exceeded");

              
//in src/org/python/core/PyInstance.java
throw Py.RuntimeError("maximum recursion depth exceeded");

              
//in src/org/python/core/PyInstance.java
throw Py.RuntimeError("maximum recursion depth exceeded");

              
//in src/org/python/core/PyInstance.java
throw Py.RuntimeError("maximum recursion depth exceeded");

              
//in src/org/python/core/PyInstance.java
throw Py.RuntimeError("maximum recursion depth exceeded");

              
//in src/org/python/core/PyInstance.java
throw Py.RuntimeError("maximum recursion depth exceeded");

              
//in src/org/python/core/PyInstance.java
throw Py.RuntimeError("maximum recursion depth exceeded");

              
//in src/org/python/core/PyInstance.java
throw Py.RuntimeError("maximum recursion depth exceeded");

              
//in src/org/python/core/PyInstance.java
throw Py.RuntimeError("maximum recursion depth exceeded");

              
//in src/org/python/core/PyInstance.java
throw Py.RuntimeError("maximum recursion depth exceeded");

              
//in src/org/python/core/PyInstance.java
throw Py.RuntimeError("maximum recursion depth exceeded");

              
//in src/org/python/core/PyInstance.java
throw Py.RuntimeError("maximum recursion depth exceeded");

              
//in src/org/python/core/PyInstance.java
throw Py.RuntimeError("maximum recursion depth exceeded");

              
//in src/org/python/core/PyInstance.java
throw Py.RuntimeError("maximum recursion depth exceeded");

              
//in src/org/python/core/PyInstance.java
throw Py.RuntimeError("maximum recursion depth exceeded");

              
//in src/org/python/core/PyInstance.java
throw Py.RuntimeError("maximum recursion depth exceeded");

              
//in src/org/python/core/PyInstance.java
throw Py.RuntimeError("maximum recursion depth exceeded");

              
//in src/org/python/core/PyInstance.java
throw Py.RuntimeError("maximum recursion depth exceeded");

              
//in src/org/python/core/PyBaseException.java
throw Py.TypeError("state is not a dictionary");

              
//in src/org/python/core/PyBaseException.java
throw Py.TypeError("__dict__ must be a dictionary");

              
//in src/org/python/core/PyBaseException.java
throw Py.AttributeError("message attribute was deleted");

              
//in src/org/python/core/ContextGuard.java
throw Py.TypeError("Argument must be a generator function.");

              
//in src/org/python/core/ContextGuard.java
throw Py.RuntimeError("generator didn't yield");

              
//in src/org/python/core/ContextGuard.java
throw e;

              
//in src/org/python/core/ContextGuard.java
throw Py.RuntimeError("generator didn't stop");

              
//in src/org/python/core/PyReflectedFunction.java
throw Py.SystemError(msg);

              
//in src/org/python/core/PyReflectedFunction.java
throw Py.JavaError(e);

              
//in src/org/python/core/PyReflectedFunction.java
throw Py.JavaError(t);

              
//in src/org/python/core/PyReflectedFunction.java
throw Py.TypeError(__name__ + "(): " + message);

              
//in src/org/python/core/PyFrame.java
throw Py.UnboundLocalError(String.format(UNBOUNDLOCAL_ERROR_MSG, name));

              
//in src/org/python/core/PyFrame.java
throw Py.NameError(String.format(NAME_ERROR_MSG, index));

              
//in src/org/python/core/PyFrame.java
throw Py.NameError(String.format(GLOBAL_NAME_ERROR_MSG, index));

              
//in src/org/python/core/PyFrame.java
throw Py.SystemError(String.format("no locals found when storing '%s'", value));

              
//in src/org/python/core/PyFrame.java
throw Py.UnboundLocalError(String.format(UNBOUNDLOCAL_ERROR_MSG,
                                                         f_code.co_varnames[index]));

              
//in src/org/python/core/PyFrame.java
throw Py.NameError(String.format(NAME_ERROR_MSG, index));

              
//in src/org/python/core/PyFrame.java
throw pye;

              
//in src/org/python/core/PyFrame.java
throw Py.SystemError(String.format("no locals when deleting '%s'", index));

              
//in src/org/python/core/PyFrame.java
throw Py.NameError(String.format(GLOBAL_NAME_ERROR_MSG, index));

              
//in src/org/python/core/PyFrame.java
throw pye;

              
//in src/org/python/core/PyFrame.java
throw Py.UnboundLocalError(String.format(UNBOUNDLOCAL_ERROR_MSG, name));

              
//in src/org/python/core/PyLongDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/core/PyLongDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyLongDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyLongDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyLongDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyLongDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyLongDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyLongDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/core/PyLongDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyLongDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/core/PyLongDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/core/PyLongDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/core/PyLongDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/core/PyLongDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/core/PyLongDerived.java
throw exc;

              
//in src/org/python/core/PyLongDerived.java
throw exc;

              
//in src/org/python/core/PyLongDerived.java
throw exc;

              
//in src/org/python/core/PyLongDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/core/PyLongDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/core/PyLongDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/core/PyLongDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyBeanEventProperty.java
throw Py.JavaError(exc);

              
//in src/org/python/core/PyBeanEventProperty.java
throw Py.JavaError(e);

              
//in src/org/python/core/PyBeanEventProperty.java
throw Py.AttributeError("Internal bean event error: " + __name__);

              
//in src/org/python/core/PyBeanEventProperty.java
throw Py.JavaError(exc);

              
//in src/org/python/core/AstList.java
throw Py.IndexError("index out of range: " + o);

              
//in src/org/python/core/AstList.java
throw Py.MemoryError("");

              
//in src/org/python/core/AstList.java
throw pye;

              
//in src/org/python/core/AstList.java
throw Py.ValueError(message);

              
//in src/org/python/core/AstList.java
throw Py.MemoryError("");

              
//in src/org/python/core/AstList.java
throw Py.TypeError("setslice with java.util.List and step != 1 not supported yet");

              
//in src/org/python/core/AstList.java
throw Py.TypeError("can only assign an iterable");

              
//in src/org/python/core/AstList.java
throw pye;

              
//in src/org/python/core/PyFloat.java
throw Py.TypeError("float() argument must be a string or a number");

              
//in src/org/python/core/PyFloat.java
throw e;

              
//in src/org/python/core/PyFloat.java
throw Py.TypeError("xxx");

              
//in src/org/python/core/PyFloat.java
throw Py.ZeroDivisionError("float division");

              
//in src/org/python/core/PyFloat.java
throw Py.ZeroDivisionError("float division");

              
//in src/org/python/core/PyFloat.java
throw Py.ZeroDivisionError("float division");

              
//in src/org/python/core/PyFloat.java
throw Py.ZeroDivisionError("float division");

              
//in src/org/python/core/PyFloat.java
throw Py.ZeroDivisionError("float division");

              
//in src/org/python/core/PyFloat.java
throw Py.ZeroDivisionError("float division");

              
//in src/org/python/core/PyFloat.java
throw Py.ZeroDivisionError("float modulo");

              
//in src/org/python/core/PyFloat.java
throw Py.ZeroDivisionError("float division");

              
//in src/org/python/core/PyFloat.java
throw Py.ZeroDivisionError("float division");

              
//in src/org/python/core/PyFloat.java
throw Py.TypeError("pow() 3rd argument not allowed unless all arguments are integers");

              
//in src/org/python/core/PyFloat.java
throw Py.ZeroDivisionError("0.0 cannot be raised to a negative power");

              
//in src/org/python/core/PyFloat.java
throw Py.ValueError("negative number cannot be raised to a fractional power");

              
//in src/org/python/core/PyFloat.java
throw Py.TypeError("bad operand type for unary ~");

              
//in src/org/python/core/PyFloat.java
throw Py.ValueError("__getformat__() argument 1 must be 'double' or 'float'");

              
//in src/org/python/core/PyFloat.java
throw Py.ValueError("__setformat__() argument 1 must be 'double' or 'float'");

              
//in src/org/python/core/PyFloat.java
throw Py.ValueError(String.format("can only set %s format to 'unknown' or the "
                                              + "detected platform value", typestr));

              
//in src/org/python/core/PyFloat.java
throw Py.ValueError("__setformat__() argument 2 must be 'unknown', " +
                                "'IEEE, little-endian' or 'IEEE, big-endian'");

              
//in src/org/python/core/PyBeanEvent.java
throw Py.TypeError("write only attribute");

              
//in src/org/python/core/PyBeanEvent.java
throw Py.TypeError("can't delete this attribute");

              
//in src/org/python/core/PyBeanEvent.java
throw Py.JavaError(e);

              
//in src/org/python/core/PySlice.java
throw Py.TypeError("slice expected at least 1 arguments, got " + args.length);

              
//in src/org/python/core/PySlice.java
throw Py.TypeError("slice expected at most 3 arguments, got " + args.length);

              
//in src/org/python/core/PySlice.java
throw Py.TypeError(String.format("unhashable type: '%.200s'", getType().fastGetName()));

              
//in src/org/python/core/PySlice.java
throw Py.ValueError("slice step cannot be zero");

              
//in src/org/python/core/PySlice.java
throw pye;

              
//in src/org/python/core/PySlice.java
throw Py.TypeError("slice indices must be integers or None or have an __index__ method");

              
//in src/org/python/core/PyDescriptor.java
throw Py.TypeError(msg);

              
//in src/org/python/core/PyDescriptor.java
throw Py.TypeError(msg);

              
//in src/org/python/core/PyIntegerDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/core/PyIntegerDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyIntegerDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyIntegerDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyIntegerDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyIntegerDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyIntegerDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyIntegerDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/core/PyIntegerDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyIntegerDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/core/PyIntegerDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/core/PyIntegerDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/core/PyIntegerDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/core/PyIntegerDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/core/PyIntegerDerived.java
throw exc;

              
//in src/org/python/core/PyIntegerDerived.java
throw exc;

              
//in src/org/python/core/PyIntegerDerived.java
throw exc;

              
//in src/org/python/core/PyIntegerDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/core/PyIntegerDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/core/PyIntegerDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/core/PyIntegerDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyIterator.java
throw toThrow;

              
//in src/org/python/core/PyIterator.java
throw Py.StopIteration("");

              
//in src/org/python/core/PyBaseExceptionDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyBaseExceptionDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyBaseExceptionDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyBaseExceptionDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyBaseExceptionDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyBaseExceptionDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyBaseExceptionDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/core/PyBaseExceptionDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyBaseExceptionDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/core/PyBaseExceptionDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/core/PyBaseExceptionDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/core/PyBaseExceptionDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/core/PyBaseExceptionDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/core/PyBaseExceptionDerived.java
throw exc;

              
//in src/org/python/core/PyBaseExceptionDerived.java
throw exc;

              
//in src/org/python/core/PyBaseExceptionDerived.java
throw exc;

              
//in src/org/python/core/PyBaseExceptionDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/core/PyBaseExceptionDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/core/PyBaseExceptionDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/core/PyBaseExceptionDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/ArgParser.java
throw PyBuiltinCallable.DefaultInfo.unexpectedCall(args.length,
                    false, funcname, minargs, this.params.length);

              
//in src/org/python/core/ArgParser.java
throw AST.unexpectedCall(minargs,  funcname);

              
//in src/org/python/core/ArgParser.java
throw Py.TypeError(String.format("argument %d must be %s, not %s", pos + 1,
                                             type.fastGetName(), arg.getType().fastGetName()));

              
//in src/org/python/core/ArgParser.java
throw Py.TypeError(String.format("%s does not take keyword arguments", funcname));

              
//in src/org/python/core/ArgParser.java
throw Py.TypeError("keyword parameter '"
                                + params[j]
                                + "' was given by position and by name");

              
//in src/org/python/core/ArgParser.java
throw Py.TypeError(String.format(
                                "%s got multiple values for keyword argument '%s'",
                                funcname, params[j]));

              
//in src/org/python/core/ArgParser.java
throw Py.TypeError("'" + kws[i] + "' is an invalid keyword "
                    + "argument for this function");

              
//in src/org/python/core/ArgParser.java
throw Py.TypeError(this.funcname + ": The " + ordinal(pos)
                    + " argument is required");

              
//in src/org/python/core/ArgParser.java
throw Py.TypeError("argument " + (pos + 1) + ": expected "
                    + classname + ", " + value.getType().fastGetName() + " found");

              
//in src/org/python/core/PyBaseCode.java
throw pye;

              
//in src/org/python/core/PyBaseCode.java
throw Py.TypeError(msg);

              
//in src/org/python/core/PyBaseCode.java
throw Py.TypeError(String.format("%.200s() got an unexpected keyword "
                                                         + "argument '%.400s'",
                                                         co_name, keyword));

              
//in src/org/python/core/PyBaseCode.java
throw Py.TypeError(String.format("%.200s() got multiple values for "
                                                         + "keyword argument '%.400s'",
                                                         co_name, keyword));

              
//in src/org/python/core/PyBaseCode.java
throw Py.TypeError(msg);

              
//in src/org/python/core/PyBaseCode.java
throw Py.TypeError(String.format("%.200s() takes no arguments (%d given)",
                                             co_name, argcount));

              
//in src/org/python/core/SequenceIndexDelegate.java
throw Py.TypeError(getTypeName() + " indices must be integers");

              
//in src/org/python/core/SequenceIndexDelegate.java
throw Py.ValueError(String.format("attempt to assign sequence of size %d to extended "
                                              + "slice of size %d", value.__len__(), indices[3]));

              
//in src/org/python/core/SequenceIndexDelegate.java
throw Py.TypeError(getTypeName() + " indices must be integers");

              
//in src/org/python/core/SequenceIndexDelegate.java
throw Py.IndexError("index out of range: " + idx);

              
//in src/org/python/core/SequenceIndexDelegate.java
throw Py.TypeError(getTypeName() + " indices must be integers");

              
//in src/org/python/core/SequenceIndexDelegate.java
throw Py.IndexError(getTypeName() + " assignment index out of range");

              
//in src/org/python/core/io/RawIOBase.java
throw Py.OverflowError("requested number of bytes is more than a Python "
                                           + "string can hold");

              
//in src/org/python/core/io/TextIOBase.java
throw Py.TypeError("Cannot use string as modifiable buffer");

              
//in src/org/python/core/io/TextIOBase.java
throw Py.TypeError("argument 1 must be read-write buffer, not "
                               + buf.getType().fastGetName());

              
//in src/org/python/core/io/ServerSocketIO.java
throw Py.IOError(Errno.ENOTCONN);

              
//in src/org/python/core/io/ServerSocketIO.java
throw Py.IOError(Errno.EBADF);

              
//in src/org/python/core/io/IOBase.java
throw pye;

              
//in src/org/python/core/io/IOBase.java
throw Py.IOError(Errno.EBADF);

              
//in src/org/python/core/io/IOBase.java
throw Py.IOError(Errno.EBADF);

              
//in src/org/python/core/io/IOBase.java
throw Py.ValueError("I/O operation on closed file");

              
//in src/org/python/core/io/IOBase.java
throw Py.IOError(String.format("%s.%s() not supported", className, methodName));

              
//in src/org/python/core/io/StreamIO.java
throw Py.IOError(ioe);

              
//in src/org/python/core/io/StreamIO.java
throw Py.IOError(ioe);

              
//in src/org/python/core/io/StreamIO.java
throw Py.IOError(ioe);

              
//in src/org/python/core/io/StreamIO.java
throw Py.IOError(ioe);

              
//in src/org/python/core/io/SocketIOBase.java
throw Py.ValueError("invalid mode: '" + mode + "'");

              
//in src/org/python/core/io/SocketIOBase.java
throw Py.IOError(ioe);

              
//in src/org/python/core/io/BufferedIOMixin.java
throw pye;

              
//in src/org/python/core/io/FileIO.java
throw Py.IOError(Errno.EISDIR, name);

              
//in src/org/python/core/io/FileIO.java
throw Py.IOError(Errno.EACCES, name);

              
//in src/org/python/core/io/FileIO.java
throw Py.IOError(Errno.ENOENT, name);

              
//in src/org/python/core/io/FileIO.java
throw Py.ValueError("invalid mode: '" + mode + "'");

              
//in src/org/python/core/io/FileIO.java
throw Py.ValueError("Must have exactly one of read/write/append mode");

              
//in src/org/python/core/io/FileIO.java
throw Py.IOError(ioe);

              
//in src/org/python/core/io/FileIO.java
throw Py.IOError(ioe);

              
//in src/org/python/core/io/FileIO.java
throw Py.IOError(ioe);

              
//in src/org/python/core/io/FileIO.java
throw Py.IOError(ioe);

              
//in src/org/python/core/io/FileIO.java
throw Py.OverflowError("requested number of bytes is more than a Python string can "
                                   + "hold");

              
//in src/org/python/core/io/FileIO.java
throw Py.IOError(ioe);

              
//in src/org/python/core/io/FileIO.java
throw Py.IOError(ioe);

              
//in src/org/python/core/io/FileIO.java
throw Py.IOError(Errno.EINVAL);

              
//in src/org/python/core/io/FileIO.java
throw Py.IOError(ioe);

              
//in src/org/python/core/io/FileIO.java
throw Py.IOError(ioe);

              
//in src/org/python/core/io/FileIO.java
throw Py.IOError(ioe);

              
//in src/org/python/core/io/FileIO.java
throw Py.IOError(ioe);

              
//in src/org/python/core/io/DatagramSocketIO.java
throw Py.IOError(ioe);

              
//in src/org/python/core/io/DatagramSocketIO.java
throw Py.IOError(ioe);

              
//in src/org/python/core/io/DatagramSocketIO.java
throw Py.IOError(ioe);

              
//in src/org/python/core/io/DatagramSocketIO.java
throw Py.IOError(ioe);

              
//in src/org/python/core/io/SocketIO.java
throw Py.IOError(ioe);

              
//in src/org/python/core/io/SocketIO.java
throw Py.IOError(ioe);

              
//in src/org/python/core/io/SocketIO.java
throw Py.IOError(ioe);

              
//in src/org/python/core/io/SocketIO.java
throw Py.IOError(ioe);

              
//in src/org/python/core/stringlib/MarkupIterator.java
throw Py.ValueError(e.getMessage());

              
//in src/org/python/core/PySuperDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/core/PySuperDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PySuperDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PySuperDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PySuperDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PySuperDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PySuperDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PySuperDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/core/PySuperDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PySuperDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/core/PySuperDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/core/PySuperDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/core/PySuperDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/core/PySuperDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/core/PySuperDerived.java
throw exc;

              
//in src/org/python/core/PySuperDerived.java
throw exc;

              
//in src/org/python/core/PySuperDerived.java
throw exc;

              
//in src/org/python/core/PySuperDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/core/PySuperDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/core/PySuperDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/core/PySuperDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/StdoutWrapper.java
throw Py.AttributeError("missing sys." + this.name);

              
//in src/org/python/core/PyEnumerate.java
throw PyBuiltinCallable.DefaultInfo.unexpectedCall(args.length, false, "enumerate", 0,
                                                               1);

              
//in src/org/python/core/PyStaticMethod.java
throw Py.TypeError("staticmethod does not accept keyword arguments");

              
//in src/org/python/core/PyStaticMethod.java
throw Py.TypeError("staticmethod expected 1 argument, got " + args.length);

              
//in src/org/python/core/PyArray.java
throw Py.TypeError("array() argument 1 must be char, not str");

              
//in src/org/python/core/PyArray.java
throw Py.TypeError("array() argument 1 must be char, not " + obj.getType().fastGetName());

              
//in src/org/python/core/PyArray.java
throw Py.IndexError("index out of range: " + o);

              
//in src/org/python/core/PyArray.java
throw Py.TypeError("can only append arrays of the same type, expected '"
                               + this.type + ", found " + otherArr.type);

              
//in src/org/python/core/PyArray.java
throw Py.TypeError("can only append arrays of the same type, expected '" + this.type
                               + ", found " + otherArr.type);

              
//in src/org/python/core/PyArray.java
throw Py.TypeError("array item must be unicode character");

              
//in src/org/python/core/PyArray.java
throw Py.RuntimeError("don't know how to byteswap this array type");

              
//in src/org/python/core/PyArray.java
throw Py.ValueError("bad typecode (must be c, b, B, u, h, H, i, I, l, L, f or d)");

              
//in src/org/python/core/PyArray.java
throw Py.TypeError("array item must be char");

              
//in src/org/python/core/PyArray.java
throw Py.TypeError("an integer is required");

              
//in src/org/python/core/PyArray.java
throw Py.TypeError("can only extend with array of same kind");

              
//in src/org/python/core/PyArray.java
throw Py.TypeError("Type not compatible with array type");

              
//in src/org/python/core/PyArray.java
throw Py.TypeError("arg1 must be open file");

              
//in src/org/python/core/PyArray.java
throw Py.EOFError("not enough items in file. "
                    + Integer.toString(count) + " requested, "
                    + Integer.toString(readcount) + " actually read");

              
//in src/org/python/core/PyArray.java
throw Py.TypeError("arg must be list");

              
//in src/org/python/core/PyArray.java
throw Py.ValueError("string length not a multiple of item size");

              
//in src/org/python/core/PyArray.java
throw Py.EOFError("not enough items in string");

              
//in src/org/python/core/PyArray.java
throw Py.IOError(e);

              
//in src/org/python/core/PyArray.java
throw Py.ValueError("fromunicode argument must be an unicode object");

              
//in src/org/python/core/PyArray.java
throw Py.ValueError("fromunicode() may only be called on type 'u' arrays");

              
//in src/org/python/core/PyArray.java
throw Py.ValueError("bad typecode (must be c, b, B, u, h, H, i, I, l, L, f or d)");

              
//in src/org/python/core/PyArray.java
throw Py.ValueError("array.index(" + value + "): " + value
                            + " not found in array");

              
//in src/org/python/core/PyArray.java
throw Py.IndexError("pop from empty array");

              
//in src/org/python/core/PyArray.java
throw Py.IndexError("pop index out of range");

              
//in src/org/python/core/PyArray.java
throw Py.ValueError("array.remove(" + value + "): " + value
                + " not found in array");

              
//in src/org/python/core/PyArray.java
throw Py.TypeError("Type not compatible with array type");

              
//in src/org/python/core/PyArray.java
throw Py.OverflowError("value too small for " + type.getName());

              
//in src/org/python/core/PyArray.java
throw Py.OverflowError("value too large for " + type.getName());

              
//in src/org/python/core/PyArray.java
throw Py.TypeError("Type not compatible with array type");

              
//in src/org/python/core/PyArray.java
throw Py.OverflowError("value too small for " + type.getName());

              
//in src/org/python/core/PyArray.java
throw Py.OverflowError("value too large for " + type.getName());

              
//in src/org/python/core/PyArray.java
throw Py.TypeError("Type not compatible with array type");

              
//in src/org/python/core/PyArray.java
throw Py.OverflowError("value too small for " + type.getName());

              
//in src/org/python/core/PyArray.java
throw Py.OverflowError("value too large for " + type.getName());

              
//in src/org/python/core/PyArray.java
throw Py.OverflowError("value too small for " + type.getName());

              
//in src/org/python/core/PyArray.java
throw Py.TypeError("Type not compatible with array type");

              
//in src/org/python/core/PyArray.java
throw Py.TypeError("Type not compatible with array type");

              
//in src/org/python/core/PyArray.java
throw Py.TypeError("Type not compatible with array type");

              
//in src/org/python/core/PyArray.java
throw Py.TypeError("Type not compatible with array type");

              
//in src/org/python/core/PyArray.java
throw Py.TypeError("Type not compatible with array type");

              
//in src/org/python/core/PyArray.java
throw Py.ValueError("invalid bounds for setting from string");

              
//in src/org/python/core/PyArray.java
throw Py.ValueError("invalid bounds for setting from string");

              
//in src/org/python/core/PyArray.java
throw Py.TypeError("bad argument type for built-in operation|" + array.typecode + "|" + typecode);

              
//in src/org/python/core/PyArray.java
throw Py.TypeError("Slice typecode '" + array.typecode
                                           + "' is not compatible with this array (typecode '"
                                           + this.typecode + "')");

              
//in src/org/python/core/PyArray.java
throw Py.TypeError(String.format("can only assign array (not \"%.200s\") to array "
                                                 + "slice", value.getType().fastGetName()));

              
//in src/org/python/core/PyArray.java
throw Py.TypeError("arg must be open file");

              
//in src/org/python/core/PyArray.java
throw Py.ValueError("invalid storage");

              
//in src/org/python/core/PyArray.java
throw Py.ValueError("invalid storage");

              
//in src/org/python/core/PyArray.java
throw Py.ValueError("invalid storage");

              
//in src/org/python/core/PyArray.java
throw Py.IOError(e);

              
//in src/org/python/core/PyArray.java
throw Py.ValueError("tounicode() may only be called on type 'u' arrays");

              
//in src/org/python/core/PyClassMethodDescr.java
throw Py.TypeError(String.format("descriptor '%s' for type '%s' needs either an "
                                                 + " object or a type", name, dtype.fastGetName()));

              
//in src/org/python/core/PyClassMethodDescr.java
throw Py.TypeError(String.format("descriptor '%s' for type '%s' needs a type, not a"
                                             + " '%s' as arg 2", name, dtype.fastGetName(),
                                             type.getType().fastGetName()));

              
//in src/org/python/core/PyModuleDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyModuleDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyModuleDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyModuleDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyModuleDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyModuleDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyModuleDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/core/PyModuleDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyModuleDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/core/PyModuleDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/core/PyModuleDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/core/PyModuleDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/core/PyModuleDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/core/PyModuleDerived.java
throw exc;

              
//in src/org/python/core/PyModuleDerived.java
throw exc;

              
//in src/org/python/core/PyModuleDerived.java
throw exc;

              
//in src/org/python/core/PyModuleDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/core/PyModuleDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/core/PyModuleDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/core/PyModuleDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyFileReader.java
throw Py.ValueError("I/O operation on closed file");

              
//in src/org/python/core/PyFileReader.java
throw Py.IOError(e);

              
//in src/org/python/core/PyFileReader.java
throw Py.IOError(e);

              
//in src/org/python/core/PyFileReader.java
throw Py.IOError(e);

              
//in src/org/python/core/PyFileReader.java
throw Py.NotImplementedError("size argument to readline not implemented for PyFileReader");

              
//in src/org/python/core/PyFileReader.java
throw Py.IOError(e);

              
//in src/org/python/core/__builtin__.java
throw info.unexpectedCall(0, false);

              
//in src/org/python/core/__builtin__.java
throw Py.TypeError("ord() expected string of length 1, but " +
                                       arg1.getType().fastGetName() + " found");

              
//in src/org/python/core/__builtin__.java
throw Py.TypeError("reload() argument must be a module");

              
//in src/org/python/core/__builtin__.java
throw info.unexpectedCall(1, false);

              
//in src/org/python/core/__builtin__.java
throw info.unexpectedCall(2, false);

              
//in src/org/python/core/__builtin__.java
throw Py.TypeError("apply() 3rd argument must be a "
                                       + "dictionary with string keys");

              
//in src/org/python/core/__builtin__.java
throw info.unexpectedCall(3, false);

              
//in src/org/python/core/__builtin__.java
throw info.unexpectedCall(4, false);

              
//in src/org/python/core/__builtin__.java
throw info.unexpectedCall(args.length, false);

              
//in src/org/python/core/__builtin__.java
throw Py.TypeError(String.format("keywords must be strings"));

              
//in src/org/python/core/__builtin__.java
throw Py.ValueError("unichr() arg not in range(0x110000)");

              
//in src/org/python/core/__builtin__.java
throw Py.ValueError("chr() arg not in range(256)");

              
//in src/org/python/core/__builtin__.java
throw Py.TypeError("number coercion failed");

              
//in src/org/python/core/__builtin__.java
throw Py.TypeError(String.format("Expected keys() to be a list, not '%s'",
                                             retObj.getType().fastGetName()));

              
//in src/org/python/core/__builtin__.java
throw Py.TypeError("globals must be a mapping");

              
//in src/org/python/core/__builtin__.java
throw Py.TypeError("locals must be a mapping");

              
//in src/org/python/core/__builtin__.java
throw Py.TypeError("eval: argument 1 must be string or code object");

              
//in src/org/python/core/__builtin__.java
throw Py.TypeError("code object passed to eval() may not contain free variables");

              
//in src/org/python/core/__builtin__.java
throw Py.IOError(e);

              
//in src/org/python/core/__builtin__.java
throw Py.IOError(e);

              
//in src/org/python/core/__builtin__.java
throw Py.TypeError(String.format("can't filter %s to %s: __getitem__ returned "
                                                 + "different type", name, name));

              
//in src/org/python/core/__builtin__.java
throw pye;

              
//in src/org/python/core/__builtin__.java
throw attributeError;

              
//in src/org/python/core/__builtin__.java
throw Py.TypeError("intern() argument 1 must be string, not "
                               + obj.getType().fastGetName());

              
//in src/org/python/core/__builtin__.java
throw Py.TypeError("can't intern subclass of string");

              
//in src/org/python/core/__builtin__.java
throw Py.TypeError("map requires at least two arguments");

              
//in src/org/python/core/__builtin__.java
throw Py.TypeError("ord() expected a character, but string of length " +
                           length + " found");

              
//in src/org/python/core/__builtin__.java
throw Py.TypeError(String.format("unsupported operand type(s) for pow(): '%.100s', "
                                         + "'%.100s', '%.100s'", x.getType().fastGetName(),
                                         y.getType().fastGetName(), z.getType().fastGetName()));

              
//in src/org/python/core/__builtin__.java
throw Py.ValueError("range() step argument must not be zero");

              
//in src/org/python/core/__builtin__.java
throw Py.OverflowError("range() result has too many items");

              
//in src/org/python/core/__builtin__.java
throw Py.TypeError(String.format("range() integer start argument expected, got %s.",
                                             ilow.getType().fastGetName()));

              
//in src/org/python/core/__builtin__.java
throw Py.TypeError(String.format("range() integer end argument expected, got %s.",
                                             ihigh.getType().fastGetName()));

              
//in src/org/python/core/__builtin__.java
throw Py.TypeError(String.format("range() integer step argument expected, got %s.",
                                             istep.getType().fastGetName()));

              
//in src/org/python/core/__builtin__.java
throw Py.ValueError("range() step argument must not be zero");

              
//in src/org/python/core/__builtin__.java
throw Py.OverflowError("range() result has too many items");

              
//in src/org/python/core/__builtin__.java
throw Py.TypeError("object.readline() returned non-string");

              
//in src/org/python/core/__builtin__.java
throw Py.RuntimeError("[raw_]input: lost sys.stdout");

              
//in src/org/python/core/__builtin__.java
throw Py.EOFError("raw_input()");

              
//in src/org/python/core/__builtin__.java
throw Py.RuntimeError("[raw_]input: lost sys.stdin");

              
//in src/org/python/core/__builtin__.java
throw Py.TypeError("reduce of empty sequence with no initial value");

              
//in src/org/python/core/__builtin__.java
throw Py.TypeError("sum() can't sum strings [use ''.join(seq) instead]");

              
//in src/org/python/core/__builtin__.java
throw Py.TypeError("argument to reversed() must be a sequence");

              
//in src/org/python/core/__builtin__.java
throw Py.TypeError("vars() argument must have __dict__ attribute");

              
//in src/org/python/core/__builtin__.java
throw e;

              
//in src/org/python/core/__builtin__.java
throw Py.TypeError("zip argument #" + (j + 1) + " must support iteration");

              
//in src/org/python/core/__builtin__.java
throw e;

              
//in src/org/python/core/__builtin__.java
throw Py.TypeError(function + "(): attribute name must be string");

              
//in src/org/python/core/__builtin__.java
throw Py.TypeError("sorted() takes at least 1 argument (0 given)");

              
//in src/org/python/core/__builtin__.java
throw Py.TypeError(String.format("sorted() takes at most 4 arguments (%s given)",
                                             args.length));

              
//in src/org/python/core/__builtin__.java
throw Py.TypeError(String.format("'%s' object is not iterable",
                                                 args[0].getType().fastGetName()));

              
//in src/org/python/core/__builtin__.java
throw Py.TypeError("'" + arg.getType().fastGetName() + "' object is not iterable");

              
//in src/org/python/core/__builtin__.java
throw Py.TypeError("'" + arg.getType().fastGetName() + "' object is not iterable");

              
//in src/org/python/core/__builtin__.java
throw Py.TypeError("max() expected 1 arguments, got 0");

              
//in src/org/python/core/__builtin__.java
throw Py.TypeError("max() got an unexpected keyword argument");

              
//in src/org/python/core/__builtin__.java
throw Py.ValueError("min of empty sequence");

              
//in src/org/python/core/__builtin__.java
throw Py.TypeError("min() expected 1 arguments, got 0");

              
//in src/org/python/core/__builtin__.java
throw Py.TypeError("min() got an unexpected keyword argument");

              
//in src/org/python/core/__builtin__.java
throw Py.ValueError("min of empty sequence");

              
//in src/org/python/core/__builtin__.java
throw Py.TypeError("expected a readable buffer object");

              
//in src/org/python/core/__builtin__.java
throw Py.TypeError("compile() expected string without null bytes");

              
//in src/org/python/core/PyTypeDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyTypeDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyTypeDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyTypeDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyTypeDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyTypeDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyTypeDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/core/PyTypeDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyTypeDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/core/PyTypeDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/core/PyTypeDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/core/PyTypeDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/core/PyTypeDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/core/PyTypeDerived.java
throw exc;

              
//in src/org/python/core/PyTypeDerived.java
throw exc;

              
//in src/org/python/core/PyTypeDerived.java
throw exc;

              
//in src/org/python/core/PyTypeDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/core/PyTypeDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/core/PyTypeDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/core/PyTypeDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/exceptions.java
throw Py.IndexError("tuple index out of range");

              
//in src/org/python/core/exceptions.java
throw Py.TypeError(String.format("%.200s attribute must be str", name));

              
//in src/org/python/core/exceptions.java
throw Py.TypeError(String.format("%.200s attribute must be unicode", name));

              
//in src/org/python/core/exceptions.java
throw Py.JavaError(e);

              
//in src/org/python/core/exceptions.java
throw Py.JavaError(t);

              
//in src/org/python/core/PySetDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/core/PySetDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PySetDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PySetDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PySetDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PySetDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PySetDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PySetDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/core/PySetDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PySetDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/core/PySetDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/core/PySetDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/core/PySetDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/core/PySetDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/core/PySetDerived.java
throw exc;

              
//in src/org/python/core/PySetDerived.java
throw exc;

              
//in src/org/python/core/PySetDerived.java
throw exc;

              
//in src/org/python/core/PySetDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/core/PySetDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/core/PySetDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/core/PySetDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyType.java
throw Py.TypeError("type() takes 1 or 3 arguments");

              
//in src/org/python/core/PyType.java
throw Py.TypeError("type(): argument 3 must be dict, not " + dict.getType());

              
//in src/org/python/core/PyType.java
throw Py.TypeError("type.__init__() takes no keyword arguments");

              
//in src/org/python/core/PyType.java
throw Py.TypeError("type.__init__() takes 1 or 3 arguments");

              
//in src/org/python/core/PyType.java
throw Py.TypeError(String.format("type '%.100s' is not an acceptable base type",
                                             base.name));

              
//in src/org/python/core/PyType.java
throw Py.TypeError("__dict__ slot disallowed: we already got one");

              
//in src/org/python/core/PyType.java
throw Py.TypeError("__weakref__ slot disallowed: we already got one");

              
//in src/org/python/core/PyType.java
throw Py.AttributeError(String.format(writeMsg, "__weakref__",
                                                          obj.getType().fastGetName()));

              
//in src/org/python/core/PyType.java
throw Py.TypeError(String.format("%s assignment: '%s' object layout differs from '%s'",
                                             attribute, other.fastGetName(), fastGetName()));

              
//in src/org/python/core/PyType.java
throw Py.TypeError(String.format(msg, proxy.getName(), baseProxy.getName()));

              
//in src/org/python/core/PyType.java
throw Py.TypeError("Can't delete __bases__ attribute");

              
//in src/org/python/core/PyType.java
throw Py.TypeError("bases must be a tuple");

              
//in src/org/python/core/PyType.java
throw Py.TypeError("can only assign non-empty tuple to __bases__, not "
                               + newBasesTuple);

              
//in src/org/python/core/PyType.java
throw Py.TypeError(name + ".__bases__ must be a tuple of old- or new-style "
                                       + "classes, not " + newBases[i]);

              
//in src/org/python/core/PyType.java
throw Py.TypeError("a __bases__ item causes an inheritance cycle");

              
//in src/org/python/core/PyType.java
throw t;

              
//in src/org/python/core/PyType.java
throw Py.AttributeError("mro");

              
//in src/org/python/core/PyType.java
throw Py.TypeError(String.format("mro() returned a non-class ('%.500s')",
                                                     cls.getType().fastGetName()));

              
//in src/org/python/core/PyType.java
throw Py.TypeError(String.format("mro() returned base with unsuitable layout "
                                                     + "('%.500s')", t.fastGetName()));

              
//in src/org/python/core/PyType.java
throw Py.TypeError("duplicate base class " +
                                       (name == null ? "?" : name.toString()));

              
//in src/org/python/core/PyType.java
throw Py.TypeError(msg.toString());

              
//in src/org/python/core/PyType.java
throw Py.TypeError("bases must be types");

              
//in src/org/python/core/PyType.java
throw Py.TypeError("multiple bases have instance lay-out conflict");

              
//in src/org/python/core/PyType.java
throw Py.TypeError("a new-style class can't have only classic bases");

              
//in src/org/python/core/PyType.java
throw Py.TypeError("metaclass conflict: the metaclass of a derived class must be a "
                               + "(non-strict) subclass of the metaclasses of all its bases");

              
//in src/org/python/core/PyType.java
throw Py.JavaError(e);

              
//in src/org/python/core/PyType.java
throw Py.TypeError(String.format("can't set attributes of built-in/extension type "
                    + "'%s'", this.name));

              
//in src/org/python/core/PyType.java
throw Py.TypeError(String.format("can't set attributes of built-in/extension type "
                    + "'%s'", this.name));

              
//in src/org/python/core/PyType.java
throw Py.TypeError(String.format("cannot create '%.100s' instances", name));

              
//in src/org/python/core/PyType.java
throw Py.TypeError(String.format("can only assign string to %s.__name__, not '%s'",
                                             this.name, name.getType().fastGetName()));

              
//in src/org/python/core/PyType.java
throw Py.ValueError("__name__ must not contain null bytes");

              
//in src/org/python/core/PyType.java
throw Py.TypeError(String.format("can't delete %s.__name__", name));

              
//in src/org/python/core/PyType.java
throw Py.AttributeError(String.format("attribute '__dict__' of '%s' objects is not "
                                              + "writable", getType().fastGetName()));

              
//in src/org/python/core/PyType.java
throw Py.TypeError(String.format("can't delete %s.__module__", name));

              
//in src/org/python/core/PyType.java
throw Py.AttributeError(String.format("type object '%.50s' has no attribute '%.400s'",
                                              fastGetName(), name));

              
//in src/org/python/core/PyType.java
throw Py.TypeError(String.format("__slots__ items must be strings, not '%.200s'",
                                             obj.getType().fastGetName()));

              
//in src/org/python/core/PyType.java
throw Py.TypeError(msg);

              
//in src/org/python/core/PyType.java
throw Py.TypeError(msg);

              
//in src/org/python/core/PyType.java
throw Py.TypeError(module + "." + name + " must be a type for deserialization");

              
//in src/org/python/core/PythonTraceFunction.java
throw exc;

              
//in src/org/python/core/PyJavaType.java
throw Py.TypeError(getName()
                                + " does not have a consistent method resolution order with "
                                + conflict.getName() + ", and it already has " + name
                                + " added for Python");

              
//in src/org/python/core/PyJavaType.java
throw Py.NameError("attribute not found: "+name);

              
//in src/org/python/core/PyJavaType.java
throw Py.TypeError(String.format("Supertypes that share a modified attribute "
                            + " have an MRO conflict[attribute=%s, types=%s]", method, types));

              
//in src/org/python/core/PyJavaType.java
throw Py.JavaError(e);

              
//in src/org/python/core/PyJavaType.java
throw Py.JavaError(exc);

              
//in src/org/python/core/PyJavaType.java
throw Py.TypeError("Could not copy Java object because it is not Cloneable or known to be immutable. "
                            + "Consider monkeypatching __copy__ for " + self.getType().fastGetName());

              
//in src/org/python/core/PyJavaType.java
throw Py.TypeError("Could not deepcopy Java object because it is not Serializable. "
                            + "Consider monkeypatching __deepcopy__ for " + self.getType().fastGetName());

              
//in src/org/python/core/PyJavaType.java
throw Py.TypeError("Could not copy Java object");

              
//in src/org/python/core/PyJavaType.java
throw Py.TypeError("Could not copy Java object");

              
//in src/org/python/core/PyJavaType.java
throw Py.JavaError(e);

              
//in src/org/python/core/PyPropertyDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/core/PyPropertyDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyPropertyDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyPropertyDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyPropertyDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyPropertyDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyPropertyDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyPropertyDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/core/PyPropertyDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyPropertyDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/core/PyPropertyDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/core/PyPropertyDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/core/PyPropertyDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/core/PyPropertyDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/core/PyPropertyDerived.java
throw exc;

              
//in src/org/python/core/PyPropertyDerived.java
throw exc;

              
//in src/org/python/core/PyPropertyDerived.java
throw exc;

              
//in src/org/python/core/PyPropertyDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/core/PyPropertyDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/core/PyPropertyDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/core/PyPropertyDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/CompilerFacade.java
throw ParserFacade.fixParseError(null, t, filename);

              
//in src/org/python/core/Py.java
throw e;

              
//in src/org/python/core/Py.java
throw Py.TypeError("can't convert " + o.__repr__() + " to " +
                    c.getName());

              
//in src/org/python/core/Py.java
throw Py.TypeError("can't convert to: " + s);

              
//in src/org/python/core/Py.java
throw Py.JavaError(e);

              
//in src/org/python/core/Py.java
throw JavaError(e);

              
//in src/org/python/core/Py.java
throw JavaError(e);

              
//in src/org/python/core/Py.java
throw Py.TypeError("Proxy instance reused");

              
//in src/org/python/core/Py.java
throw e;

              
//in src/org/python/core/Py.java
throw Py.TypeError("code object passed to exec may not contain free variables");

              
//in src/org/python/core/Py.java
throw Py.TypeError(
                        "exec: argument 1 must be string, code or file object");

              
//in src/org/python/core/Py.java
throw Py.TypeError("integer required");

              
//in src/org/python/core/Py.java
throw Py.TypeError("integer required");

              
//in src/org/python/core/Py.java
throw Py.TypeError(msg);

              
//in src/org/python/core/Py.java
throw Py.TypeError("integer required");

              
//in src/org/python/core/Py.java
throw Py.TypeError("float required");

              
//in src/org/python/core/Py.java
throw Py.TypeError("float required");

              
//in src/org/python/core/Py.java
throw Py.TypeError(msg);

              
//in src/org/python/core/Py.java
throw Py.TypeError(msg);

              
//in src/org/python/core/Py.java
throw Py.TypeError("None required for void return");

              
//in src/org/python/core/Py.java
throw pye;

              
//in src/org/python/core/Py.java
throw pye;

              
//in src/org/python/core/Py.java
throw Py.TypeError("compile() expected string without null bytes");

              
//in src/org/python/core/Py.java
throw Py.ValueError(String.format("need more than %d value%s to unpack", i,
                                                  i == 1 ? "" : "s"));

              
//in src/org/python/core/Py.java
throw Py.ValueError("too many values to unpack");

              
//in src/org/python/core/Py.java
throw Py.TypeError(message);

              
//in src/org/python/core/Py.java
throw exc;

              
//in src/org/python/core/Py.java
throw Py.TypeError(message);

              
//in src/org/python/core/Py.java
throw Py.JavaError(t);

              
//in src/org/python/core/Py.java
throw Py.TypeError("java function not settable: " + method.getName());

              
//in src/org/python/core/PyNewWrapper.java
throw Py.SystemError("__new__ wrappers are already bound");

              
//in src/org/python/core/PyNewWrapper.java
throw Py.TypeError(for_type.fastGetName() + ".__new__(): not enough arguments");

              
//in src/org/python/core/PyNewWrapper.java
throw Py.TypeError(for_type.fastGetName() + ".__new__(X): X is not a type object ("
                    + arg0.getType().fastGetName() + ")");

              
//in src/org/python/core/PyNewWrapper.java
throw Py.TypeError(for_type.fastGetName() + ".__new__(" + subtype.fastGetName() + "): "
                    + subtype.fastGetName() + " is not a subtype of " + for_type.fastGetName());

              
//in src/org/python/core/PyNewWrapper.java
throw Py.TypeError(for_type.fastGetName() + ".__new__(" + subtype.fastGetName()
                    + ") is not safe, use " + subtype.fastGetName() + ".__new__()");

              
//in src/org/python/core/PySequenceIter.java
throw exc;

              
//in src/org/python/core/CompilerFlags.java
throw Py.ValueError("compile(): unrecognised flags");

              
//in src/org/python/core/PyFileDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/core/PyFileDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyFileDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyFileDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyFileDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyFileDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyFileDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyFileDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/core/PyFileDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyFileDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/core/PyFileDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/core/PyFileDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/core/PyFileDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/core/PyFileDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/core/PyFileDerived.java
throw exc;

              
//in src/org/python/core/PyFileDerived.java
throw exc;

              
//in src/org/python/core/PyFileDerived.java
throw exc;

              
//in src/org/python/core/PyFileDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/core/PyFileDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/core/PyFileDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/core/PyFileDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PySequence.java
throw Py.TypeError("can't assign to immutable object");

              
//in src/org/python/core/PySequence.java
throw Py.TypeError(String.format("'%s' object does not support item assignment",
                                         getType().fastGetName()));

              
//in src/org/python/core/PySequence.java
throw Py.TypeError(String.format("'%s' object does not support item deletion",
                                         getType().fastGetName()));

              
//in src/org/python/core/PySequence.java
throw Py.TypeError(String.format("'%s' object does not support item deletion",
                                         getType().fastGetName()));

              
//in src/org/python/core/PyCallIter.java
throw Py.TypeError("iter(v, w): v must be callable");

              
//in src/org/python/core/PyCallIter.java
throw exc;

              
//in src/org/python/core/PyFunction.java
throw Py.TypeError("function() argument 1 must be code, not " +
                               code.getType().fastGetName());

              
//in src/org/python/core/PyFunction.java
throw Py.TypeError("arg 3 (name) must be None or string");

              
//in src/org/python/core/PyFunction.java
throw Py.TypeError("arg 4 (defaults) must be None or tuple");

              
//in src/org/python/core/PyFunction.java
throw Py.TypeError("arg 5 (closure) must be tuple");

              
//in src/org/python/core/PyFunction.java
throw Py.TypeError("arg 5 (closure) must be None or tuple");

              
//in src/org/python/core/PyFunction.java
throw Py.ValueError(String.format("%s requires closure of length %d, not %d",
                                              tcode.co_name, nfree, nclosure));

              
//in src/org/python/core/PyFunction.java
throw Py.TypeError(String.format("arg 5 (closure) expected cell, found %s",
                                                     o.getType().fastGetName()));

              
//in src/org/python/core/PyFunction.java
throw Py.TypeError("func_defaults must be set to a tuple object");

              
//in src/org/python/core/PyFunction.java
throw Py.TypeError("func_code must be set to a code object");

              
//in src/org/python/core/PyFunction.java
throw Py.ValueError(String.format("%s() requires a code object with %d free vars,"
                                              + " not %d", __name__, nclosure, nfree));

              
//in src/org/python/core/PyFunction.java
throw Py.TypeError("setting function's dictionary to a non-dict");

              
//in src/org/python/core/PyFunction.java
throw Py.TypeError("function's dictionary may not be deleted");

              
//in src/org/python/core/PyFunction.java
throw Py.TypeError("readonly attribute");

              
//in src/org/python/core/PyFunction.java
throw Py.TypeError("readonly attribute");

              
//in src/org/python/core/PyListDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/core/PyListDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyListDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyListDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyListDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyListDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyListDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyListDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/core/PyListDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyListDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/core/PyListDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/core/PyListDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/core/PyListDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/core/PyListDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/core/PyListDerived.java
throw exc;

              
//in src/org/python/core/PyListDerived.java
throw exc;

              
//in src/org/python/core/PyListDerived.java
throw exc;

              
//in src/org/python/core/PyListDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/core/PyListDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/core/PyListDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/core/PyListDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/Options.java
throw Py.ValueError("Illegal verbose option setting: '" + prop
                        + "'");

              
//in src/org/python/core/Options.java
throw Py.ValueError("Illegal divisionWarning option "
                        + "setting: '" + prop + "'");

              
//in src/org/python/core/PyXRange.java
throw Py.ValueError("xrange() arg 3 must not be zero");

              
//in src/org/python/core/PyXRange.java
throw Py.OverflowError("xrange() result has too many items");

              
//in src/org/python/core/PyXRange.java
throw Py.IndexError("xrange object index out of range");

              
//in src/org/python/core/PyFrozenSetDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/core/PyFrozenSetDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyFrozenSetDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyFrozenSetDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyFrozenSetDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyFrozenSetDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyFrozenSetDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyFrozenSetDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/core/PyFrozenSetDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyFrozenSetDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/core/PyFrozenSetDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/core/PyFrozenSetDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/core/PyFrozenSetDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/core/PyFrozenSetDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/core/PyFrozenSetDerived.java
throw exc;

              
//in src/org/python/core/PyFrozenSetDerived.java
throw exc;

              
//in src/org/python/core/PyFrozenSetDerived.java
throw exc;

              
//in src/org/python/core/PyFrozenSetDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/core/PyFrozenSetDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/core/PyFrozenSetDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/core/PyFrozenSetDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyModule.java
throw Py.TypeError("readonly attribute");

              
//in src/org/python/core/PyModule.java
throw Py.TypeError("readonly attribute");

              
//in src/org/python/core/PyModule.java
throw Py.TypeError("__path__ must be list or None");

              
//in src/org/python/core/PyModule.java
throw Py.TypeError("module.__dict__ is not a dictionary");

              
//in src/org/python/core/ParserFacade.java
throw Py.SyntaxError(msg);

              
//in src/org/python/core/ParserFacade.java
throw Py.JavaError(t);

              
//in src/org/python/core/ParserFacade.java
throw fixParseError(bufReader, tt, filename);

              
//in src/org/python/core/ParserFacade.java
throw Py.ValueError("parse kind must be eval, exec, or single");

              
//in src/org/python/core/ParserFacade.java
throw fixParseError(bufReader, t, filename);

              
//in src/org/python/core/ParserFacade.java
throw fixParseError(bufReader, t, filename);

              
//in src/org/python/core/ParserFacade.java
throw fixParseError(bufReader, t, filename);

              
//in src/org/python/core/ParserFacade.java
throw p;

              
//in src/org/python/core/PyDictionaryDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/core/PyDictionaryDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyDictionaryDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyDictionaryDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyDictionaryDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyDictionaryDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyDictionaryDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyDictionaryDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/core/PyDictionaryDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyDictionaryDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/core/PyDictionaryDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/core/PyDictionaryDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/core/PyDictionaryDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/core/PyDictionaryDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/core/PyDictionaryDerived.java
throw exc;

              
//in src/org/python/core/PyDictionaryDerived.java
throw exc;

              
//in src/org/python/core/PyDictionaryDerived.java
throw exc;

              
//in src/org/python/core/PyDictionaryDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/core/PyDictionaryDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/core/PyDictionaryDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/core/PyDictionaryDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/AnnotationReader.java
throw ioe;

              
//in src/org/python/core/PyBuiltinFunction.java
throw Py.TypeError("Can't bind a builtin function");

              
//in src/org/python/core/PyBytecode.java
throw Py.TypeError("readonly attribute");

              
//in src/org/python/core/PyBytecode.java
throw Py.AttributeError(name);

              
//in src/org/python/core/PyBytecode.java
throw Py.SystemError("");

              
//in src/org/python/core/PyBytecode.java
throw (PyException) generatorInput;

              
//in src/org/python/core/PyBytecode.java
throw Py.RuntimeError("invalid argument to DUP_TOPX" +
                                    " (bytecode corruption?)");

              
//in src/org/python/core/PyBytecode.java
throw PyException.doRaise(type, value, tb);

              
//in src/org/python/core/PyBytecode.java
throw PyException.doRaise(type, value, null);

              
//in src/org/python/core/PyBytecode.java
throw PyException.doRaise(type, null, null);

              
//in src/org/python/core/PyBytecode.java
throw PyException.doRaise(null, null, null);

              
//in src/org/python/core/PyBytecode.java
throw Py.SystemError("bad RAISE_VARARGS oparg");

              
//in src/org/python/core/PyBytecode.java
throw Py.SystemError("'finally' pops bad exception");

              
//in src/org/python/core/PyBytecode.java
throw Py.ImportError("__import__ not found");

              
//in src/org/python/core/PyBytecode.java
throw Py.ImportError(String.format("cannot import name %.230s", name));

              
//in src/org/python/core/PyBytecode.java
throw pye;

              
//in src/org/python/core/PyBytecode.java
throw pye;

              
//in src/org/python/core/PyBytecode.java
throw Py.SystemError("unknown opcode");

              
//in src/org/python/core/PyBytecode.java
throw ts.exception;

              
//in src/org/python/core/PyBytecode.java
throw Py.ValueError("too many values to unpack");

              
//in src/org/python/core/PyBytecode.java
throw Py.ValueError(String.format("need more than %d value%s to unpack",
                    i, i == 1 ? "" : "s"));

              
//in src/org/python/core/PyStringDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/core/PyStringDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyStringDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyStringDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyStringDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyStringDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyStringDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyStringDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/core/PyStringDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyStringDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/core/PyStringDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/core/PyStringDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/core/PyStringDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/core/PyStringDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/core/PyStringDerived.java
throw exc;

              
//in src/org/python/core/PyStringDerived.java
throw exc;

              
//in src/org/python/core/PyStringDerived.java
throw exc;

              
//in src/org/python/core/PyStringDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/core/PyStringDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/core/PyStringDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/core/PyBuiltinMethodSet.java
throw Py.TypeError(String.format("descriptor '%s' for '%s' objects doesn't apply "
                                                 + "to '%s' object", info.getName(),
                                                 PyType.fromClass(this.type), obj.getType()));

              
//in src/org/python/core/ThreadState.java
throw Py.RuntimeError("invalid initializing proxies state");

              
//in src/org/python/core/ThreadState.java
throw Py.RuntimeError("maximum recursion depth exceeded" + where);

              
//in src/org/python/core/codecs.java
throw Py.TypeError("argument must be callable");

              
//in src/org/python/core/codecs.java
throw Py.TypeError("argument must be callable");

              
//in src/org/python/core/codecs.java
throw Py.TypeError("codec search functions must return 4-tuples");

              
//in src/org/python/core/codecs.java
throw exc;

              
//in src/org/python/core/codecs.java
throw ex;

              
//in src/org/python/core/codecs.java
throw Py.TypeError("decoder must return a tuple (object,integer)");

              
//in src/org/python/core/codecs.java
throw ex;

              
//in src/org/python/core/codecs.java
throw Py.TypeError("encoder must return a tuple (object,integer)");

              
//in src/org/python/core/codecs.java
throw Py.TypeError("encoder did not return a string/unicode object (type="
                    + encoded.getType().fastGetName() + ")");

              
//in src/org/python/core/codecs.java
throw wrong_exception_type(exc);

              
//in src/org/python/core/codecs.java
throw wrong_exception_type(exc);

              
//in src/org/python/core/codecs.java
throw wrong_exception_type(exc);

              
//in src/org/python/core/codecs.java
throw wrong_exception_type(exc);

              
//in src/org/python/core/codecs.java
throw wrong_exception_type(exc);

              
//in src/org/python/core/codecs.java
throw Py.UnicodeEncodeError(encoding, str, i + j, i + j + 1, reason);

              
//in src/org/python/core/codecs.java
throw Py.IndexError(newPosition + " out of bounds of encoded string");

              
//in src/org/python/core/codecs.java
throw Py.UnicodeEncodeError("punycode", input.getString(), codePointIndex, codePointIndex + 1, "overflow");

              
//in src/org/python/core/codecs.java
throw Py.UnicodeEncodeError("punycode", input.getString(), i, i + 1, "overflow");

              
//in src/org/python/core/codecs.java
throw Py.UnicodeDecodeError("punycode", input, j, j + 1, "not basic");

              
//in src/org/python/core/codecs.java
throw Py.UnicodeDecodeError("punycode", input, j, j + 1, "overflow");

              
//in src/org/python/core/codecs.java
throw Py.UnicodeDecodeError("punycode", input, j, j + 1, "overflow");

              
//in src/org/python/core/PyException.java
throw Py.TypeError("raise: arg 3 must be a traceback or None");

              
//in src/org/python/core/PyException.java
throw Py.TypeError("instance exception may not have a separate value");

              
//in src/org/python/core/PyException.java
throw Py.TypeError("exceptions must be old-style classes or derived from "
                               + "BaseException, not " + type.getType().fastGetName());

              
//in src/org/python/core/PyCell.java
throw Py.ValueError("Cell is empty");

              
//in src/org/python/core/BaseSet.java
throw Py.RuntimeError("set changed size during iteration");

              
//in src/org/python/core/BaseSet.java
throw Py.TypeError("cannot compare sets using cmp()");

              
//in src/org/python/core/BaseSet.java
throw Py.TypeError("can only compare to a set");

              
//in src/org/python/core/BaseSet.java
throw pye;

              
//in src/org/python/core/PyInteger.java
throw Py.TypeError("int: can't convert non-string with explicit base");

              
//in src/org/python/core/PyInteger.java
throw pye;

              
//in src/org/python/core/PyInteger.java
throw Py.OverflowError("long int too large to convert to int");

              
//in src/org/python/core/PyInteger.java
throw Py.TypeError("int: can't convert non-string with explicit base");

              
//in src/org/python/core/PyInteger.java
throw pye;

              
//in src/org/python/core/PyInteger.java
throw Py.TypeError("int() argument must be a string or a number");

              
//in src/org/python/core/PyInteger.java
throw Py.TypeError("xxx");

              
//in src/org/python/core/PyInteger.java
throw Py.ZeroDivisionError("integer division or modulo by zero");

              
//in src/org/python/core/PyInteger.java
throw Py.ZeroDivisionError("cannot raise 0 to a negative power");

              
//in src/org/python/core/PyInteger.java
throw Py.ValueError("pow(x, y, z) with z==0");

              
//in src/org/python/core/PyInteger.java
throw Py.ValueError("negative shift count");

              
//in src/org/python/core/PyInteger.java
throw Py.ValueError("negative shift count");

              
//in src/org/python/core/PyInteger.java
throw Py.ValueError("negative shift count");

              
//in src/org/python/core/PyInteger.java
throw Py.ValueError("negative shift count");

              
//in src/org/python/core/PyInteger.java
throw Py.TypeError("__format__ requires str or unicode");

              
//in src/org/python/core/PyInteger.java
throw Py.ValueError(e.getMessage());

              
//in src/org/python/core/PyObjectDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/core/PyObjectDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyObjectDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyObjectDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyObjectDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyObjectDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyObjectDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyObjectDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/core/PyObjectDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyObjectDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/core/PyObjectDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/core/PyObjectDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/core/PyObjectDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/core/PyObjectDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/core/PyObjectDerived.java
throw exc;

              
//in src/org/python/core/PyObjectDerived.java
throw exc;

              
//in src/org/python/core/PyObjectDerived.java
throw exc;

              
//in src/org/python/core/PyObjectDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/core/PyObjectDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/core/PyObjectDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/core/PyObjectDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyComplexDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/core/PyComplexDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyComplexDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyComplexDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyComplexDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyComplexDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyComplexDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyComplexDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/core/PyComplexDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyComplexDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/core/PyComplexDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/core/PyComplexDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/core/PyComplexDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/core/PyComplexDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/core/PyComplexDerived.java
throw exc;

              
//in src/org/python/core/PyComplexDerived.java
throw exc;

              
//in src/org/python/core/PyComplexDerived.java
throw exc;

              
//in src/org/python/core/PyComplexDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/core/PyComplexDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/core/PyComplexDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/core/PyComplexDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyLong.java
throw pye;

              
//in src/org/python/core/PyLong.java
throw Py.TypeError(String.format("long() argument must be a string or a number, "
                                                 + "not '%.200s'", x.getType().fastGetName()));

              
//in src/org/python/core/PyLong.java
throw Py.TypeError("long: can't convert non-string with explicit base");

              
//in src/org/python/core/PyLong.java
throw Py.OverflowError("cannot convert float infinity to long");

              
//in src/org/python/core/PyLong.java
throw Py.OverflowError("long int too large to convert to float");

              
//in src/org/python/core/PyLong.java
throw Py.OverflowError(overflowMsg);

              
//in src/org/python/core/PyLong.java
throw Py.TypeError("xxx");

              
//in src/org/python/core/PyLong.java
throw Py.ZeroDivisionError("long division or modulo");

              
//in src/org/python/core/PyLong.java
throw Py.ZeroDivisionError("long division or modulo");

              
//in src/org/python/core/PyLong.java
throw Py.OverflowError("long/long too large for a float");

              
//in src/org/python/core/PyLong.java
throw Py.OverflowError("long/long too large for a float");

              
//in src/org/python/core/PyLong.java
throw Py.ZeroDivisionError("zero to a negative power");

              
//in src/org/python/core/PyLong.java
throw Py.ValueError("pow(x, y, z) with z == 0");

              
//in src/org/python/core/PyLong.java
throw Py.TypeError("xxx");

              
//in src/org/python/core/PyLong.java
throw Py.ValueError("negative shift count");

              
//in src/org/python/core/PyLong.java
throw Py.ValueError("negative shift count");

              
//in src/org/python/core/PyLong.java
throw Py.ValueError("negative shift count");

              
//in src/org/python/core/PyLong.java
throw Py.ValueError("negative shift count");

              
//in src/org/python/core/PyClassMethodDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/core/PyClassMethodDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyClassMethodDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyClassMethodDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyClassMethodDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyClassMethodDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyClassMethodDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyClassMethodDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/core/PyClassMethodDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyClassMethodDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/core/PyClassMethodDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/core/PyClassMethodDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/core/PyClassMethodDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/core/PyClassMethodDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/core/PyClassMethodDerived.java
throw exc;

              
//in src/org/python/core/PyClassMethodDerived.java
throw exc;

              
//in src/org/python/core/PyClassMethodDerived.java
throw exc;

              
//in src/org/python/core/PyClassMethodDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/core/PyClassMethodDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/core/PyClassMethodDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/core/PyClassMethodDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyBuiltinFunctionNarrow.java
throw info.unexpectedCall(args.length, false);

              
//in src/org/python/core/PyBuiltinFunctionNarrow.java
throw Py.TypeError(fastGetName() + "() takes no keyword arguments");

              
//in src/org/python/core/PyBuiltinFunctionNarrow.java
throw info.unexpectedCall(0, false);

              
//in src/org/python/core/PyBuiltinFunctionNarrow.java
throw info.unexpectedCall(1, false);

              
//in src/org/python/core/PyBuiltinFunctionNarrow.java
throw info.unexpectedCall(2, false);

              
//in src/org/python/core/PyBuiltinFunctionNarrow.java
throw info.unexpectedCall(3, false);

              
//in src/org/python/core/PyBuiltinFunctionNarrow.java
throw info.unexpectedCall(4, false);

              
//in src/org/python/core/PyMethod.java
throw Py.TypeError("first argument must be callable");

              
//in src/org/python/core/PyMethod.java
throw Py.TypeError("unbound methods must have non-NULL im_class");

              
//in src/org/python/core/PyMethod.java
throw Py.TypeError(msg);

              
//in src/org/python/core/ClasspathPyImporter.java
throw Py.ImportError("path isn't for classpath importer");

              
//in src/org/python/core/ClasspathPyImporter.java
throw Py.JavaError(e);

              
//in src/org/python/core/CompileMode.java
throw Py.ValueError("compile() arg 3 must be 'exec' or 'eval' or 'single'");

              
//in src/org/python/core/PyTupleDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
//in src/org/python/core/PyTupleDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyTupleDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyTupleDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyTupleDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyTupleDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyTupleDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyTupleDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/core/PyTupleDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyTupleDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/core/PyTupleDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/core/PyTupleDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/core/PyTupleDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/core/PyTupleDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/core/PyTupleDerived.java
throw exc;

              
//in src/org/python/core/PyTupleDerived.java
throw exc;

              
//in src/org/python/core/PyTupleDerived.java
throw exc;

              
//in src/org/python/core/PyTupleDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/core/PyTupleDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/core/PyTupleDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/core/PyTupleDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyString.java
throw Py.UnicodeError("Unicode names not loaded");

              
//in src/org/python/core/PyString.java
throw Py.IndexError("string index out of range");

              
//in src/org/python/core/PyString.java
throw Py.TypeError("'in <string>' requires string as left operand");

              
//in src/org/python/core/PyString.java
throw Py.OverflowError("max str len is " + Integer.MAX_VALUE);

              
//in src/org/python/core/PyString.java
throw e;

              
//in src/org/python/core/PyString.java
throw Py.TypeError("bad operand type for unary +");

              
//in src/org/python/core/PyString.java
throw Py.TypeError("bad operand type for unary -");

              
//in src/org/python/core/PyString.java
throw Py.TypeError("bad operand type for unary ~");

              
//in src/org/python/core/PyString.java
throw Py.ValueError("empty string for complex()");

              
//in src/org/python/core/PyString.java
throw Py.ValueError(String.format("float() out of range: %.150s", getString()));

              
//in src/org/python/core/PyString.java
throw Py.ValueError("malformed string for complex() " +
                                getString().substring(s));

              
//in src/org/python/core/PyString.java
throw Py.ValueError("empty separator");

              
//in src/org/python/core/PyString.java
throw Py.ValueError("empty separator");

              
//in src/org/python/core/PyString.java
throw Py.TypeError("expected a character buffer object");

              
//in src/org/python/core/PyString.java
throw Py.ValueError("empty separator");

              
//in src/org/python/core/PyString.java
throw Py.ValueError("empty separator");

              
//in src/org/python/core/PyString.java
throw Py.TypeError("expected a character buffer object");

              
//in src/org/python/core/PyString.java
throw Py.ValueError("empty separator");

              
//in src/org/python/core/PyString.java
throw Py.ValueError("empty separator");

              
//in src/org/python/core/PyString.java
throw Py.ValueError("substring not found in string.index");

              
//in src/org/python/core/PyString.java
throw Py.ValueError("substring not found in string.rindex");

              
//in src/org/python/core/PyString.java
throw Py.ValueError("null byte in argument for float()");

              
//in src/org/python/core/PyString.java
throw Py.ValueError("invalid literal for __float__: "+getString());

              
//in src/org/python/core/PyString.java
throw Py.ValueError("invalid base for atoi()");

              
//in src/org/python/core/PyString.java
throw Py.OverflowError("long int too large to convert to int");

              
//in src/org/python/core/PyString.java
throw Py.ValueError("invalid literal for int() with base " + base + ": " + getString());

              
//in src/org/python/core/PyString.java
throw Py.ValueError("invalid literal for int() with base " + base + ": " + getString());

              
//in src/org/python/core/PyString.java
throw Py.ValueError("invalid base for long literal:" + base);

              
//in src/org/python/core/PyString.java
throw Py.UnicodeEncodeError("decimal", "codec can't encode character",
                        0,0, "invalid decimal Unicode string");

              
//in src/org/python/core/PyString.java
throw Py.ValueError("invalid literal for long() with base " + base + ": " + getString());

              
//in src/org/python/core/PyString.java
throw Py.ValueError("invalid literal for long() with base " + base + ": " + getString());

              
//in src/org/python/core/PyString.java
throw Py.TypeError(function + "() argument 2 must be char, not str");

              
//in src/org/python/core/PyString.java
throw Py.TypeError("str or unicode required for replace");

              
//in src/org/python/core/PyString.java
throw Py.TypeError(String.format("sequence item %d: expected string, %.80s found",
                                                 i, item.getType().fastGetName()));

              
//in src/org/python/core/PyString.java
throw Py.OverflowError("join() result is too long for a Python string");

              
//in src/org/python/core/PyString.java
throw Py.TypeError(String.format("sequence item %d: expected string or Unicode,"
                                                 + " %.80s found",
                                                 i, item.getType().fastGetName()));

              
//in src/org/python/core/PyString.java
throw Py.OverflowError("join() result is too long for a Python string");

              
//in src/org/python/core/PyString.java
throw Py.TypeError("expected a character buffer object");

              
//in src/org/python/core/PyString.java
throw Py.TypeError("expected a character buffer object or tuple");

              
//in src/org/python/core/PyString.java
throw Py.TypeError("expected a character buffer object");

              
//in src/org/python/core/PyString.java
throw Py.TypeError("expected a character buffer object or tuple");

              
//in src/org/python/core/PyString.java
throw Py.ValueError(
                "translation table must be 256 characters long");

              
//in src/org/python/core/PyString.java
throw Py.TypeError(
                    "translate() only works for 8-bit character strings");

              
//in src/org/python/core/PyString.java
throw Py.TypeError(
                     "character mapping must return integer, " +
                     "None or unicode");

              
//in src/org/python/core/PyString.java
throw Py.ValueError(e.getMessage());

              
//in src/org/python/core/PyString.java
throw Py.ValueError("Unknown conversion specifier " + chunk.conversion);

              
//in src/org/python/core/PyString.java
throw Py.IndexError("tuple index out of range");

              
//in src/org/python/core/PyString.java
throw Py.KeyError((String) head);

              
//in src/org/python/core/PyString.java
throw Py.TypeError("__format__ requires str or unicode");

              
//in src/org/python/core/PyString.java
throw Py.ValueError(e.getMessage());

              
//in src/org/python/core/PyString.java
throw Py.TypeError(description + " is required");

              
//in src/org/python/core/PyString.java
throw Py.ValueError("incomplete format");

              
//in src/org/python/core/PyString.java
throw Py.TypeError("not enough arguments for format string");

              
//in src/org/python/core/PyString.java
throw Py.TypeError("* wants int");

              
//in src/org/python/core/PyString.java
throw Py.OverflowError("formatted " + type + " is too long (precision too long?)");

              
//in src/org/python/core/PyString.java
throw Py.TypeError("int argument required");

              
//in src/org/python/core/PyString.java
throw e;

              
//in src/org/python/core/PyString.java
throw !pye.match(Py.TypeError) ? pye : Py.TypeError("float argument required");

              
//in src/org/python/core/PyString.java
throw Py.TypeError("format requires a mapping");

              
//in src/org/python/core/PyString.java
throw Py.TypeError("int argument required");

              
//in src/org/python/core/PyString.java
throw Py.TypeError("int argument required");

              
//in src/org/python/core/PyString.java
throw Py.TypeError("int argument required");

              
//in src/org/python/core/PyString.java
throw Py.TypeError("int argument required");

              
//in src/org/python/core/PyString.java
throw Py.TypeError("%c requires int or char");

              
//in src/org/python/core/PyString.java
throw Py.TypeError("%c requires int or char");

              
//in src/org/python/core/PyString.java
throw e;

              
//in src/org/python/core/PyString.java
throw Py.OverflowError("unsigned byte integer is less than minimum");

              
//in src/org/python/core/PyString.java
throw Py.OverflowError("unsigned byte integer is greater than maximum");

              
//in src/org/python/core/PyString.java
throw Py.OverflowError("%c arg not in range(0x110000) (wide Python build)");

              
//in src/org/python/core/PyString.java
throw Py.ValueError("unsupported format character '" +
                         codecs.encode(Py.newString(c), null, "replace") +
                         "' (0x" + Integer.toHexString(c) + ") at index " +
                         (index-1));

              
//in src/org/python/core/PyString.java
throw Py.TypeError("not all arguments converted during string formatting");

              
//in src/org/python/core/imp.java
throw pye;

              
//in src/org/python/core/imp.java
throw Py.IOError(ioe);

              
//in src/org/python/core/imp.java
throw Py.IOError(e);

              
//in src/org/python/core/imp.java
throw Py.IOError(ioe);

              
//in src/org/python/core/imp.java
throw Py.ImportError(ioe.getMessage() + "[name=" + name + ", source=" + sourceName
                        + ", compiled=" + compiledName + "]");

              
//in src/org/python/core/imp.java
throw Py.JavaError(t);

              
//in src/org/python/core/imp.java
throw Py.ImportError("invalid api version(" + api + " != "
                        + APIVersion + ") in: " + name);

              
//in src/org/python/core/imp.java
throw ParserFacade.fixParseError(null, t, filename);

              
//in src/org/python/core/imp.java
throw t;

              
//in src/org/python/core/imp.java
throw Py.JavaError(e);

              
//in src/org/python/core/imp.java
throw Py.JavaError(e);

              
//in src/org/python/core/imp.java
throw e;

              
//in src/org/python/core/imp.java
throw Py.ImportError("Cannot import " + name
                            + ", missing class " + c.getName());

              
//in src/org/python/core/imp.java
throw Py.ValueError("Attempted relative import in non-package");

              
//in src/org/python/core/imp.java
throw Py.ValueError("Attempted relative import beyond toplevel package");

              
//in src/org/python/core/imp.java
throw Py.ImportError("No module named " + name);

              
//in src/org/python/core/imp.java
throw Py.ImportError("No module named " + name);

              
//in src/org/python/core/imp.java
throw Py.ImportError("No module named " + name);

              
//in src/org/python/core/imp.java
throw Py.ValueError("Empty module name");

              
//in src/org/python/core/imp.java
throw Py.ImportError("cannot import name " + names[i]);

              
//in src/org/python/core/imp.java
throw Py.ImportError("reload(): module " + name
                    + " not in sys.modules");

              
//in src/org/python/core/imp.java
throw Py.ImportError("reload(): parent not in sys.modules");

              
//in src/org/python/core/ClasspathPyImporterDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/ClasspathPyImporterDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/ClasspathPyImporterDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/ClasspathPyImporterDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/ClasspathPyImporterDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/ClasspathPyImporterDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/ClasspathPyImporterDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
//in src/org/python/core/ClasspathPyImporterDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/ClasspathPyImporterDerived.java
throw Py.TypeError("__hash__ should return a int");

              
//in src/org/python/core/ClasspathPyImporterDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
//in src/org/python/core/ClasspathPyImporterDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
//in src/org/python/core/ClasspathPyImporterDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
//in src/org/python/core/ClasspathPyImporterDerived.java
throw Py.TypeError("__len__ should return a int");

              
//in src/org/python/core/ClasspathPyImporterDerived.java
throw exc;

              
//in src/org/python/core/ClasspathPyImporterDerived.java
throw exc;

              
//in src/org/python/core/ClasspathPyImporterDerived.java
throw exc;

              
//in src/org/python/core/ClasspathPyImporterDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
//in src/org/python/core/ClasspathPyImporterDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
//in src/org/python/core/ClasspathPyImporterDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
//in src/org/python/core/ClasspathPyImporterDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
//in src/org/python/core/PyGenerator.java
throw Py.StopIteration("");

              
//in src/org/python/core/PyGenerator.java
throw Py.TypeError("can't send non-None value to a just-started generator");

              
//in src/org/python/core/PyGenerator.java
throw Py.TypeError("throw() third argument must be a traceback object");

              
//in src/org/python/core/PyGenerator.java
throw Py.RuntimeError("generator ignored GeneratorExit");

              
//in src/org/python/core/PyGenerator.java
throw e;

              
//in src/org/python/core/PyGenerator.java
throw ex;

              
//in src/org/python/core/PyGenerator.java
throw Py.ValueError("generator already executing");

              
//in src/org/python/core/PyGenerator.java
throw pye;

              
//in src/org/python/core/util/StringUtil.java
throw Py.SystemError("Java couldn't find the ISO-8859-1 encoding");

              
//in src/org/python/core/util/importer.java
throw Py.ImportError(ioe.getMessage() + "[path=" + fullSearchPath + "]");

              
//in src/org/python/core/Deriveds.java
throw Py.TypeError(String.format("__init__() should return None, not '%.200s'",
                                             result.getType().fastGetName()));

              
//in src/org/python/core/Deriveds.java
throw Py.SystemError(String.format("__getattribute__ not found on type %s",
                                                       type.getName()));

              
//in src/org/python/core/Deriveds.java
throw pye;

              
//in src/org/python/core/Deriveds.java
throw firstAttributeError;

              
//in src/org/python/util/InteractiveInterpreter.java
throw exc;

              
//in src/org/python/util/InteractiveInterpreter.java
throw exc;

              
//in src/org/python/util/PythonObjectInputStream.java
throw exc;

              
//in src/org/python/util/InteractiveConsole.java
throw exc;

              
//in src/org/python/util/JLineConsole.java
throw Py.IOError(ioe);

              
//in src/org/python/util/JLineConsole.java
throw Py.IOError(e.getMessage());

              
//in src/org/python/util/JLineConsole.java
throw Py.EOFError("");

              
//in src/org/python/util/jython.java
throw Py.ValueError("jar file missing '__run__.py'");

              
//in src/org/python/util/jython.java
throw Py.IOError(e);

              
//in src/org/python/util/jython.java
throw Py.IOError(e);

            
- -
- Builder 3401
              
// in src/com/ziclix/python/sql/Fetch.java
throw zxJDBC.makeException(e);

              
// in src/com/ziclix/python/sql/Fetch.java
throw zxJDBC.makeException(e);

              
// in src/com/ziclix/python/sql/Fetch.java
throw zxJDBC.makeException(zxJDBC.DatabaseError, "no results");

              
// in src/com/ziclix/python/sql/Fetch.java
throw zxJDBC.makeException(zxJDBC.ProgrammingError, "invalid cursor scroll mode ["
                                       + mode + "]");

              
// in src/com/ziclix/python/sql/Fetch.java
throw zxJDBC.makeException(Py.IndexError, "cursor index [" + pos + "] out of range");

              
// in src/com/ziclix/python/sql/Fetch.java
throw zxJDBC.makeException(zxJDBC.getString("onlyOneResultSet"));

              
// in src/com/ziclix/python/sql/Fetch.java
throw zxJDBC.makeException(e);

              
// in src/com/ziclix/python/sql/Fetch.java
throw zxJDBC.makeException(zxJDBC.NotSupportedError,
                                   zxJDBC.getString("nocallprocsupport"));

              
// in src/com/ziclix/python/sql/Fetch.java
throw zxJDBC.makeException(zxJDBC.DatabaseError, "no results");

              
// in src/com/ziclix/python/sql/Fetch.java
throw zxJDBC.makeException(zxJDBC.NotSupportedError,
                                       zxJDBC.getString("nodynamiccursors"));

              
// in src/com/ziclix/python/sql/Fetch.java
throw zxJDBC.makeException(e);

              
// in src/com/ziclix/python/sql/Fetch.java
throw zxJDBC.makeException(Py.IndexError, "cursor index [" + value
                                                   + "] out of range");

              
// in src/com/ziclix/python/sql/Fetch.java
throw zxJDBC.makeException(zxJDBC.ProgrammingError,
                                               "invalid cursor scroll mode [" + mode + "]");

              
// in src/com/ziclix/python/sql/Fetch.java
throw zxJDBC.makeException(Py.IndexError, "cursor index [" + value
                                                   + "] out of range");

              
// in src/com/ziclix/python/sql/Fetch.java
throw zxJDBC.makeException(zxJDBC.NotSupportedError, msg);

              
// in src/com/ziclix/python/sql/Fetch.java
throw zxJDBC.makeException(zxJDBC.NotSupportedError,
                                       zxJDBC.getString("nodynamiccursors"));

              
// in src/com/ziclix/python/sql/Fetch.java
throw zxJDBC.makeException(e);

              
// in src/com/ziclix/python/sql/Fetch.java
throw zxJDBC.makeException(t);

              
// in src/com/ziclix/python/sql/zxJDBC.java
throw makeException(t);

              
// in src/com/ziclix/python/sql/zxJDBC.java
throw info.unexpectedCall(1, false);

              
// in src/com/ziclix/python/sql/zxJDBC.java
throw info.unexpectedCall(3, false);

              
// in src/com/ziclix/python/sql/zxJDBC.java
throw info.unexpectedCall(args.length, false);

              
// in src/com/ziclix/python/sql/PyConnection.java
throw zxJDBC.makeException(zxJDBC.DatabaseError, e);

              
// in src/com/ziclix/python/sql/PyConnection.java
throw zxJDBC.makeException(zxJDBC.DatabaseError, e);

              
// in src/com/ziclix/python/sql/PyConnection.java
throw zxJDBC.makeException(zxJDBC.DatabaseError, e);

              
// in src/com/ziclix/python/sql/PyConnection.java
throw zxJDBC.makeException(zxJDBC.DatabaseError, e);

              
// in src/com/ziclix/python/sql/PyConnection.java
throw zxJDBC.makeException(zxJDBC.DatabaseError, e);

              
// in src/com/ziclix/python/sql/PyConnection.java
throw zxJDBC.makeException(zxJDBC.DatabaseError, e);

              
// in src/com/ziclix/python/sql/PyConnection.java
throw zxJDBC.makeException(zxJDBC.DatabaseError, e);

              
// in src/com/ziclix/python/sql/PyConnection.java
throw zxJDBC.makeException(zxJDBC.ProgrammingError, "connection is closed");

              
// in src/com/ziclix/python/sql/PyConnection.java
throw zxJDBC.makeException(e);

              
// in src/com/ziclix/python/sql/PyConnection.java
throw zxJDBC.makeException(zxJDBC.ProgrammingError, "connection is closed");

              
// in src/com/ziclix/python/sql/PyConnection.java
throw zxJDBC.makeException(e);

              
// in src/com/ziclix/python/sql/PyConnection.java
throw zxJDBC.makeException(zxJDBC.ProgrammingError, "connection is closed");

              
// in src/com/ziclix/python/sql/PyConnection.java
throw zxJDBC.makeException(e);

              
// in src/com/ziclix/python/sql/PyConnection.java
throw zxJDBC.makeException(zxJDBC.ProgrammingError, "connection is closed");

              
// in src/com/ziclix/python/sql/PyConnection.java
throw zxJDBC.makeException(e);

              
// in src/com/ziclix/python/sql/PyConnection.java
throw zxJDBC.makeException(zxJDBC.ProgrammingError, "connection is closed");

              
// in src/com/ziclix/python/sql/PyConnection.java
throw info.unexpectedCall(0, false);

              
// in src/com/ziclix/python/sql/PyConnection.java
throw info.unexpectedCall(1, false);

              
// in src/com/ziclix/python/sql/PyConnection.java
throw info.unexpectedCall(3, false);

              
// in src/com/ziclix/python/sql/PyConnection.java
throw info.unexpectedCall(args.length, true);

              
// in src/com/ziclix/python/sql/DataHandler.java
throw createUnsupportedTypeSQLException("ARRAY", col);

              
// in src/com/ziclix/python/sql/DataHandler.java
throw createUnsupportedTypeSQLException("DATALINK", col);

              
// in src/com/ziclix/python/sql/DataHandler.java
throw createUnsupportedTypeSQLException("DISTINCT", col);

              
// in src/com/ziclix/python/sql/DataHandler.java
throw createUnsupportedTypeSQLException("REF", col);

              
// in src/com/ziclix/python/sql/DataHandler.java
throw createUnsupportedTypeSQLException("STRUCT", col);

              
// in src/com/ziclix/python/sql/DataHandler.java
throw createUnsupportedTypeSQLException("STRUCT", col);

              
// in src/com/ziclix/python/sql/DataHandler.java
throw createUnsupportedTypeSQLException(new Integer(type), col);

              
// in src/com/ziclix/python/sql/DataHandler.java
throw zxJDBC.makeException(ioe);

              
// in src/com/ziclix/python/sql/DataHandler.java
throw zxJDBC.makeException(ioe);

              
// in src/com/ziclix/python/sql/DataHandler.java
throw zxJDBC.makeException(ioe);

              
// in src/com/ziclix/python/sql/DataHandler.java
throw zxJDBC.makeException(ioe);

              
// in src/com/ziclix/python/sql/PyExtendedCursor.java
throw zxJDBC.makeException(e);

              
// in src/com/ziclix/python/sql/PyExtendedCursor.java
throw zxJDBC.makeException(e);

              
// in src/com/ziclix/python/sql/PyExtendedCursor.java
throw zxJDBC.makeException(e);

              
// in src/com/ziclix/python/sql/PyExtendedCursor.java
throw zxJDBC.makeException(e);

              
// in src/com/ziclix/python/sql/PyExtendedCursor.java
throw zxJDBC.makeException(e);

              
// in src/com/ziclix/python/sql/PyExtendedCursor.java
throw zxJDBC.makeException(e);

              
// in src/com/ziclix/python/sql/PyExtendedCursor.java
throw zxJDBC.makeException(e);

              
// in src/com/ziclix/python/sql/PyExtendedCursor.java
throw zxJDBC.makeException(e);

              
// in src/com/ziclix/python/sql/PyExtendedCursor.java
throw zxJDBC.makeException(e);

              
// in src/com/ziclix/python/sql/PyExtendedCursor.java
throw zxJDBC.makeException(e);

              
// in src/com/ziclix/python/sql/PyExtendedCursor.java
throw zxJDBC.makeException(e);

              
// in src/com/ziclix/python/sql/PyExtendedCursor.java
throw info.unexpectedCall(0, false);

              
// in src/com/ziclix/python/sql/PyExtendedCursor.java
throw info.unexpectedCall(1, false);

              
// in src/com/ziclix/python/sql/PyExtendedCursor.java
throw info.unexpectedCall(3, false);

              
// in src/com/ziclix/python/sql/PyExtendedCursor.java
throw info.unexpectedCall(args.length, true);

              
// in src/com/ziclix/python/sql/PyExtendedCursor.java
throw info.unexpectedCall(4, false);

              
// in src/com/ziclix/python/sql/Jython22DataHandler.java
throw createUnsupportedTypeSQLException(new Integer(type), col);

              
// in src/com/ziclix/python/sql/Jython22DataHandler.java
throw createUnsupportedTypeSQLException(new Integer(type), col);

              
// in src/com/ziclix/python/sql/connect/Connectx.java
throw zxJDBC.makeException(zxJDBC.DatabaseError, "unable to instantiate datasource");

              
// in src/com/ziclix/python/sql/connect/Connectx.java
throw zxJDBC.makeException(zxJDBC.DatabaseError, e);

              
// in src/com/ziclix/python/sql/connect/Connectx.java
throw zxJDBC.makeException(zxJDBC.DatabaseError, "unable to establish connection");

              
// in src/com/ziclix/python/sql/connect/Connectx.java
throw zxJDBC.makeException(zxJDBC.DatabaseError, e);

              
// in src/com/ziclix/python/sql/connect/Connectx.java
throw zxJDBC.makeException("no such " + exceptionMsg);

              
// in src/com/ziclix/python/sql/connect/Connectx.java
throw zxJDBC.makeException("illegal access for " + exceptionMsg);

              
// in src/com/ziclix/python/sql/connect/Connectx.java
throw zxJDBC.makeException("invocation target exception for " + exceptionMsg);

              
// in src/com/ziclix/python/sql/connect/Connect.java
throw zxJDBC.makeException(zxJDBC.DatabaseError, "no url specified");

              
// in src/com/ziclix/python/sql/connect/Connect.java
throw zxJDBC.makeException(zxJDBC.DatabaseError, "no driver specified");

              
// in src/com/ziclix/python/sql/connect/Connect.java
throw zxJDBC.makeException(zxJDBC.DatabaseError, "driver [" + driver + "] not found");

              
// in src/com/ziclix/python/sql/connect/Connect.java
throw zxJDBC.makeException(zxJDBC.DatabaseError, e);

              
// in src/com/ziclix/python/sql/connect/Connect.java
throw zxJDBC.makeException(zxJDBC.DatabaseError, "unable to establish connection");

              
// in src/com/ziclix/python/sql/connect/Connect.java
throw zxJDBC.makeException(zxJDBC.DatabaseError, e);

              
// in src/com/ziclix/python/sql/connect/Lookup.java
throw zxJDBC.makeException(zxJDBC.DatabaseError, "lookup name is null");

              
// in src/com/ziclix/python/sql/connect/Lookup.java
throw zxJDBC.makeException(zxJDBC.ProgrammingError, e);

              
// in src/com/ziclix/python/sql/connect/Lookup.java
throw zxJDBC.makeException(zxJDBC.DatabaseError, e);

              
// in src/com/ziclix/python/sql/connect/Lookup.java
throw zxJDBC.makeException(zxJDBC.ProgrammingError,
                                       "object [" + jndiName + "] not found in JNDI");

              
// in src/com/ziclix/python/sql/connect/Lookup.java
throw zxJDBC.makeException(zxJDBC.DatabaseError, e);

              
// in src/com/ziclix/python/sql/connect/Lookup.java
throw zxJDBC.makeException(zxJDBC.DatabaseError, "unable to establish connection");

              
// in src/com/ziclix/python/sql/connect/Lookup.java
throw zxJDBC.makeException(zxJDBC.DatabaseError, e);

              
// in src/com/ziclix/python/sql/PyStatement.java
throw zxJDBC.makeException(e);

              
// in src/com/ziclix/python/sql/PyStatement.java
throw zxJDBC.makeException(zxJDBC.ProgrammingError, "statement is closed");

              
// in src/com/ziclix/python/sql/PyStatement.java
throw zxJDBC.makeException(zxJDBC.ProgrammingError,
                                           zxJDBC.getString("invalidStyle"));

              
// in src/com/ziclix/python/sql/PyStatement.java
throw zxJDBC.makeException(zxJDBC.ProgrammingError,
                                                   zxJDBC.getString("bindingValue"));

              
// in src/com/ziclix/python/sql/PyStatement.java
throw zxJDBC.makeException(e);

              
// in src/com/ziclix/python/sql/pipe/Pipe.java
throw zxJDBC.makeException(e);

              
// in src/com/ziclix/python/sql/pipe/Pipe.java
throw zxJDBC.makeException(e);

              
// in src/com/ziclix/python/sql/pipe/Pipe.java
throw zxJDBC.makeException(sourceRunner.getException().toString());

              
// in src/com/ziclix/python/sql/pipe/Pipe.java
throw zxJDBC.makeException(sinkRunner.getException().toString());

              
// in src/com/ziclix/python/sql/pipe/db/DBSink.java
throw zxJDBC.makeException(zxJDBC.getString("noColInfo"));

              
// in src/com/ziclix/python/sql/pipe/db/DBSink.java
throw zxJDBC.makeException(zxJDBC.ProgrammingError, zxJDBC.getString("excludedAllCols"));

              
// in src/com/ziclix/python/sql/pipe/db/BaseDB.java
throw zxJDBC.makeException(msg);

              
// in src/com/ziclix/python/sql/util/PyArgParser.java
throw Py.KeyError(kw);

              
// in src/com/ziclix/python/sql/util/PyArgParser.java
throw Py.IndexError("index out of range");

              
// in src/com/ziclix/python/sql/util/BCP.java
throw Py.ValueError(zxJDBC.getString("invalidTableName"));

              
// in src/com/ziclix/python/sql/util/BCP.java
throw info.unexpectedCall(1, false);

              
// in src/com/ziclix/python/sql/util/BCP.java
throw Py.ValueError(zxJDBC.getString("invalidTableName"));

              
// in src/com/ziclix/python/sql/util/BCP.java
throw info.unexpectedCall(2, false);

              
// in src/com/ziclix/python/sql/util/BCP.java
throw Py.ValueError(zxJDBC.getString("invalidTableName"));

              
// in src/com/ziclix/python/sql/util/BCP.java
throw info.unexpectedCall(3, false);

              
// in src/com/ziclix/python/sql/util/BCP.java
throw Py.ValueError(zxJDBC.getString("invalidTableName"));

              
// in src/com/ziclix/python/sql/util/BCP.java
throw info.unexpectedCall(3, false);

              
// in src/com/ziclix/python/sql/Procedure.java
throw zxJDBC.makeException(zxJDBC.NotSupportedError, "procedureColumnUnknown");

              
// in src/com/ziclix/python/sql/Procedure.java
throw zxJDBC.makeException(zxJDBC.NotSupportedError, "procedureColumnResult");

              
// in src/com/ziclix/python/sql/Procedure.java
throw zxJDBC.makeException(zxJDBC.DataError, "unknown column type [" + colType + "]");

              
// in src/com/ziclix/python/sql/PyCursor.java
throw Py.StopIteration("");

              
// in src/com/ziclix/python/sql/PyCursor.java
throw zxJDBC.makeException(zxJDBC.NotSupportedError,
                                       zxJDBC.getString("nodynamiccursors"));

              
// in src/com/ziclix/python/sql/PyCursor.java
throw zxJDBC.makeException(e);

              
// in src/com/ziclix/python/sql/PyCursor.java
throw zxJDBC.makeException(zxJDBC.NotSupportedError,
                                               "sequence of sequences is not supported");

              
// in src/com/ziclix/python/sql/PyCursor.java
throw zxJDBC.makeException(zxJDBC.NotSupportedError,
                                           zxJDBC.getString("noStoredProc"));

              
// in src/com/ziclix/python/sql/PyCursor.java
throw zxJDBC.makeException(t);

              
// in src/com/ziclix/python/sql/PyCursor.java
throw zxJDBC.makeException(zxJDBC.Error, t, rowIndex);

              
// in src/com/ziclix/python/sql/PyCursor.java
throw zxJDBC.makeException(e);

              
// in src/com/ziclix/python/sql/PyCursor.java
throw zxJDBC.makeException(sqle);

              
// in src/com/ziclix/python/sql/PyCursor.java
throw zxJDBC.makeException(zxJDBC.ProgrammingError,
                                       zxJDBC.getString("optionalSecond"));

              
// in src/com/ziclix/python/sql/PyCursor.java
throw zxJDBC.makeException(zxJDBC.ProgrammingError, "cursor is closed");

              
// in src/com/ziclix/python/sql/PyCursor.java
throw info.unexpectedCall(0, false);

              
// in src/com/ziclix/python/sql/PyCursor.java
throw info.unexpectedCall(1, false);

              
// in src/com/ziclix/python/sql/PyCursor.java
throw info.unexpectedCall(2, false);

              
// in src/com/ziclix/python/sql/PyCursor.java
throw info.unexpectedCall(3, false);

              
// in src/com/ziclix/python/sql/PyCursor.java
throw info.unexpectedCall(args.length, true);

              
// in src/org/python/compiler/ScopesCompiler.java
throw ParserFacade.fixParseError(null, t, code_compiler.getFilename());

              
// in src/org/python/antlr/ast/aliasDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/antlr/ast/aliasDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/aliasDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/aliasDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/aliasDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/aliasDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/aliasDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/aliasDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/antlr/ast/aliasDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/aliasDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/antlr/ast/aliasDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/antlr/ast/aliasDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/antlr/ast/aliasDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/antlr/ast/aliasDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/antlr/ast/aliasDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/antlr/ast/aliasDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/antlr/ast/aliasDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/antlr/ast/aliasDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/AttributeDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/antlr/ast/AttributeDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/AttributeDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/AttributeDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/AttributeDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/AttributeDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/AttributeDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/AttributeDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/antlr/ast/AttributeDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/AttributeDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/antlr/ast/AttributeDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/antlr/ast/AttributeDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/antlr/ast/AttributeDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/antlr/ast/AttributeDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/antlr/ast/AttributeDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/antlr/ast/AttributeDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/antlr/ast/AttributeDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/antlr/ast/AttributeDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/UnaryOpDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/antlr/ast/UnaryOpDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/UnaryOpDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/UnaryOpDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/UnaryOpDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/UnaryOpDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/UnaryOpDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/UnaryOpDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/antlr/ast/UnaryOpDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/UnaryOpDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/antlr/ast/UnaryOpDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/antlr/ast/UnaryOpDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/antlr/ast/UnaryOpDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/antlr/ast/UnaryOpDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/antlr/ast/UnaryOpDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/antlr/ast/UnaryOpDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/antlr/ast/UnaryOpDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/antlr/ast/UnaryOpDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/BreakDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/antlr/ast/BreakDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/BreakDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/BreakDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/BreakDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/BreakDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/BreakDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/BreakDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/antlr/ast/BreakDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/BreakDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/antlr/ast/BreakDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/antlr/ast/BreakDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/antlr/ast/BreakDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/antlr/ast/BreakDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/antlr/ast/BreakDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/antlr/ast/BreakDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/antlr/ast/BreakDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/antlr/ast/BreakDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/BoolOpDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/antlr/ast/BoolOpDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/BoolOpDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/BoolOpDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/BoolOpDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/BoolOpDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/BoolOpDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/BoolOpDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/antlr/ast/BoolOpDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/BoolOpDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/antlr/ast/BoolOpDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/antlr/ast/BoolOpDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/antlr/ast/BoolOpDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/antlr/ast/BoolOpDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/antlr/ast/BoolOpDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/antlr/ast/BoolOpDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/antlr/ast/BoolOpDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/antlr/ast/BoolOpDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ListCompDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/antlr/ast/ListCompDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ListCompDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ListCompDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ListCompDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ListCompDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ListCompDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ListCompDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/antlr/ast/ListCompDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ListCompDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/antlr/ast/ListCompDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/antlr/ast/ListCompDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/antlr/ast/ListCompDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/antlr/ast/ListCompDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/antlr/ast/ListCompDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/antlr/ast/ListCompDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/antlr/ast/ListCompDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/antlr/ast/ListCompDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ContinueDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/antlr/ast/ContinueDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ContinueDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ContinueDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ContinueDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ContinueDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ContinueDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ContinueDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/antlr/ast/ContinueDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ContinueDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/antlr/ast/ContinueDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/antlr/ast/ContinueDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/antlr/ast/ContinueDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/antlr/ast/ContinueDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/antlr/ast/ContinueDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/antlr/ast/ContinueDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/antlr/ast/ContinueDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/antlr/ast/ContinueDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/TupleDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/antlr/ast/TupleDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/TupleDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/TupleDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/TupleDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/TupleDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/TupleDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/TupleDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/antlr/ast/TupleDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/TupleDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/antlr/ast/TupleDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/antlr/ast/TupleDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/antlr/ast/TupleDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/antlr/ast/TupleDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/antlr/ast/TupleDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/antlr/ast/TupleDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/antlr/ast/TupleDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/antlr/ast/TupleDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/InteractiveDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/antlr/ast/InteractiveDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/InteractiveDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/InteractiveDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/InteractiveDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/InteractiveDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/InteractiveDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/InteractiveDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/antlr/ast/InteractiveDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/InteractiveDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/antlr/ast/InteractiveDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/antlr/ast/InteractiveDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/antlr/ast/InteractiveDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/antlr/ast/InteractiveDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/antlr/ast/InteractiveDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/antlr/ast/InteractiveDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/antlr/ast/InteractiveDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/antlr/ast/InteractiveDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/DeleteDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/antlr/ast/DeleteDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/DeleteDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/DeleteDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/DeleteDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/DeleteDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/DeleteDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/DeleteDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/antlr/ast/DeleteDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/DeleteDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/antlr/ast/DeleteDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/antlr/ast/DeleteDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/antlr/ast/DeleteDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/antlr/ast/DeleteDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/antlr/ast/DeleteDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/antlr/ast/DeleteDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/antlr/ast/DeleteDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/antlr/ast/DeleteDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/IndexDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/antlr/ast/IndexDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/IndexDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/IndexDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/IndexDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/IndexDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/IndexDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/IndexDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/antlr/ast/IndexDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/IndexDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/antlr/ast/IndexDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/antlr/ast/IndexDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/antlr/ast/IndexDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/antlr/ast/IndexDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/antlr/ast/IndexDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/antlr/ast/IndexDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/antlr/ast/IndexDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/antlr/ast/IndexDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ModuleDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/antlr/ast/ModuleDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ModuleDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ModuleDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ModuleDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ModuleDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ModuleDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ModuleDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/antlr/ast/ModuleDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ModuleDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/antlr/ast/ModuleDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/antlr/ast/ModuleDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/antlr/ast/ModuleDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/antlr/ast/ModuleDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/antlr/ast/ModuleDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/antlr/ast/ModuleDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/antlr/ast/ModuleDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/antlr/ast/ModuleDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/CallDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/antlr/ast/CallDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/CallDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/CallDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/CallDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/CallDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/CallDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/CallDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/antlr/ast/CallDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/CallDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/antlr/ast/CallDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/antlr/ast/CallDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/antlr/ast/CallDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/antlr/ast/CallDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/antlr/ast/CallDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/antlr/ast/CallDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/antlr/ast/CallDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/antlr/ast/CallDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ReturnDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/antlr/ast/ReturnDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ReturnDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ReturnDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ReturnDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ReturnDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ReturnDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ReturnDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/antlr/ast/ReturnDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ReturnDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/antlr/ast/ReturnDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/antlr/ast/ReturnDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/antlr/ast/ReturnDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/antlr/ast/ReturnDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/antlr/ast/ReturnDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/antlr/ast/ReturnDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/antlr/ast/ReturnDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/antlr/ast/ReturnDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ForDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/antlr/ast/ForDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ForDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ForDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ForDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ForDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ForDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ForDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/antlr/ast/ForDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ForDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/antlr/ast/ForDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/antlr/ast/ForDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/antlr/ast/ForDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/antlr/ast/ForDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/antlr/ast/ForDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/antlr/ast/ForDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/antlr/ast/ForDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/antlr/ast/ForDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ExceptHandlerDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/antlr/ast/ExceptHandlerDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ExceptHandlerDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ExceptHandlerDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ExceptHandlerDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ExceptHandlerDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ExceptHandlerDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ExceptHandlerDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/antlr/ast/ExceptHandlerDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ExceptHandlerDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/antlr/ast/ExceptHandlerDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/antlr/ast/ExceptHandlerDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/antlr/ast/ExceptHandlerDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/antlr/ast/ExceptHandlerDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/antlr/ast/ExceptHandlerDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/antlr/ast/ExceptHandlerDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/antlr/ast/ExceptHandlerDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/antlr/ast/ExceptHandlerDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/SubscriptDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/antlr/ast/SubscriptDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/SubscriptDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/SubscriptDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/SubscriptDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/SubscriptDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/SubscriptDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/SubscriptDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/antlr/ast/SubscriptDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/SubscriptDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/antlr/ast/SubscriptDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/antlr/ast/SubscriptDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/antlr/ast/SubscriptDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/antlr/ast/SubscriptDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/antlr/ast/SubscriptDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/antlr/ast/SubscriptDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/antlr/ast/SubscriptDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/antlr/ast/SubscriptDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/DictDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/antlr/ast/DictDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/DictDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/DictDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/DictDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/DictDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/DictDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/DictDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/antlr/ast/DictDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/DictDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/antlr/ast/DictDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/antlr/ast/DictDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/antlr/ast/DictDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/antlr/ast/DictDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/antlr/ast/DictDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/antlr/ast/DictDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/antlr/ast/DictDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/antlr/ast/DictDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/LambdaDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/antlr/ast/LambdaDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/LambdaDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/LambdaDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/LambdaDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/LambdaDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/LambdaDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/LambdaDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/antlr/ast/LambdaDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/LambdaDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/antlr/ast/LambdaDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/antlr/ast/LambdaDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/antlr/ast/LambdaDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/antlr/ast/LambdaDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/antlr/ast/LambdaDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/antlr/ast/LambdaDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/antlr/ast/LambdaDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/antlr/ast/LambdaDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/GlobalDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/antlr/ast/GlobalDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/GlobalDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/GlobalDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/GlobalDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/GlobalDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/GlobalDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/GlobalDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/antlr/ast/GlobalDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/GlobalDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/antlr/ast/GlobalDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/antlr/ast/GlobalDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/antlr/ast/GlobalDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/antlr/ast/GlobalDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/antlr/ast/GlobalDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/antlr/ast/GlobalDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/antlr/ast/GlobalDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/antlr/ast/GlobalDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ListDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/antlr/ast/ListDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ListDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ListDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ListDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ListDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ListDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ListDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/antlr/ast/ListDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ListDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/antlr/ast/ListDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/antlr/ast/ListDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/antlr/ast/ListDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/antlr/ast/ListDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/antlr/ast/ListDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/antlr/ast/ListDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/antlr/ast/ListDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/antlr/ast/ListDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/BinOpDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/antlr/ast/BinOpDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/BinOpDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/BinOpDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/BinOpDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/BinOpDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/BinOpDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/BinOpDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/antlr/ast/BinOpDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/BinOpDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/antlr/ast/BinOpDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/antlr/ast/BinOpDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/antlr/ast/BinOpDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/antlr/ast/BinOpDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/antlr/ast/BinOpDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/antlr/ast/BinOpDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/antlr/ast/BinOpDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/antlr/ast/BinOpDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ClassDefDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/antlr/ast/ClassDefDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ClassDefDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ClassDefDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ClassDefDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ClassDefDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ClassDefDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ClassDefDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/antlr/ast/ClassDefDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ClassDefDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/antlr/ast/ClassDefDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/antlr/ast/ClassDefDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/antlr/ast/ClassDefDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/antlr/ast/ClassDefDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/antlr/ast/ClassDefDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/antlr/ast/ClassDefDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/antlr/ast/ClassDefDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/antlr/ast/ClassDefDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ExpressionDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/antlr/ast/ExpressionDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ExpressionDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ExpressionDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ExpressionDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ExpressionDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ExpressionDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ExpressionDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/antlr/ast/ExpressionDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ExpressionDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/antlr/ast/ExpressionDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/antlr/ast/ExpressionDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/antlr/ast/ExpressionDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/antlr/ast/ExpressionDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/antlr/ast/ExpressionDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/antlr/ast/ExpressionDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/antlr/ast/ExpressionDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/antlr/ast/ExpressionDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/SliceDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/antlr/ast/SliceDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/SliceDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/SliceDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/SliceDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/SliceDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/SliceDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/SliceDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/antlr/ast/SliceDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/SliceDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/antlr/ast/SliceDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/antlr/ast/SliceDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/antlr/ast/SliceDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/antlr/ast/SliceDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/antlr/ast/SliceDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/antlr/ast/SliceDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/antlr/ast/SliceDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/antlr/ast/SliceDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/NumDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/antlr/ast/NumDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/NumDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/NumDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/NumDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/NumDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/NumDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/NumDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/antlr/ast/NumDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/NumDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/antlr/ast/NumDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/antlr/ast/NumDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/antlr/ast/NumDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/antlr/ast/NumDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/antlr/ast/NumDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/antlr/ast/NumDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/antlr/ast/NumDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/antlr/ast/NumDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ExprDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/antlr/ast/ExprDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ExprDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ExprDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ExprDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ExprDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ExprDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ExprDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/antlr/ast/ExprDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ExprDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/antlr/ast/ExprDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/antlr/ast/ExprDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/antlr/ast/ExprDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/antlr/ast/ExprDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/antlr/ast/ExprDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/antlr/ast/ExprDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/antlr/ast/ExprDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/antlr/ast/ExprDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/NameDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/antlr/ast/NameDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/NameDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/NameDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/NameDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/NameDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/NameDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/NameDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/antlr/ast/NameDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/NameDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/antlr/ast/NameDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/antlr/ast/NameDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/antlr/ast/NameDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/antlr/ast/NameDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/antlr/ast/NameDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/antlr/ast/NameDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/antlr/ast/NameDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/antlr/ast/NameDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/TryFinallyDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/antlr/ast/TryFinallyDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/TryFinallyDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/TryFinallyDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/TryFinallyDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/TryFinallyDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/TryFinallyDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/TryFinallyDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/antlr/ast/TryFinallyDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/TryFinallyDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/antlr/ast/TryFinallyDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/antlr/ast/TryFinallyDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/antlr/ast/TryFinallyDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/antlr/ast/TryFinallyDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/antlr/ast/TryFinallyDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/antlr/ast/TryFinallyDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/antlr/ast/TryFinallyDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/antlr/ast/TryFinallyDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/IfExpDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/antlr/ast/IfExpDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/IfExpDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/IfExpDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/IfExpDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/IfExpDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/IfExpDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/IfExpDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/antlr/ast/IfExpDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/IfExpDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/antlr/ast/IfExpDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/antlr/ast/IfExpDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/antlr/ast/IfExpDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/antlr/ast/IfExpDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/antlr/ast/IfExpDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/antlr/ast/IfExpDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/antlr/ast/IfExpDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/antlr/ast/IfExpDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/AugAssignDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/antlr/ast/AugAssignDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/AugAssignDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/AugAssignDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/AugAssignDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/AugAssignDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/AugAssignDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/AugAssignDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/antlr/ast/AugAssignDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/AugAssignDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/antlr/ast/AugAssignDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/antlr/ast/AugAssignDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/antlr/ast/AugAssignDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/antlr/ast/AugAssignDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/antlr/ast/AugAssignDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/antlr/ast/AugAssignDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/antlr/ast/AugAssignDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/antlr/ast/AugAssignDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ImportDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/antlr/ast/ImportDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ImportDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ImportDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ImportDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ImportDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ImportDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ImportDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/antlr/ast/ImportDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ImportDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/antlr/ast/ImportDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/antlr/ast/ImportDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/antlr/ast/ImportDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/antlr/ast/ImportDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/antlr/ast/ImportDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/antlr/ast/ImportDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/antlr/ast/ImportDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/antlr/ast/ImportDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/IfDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/antlr/ast/IfDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/IfDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/IfDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/IfDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/IfDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/IfDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/IfDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/antlr/ast/IfDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/IfDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/antlr/ast/IfDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/antlr/ast/IfDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/antlr/ast/IfDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/antlr/ast/IfDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/antlr/ast/IfDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/antlr/ast/IfDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/antlr/ast/IfDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/antlr/ast/IfDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/PassDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/antlr/ast/PassDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/PassDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/PassDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/PassDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/PassDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/PassDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/PassDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/antlr/ast/PassDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/PassDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/antlr/ast/PassDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/antlr/ast/PassDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/antlr/ast/PassDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/antlr/ast/PassDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/antlr/ast/PassDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/antlr/ast/PassDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/antlr/ast/PassDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/antlr/ast/PassDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/FunctionDefDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/antlr/ast/FunctionDefDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/FunctionDefDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/FunctionDefDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/FunctionDefDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/FunctionDefDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/FunctionDefDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/FunctionDefDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/antlr/ast/FunctionDefDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/FunctionDefDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/antlr/ast/FunctionDefDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/antlr/ast/FunctionDefDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/antlr/ast/FunctionDefDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/antlr/ast/FunctionDefDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/antlr/ast/FunctionDefDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/antlr/ast/FunctionDefDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/antlr/ast/FunctionDefDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/antlr/ast/FunctionDefDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/argumentsDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/antlr/ast/argumentsDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/argumentsDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/argumentsDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/argumentsDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/argumentsDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/argumentsDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/argumentsDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/antlr/ast/argumentsDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/argumentsDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/antlr/ast/argumentsDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/antlr/ast/argumentsDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/antlr/ast/argumentsDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/antlr/ast/argumentsDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/antlr/ast/argumentsDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/antlr/ast/argumentsDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/antlr/ast/argumentsDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/antlr/ast/argumentsDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/WithDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/antlr/ast/WithDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/WithDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/WithDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/WithDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/WithDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/WithDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/WithDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/antlr/ast/WithDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/WithDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/antlr/ast/WithDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/antlr/ast/WithDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/antlr/ast/WithDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/antlr/ast/WithDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/antlr/ast/WithDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/antlr/ast/WithDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/antlr/ast/WithDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/antlr/ast/WithDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ImportFromDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/antlr/ast/ImportFromDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ImportFromDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ImportFromDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ImportFromDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ImportFromDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ImportFromDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ImportFromDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/antlr/ast/ImportFromDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ImportFromDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/antlr/ast/ImportFromDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/antlr/ast/ImportFromDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/antlr/ast/ImportFromDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/antlr/ast/ImportFromDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/antlr/ast/ImportFromDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/antlr/ast/ImportFromDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/antlr/ast/ImportFromDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/antlr/ast/ImportFromDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/CompareDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/antlr/ast/CompareDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/CompareDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/CompareDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/CompareDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/CompareDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/CompareDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/CompareDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/antlr/ast/CompareDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/CompareDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/antlr/ast/CompareDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/antlr/ast/CompareDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/antlr/ast/CompareDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/antlr/ast/CompareDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/antlr/ast/CompareDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/antlr/ast/CompareDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/antlr/ast/CompareDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/antlr/ast/CompareDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ReprDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/antlr/ast/ReprDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ReprDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ReprDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ReprDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ReprDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ReprDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ReprDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/antlr/ast/ReprDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ReprDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/antlr/ast/ReprDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/antlr/ast/ReprDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/antlr/ast/ReprDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/antlr/ast/ReprDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/antlr/ast/ReprDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/antlr/ast/ReprDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/antlr/ast/ReprDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/antlr/ast/ReprDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/StrDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/antlr/ast/StrDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/StrDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/StrDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/StrDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/StrDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/StrDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/StrDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/antlr/ast/StrDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/StrDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/antlr/ast/StrDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/antlr/ast/StrDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/antlr/ast/StrDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/antlr/ast/StrDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/antlr/ast/StrDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/antlr/ast/StrDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/antlr/ast/StrDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/antlr/ast/StrDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/YieldDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/antlr/ast/YieldDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/YieldDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/YieldDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/YieldDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/YieldDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/YieldDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/YieldDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/antlr/ast/YieldDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/YieldDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/antlr/ast/YieldDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/antlr/ast/YieldDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/antlr/ast/YieldDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/antlr/ast/YieldDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/antlr/ast/YieldDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/antlr/ast/YieldDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/antlr/ast/YieldDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/antlr/ast/YieldDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/EllipsisDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/antlr/ast/EllipsisDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/EllipsisDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/EllipsisDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/EllipsisDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/EllipsisDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/EllipsisDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/EllipsisDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/antlr/ast/EllipsisDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/EllipsisDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/antlr/ast/EllipsisDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/antlr/ast/EllipsisDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/antlr/ast/EllipsisDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/antlr/ast/EllipsisDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/antlr/ast/EllipsisDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/antlr/ast/EllipsisDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/antlr/ast/EllipsisDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/antlr/ast/EllipsisDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/RaiseDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/antlr/ast/RaiseDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/RaiseDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/RaiseDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/RaiseDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/RaiseDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/RaiseDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/RaiseDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/antlr/ast/RaiseDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/RaiseDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/antlr/ast/RaiseDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/antlr/ast/RaiseDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/antlr/ast/RaiseDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/antlr/ast/RaiseDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/antlr/ast/RaiseDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/antlr/ast/RaiseDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/antlr/ast/RaiseDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/antlr/ast/RaiseDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/AssignDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/antlr/ast/AssignDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/AssignDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/AssignDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/AssignDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/AssignDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/AssignDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/AssignDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/antlr/ast/AssignDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/AssignDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/antlr/ast/AssignDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/antlr/ast/AssignDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/antlr/ast/AssignDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/antlr/ast/AssignDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/antlr/ast/AssignDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/antlr/ast/AssignDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/antlr/ast/AssignDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/antlr/ast/AssignDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/GeneratorExpDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/antlr/ast/GeneratorExpDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/GeneratorExpDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/GeneratorExpDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/GeneratorExpDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/GeneratorExpDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/GeneratorExpDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/GeneratorExpDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/antlr/ast/GeneratorExpDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/GeneratorExpDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/antlr/ast/GeneratorExpDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/antlr/ast/GeneratorExpDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/antlr/ast/GeneratorExpDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/antlr/ast/GeneratorExpDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/antlr/ast/GeneratorExpDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/antlr/ast/GeneratorExpDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/antlr/ast/GeneratorExpDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/antlr/ast/GeneratorExpDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/SuiteDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/antlr/ast/SuiteDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/SuiteDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/SuiteDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/SuiteDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/SuiteDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/SuiteDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/SuiteDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/antlr/ast/SuiteDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/SuiteDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/antlr/ast/SuiteDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/antlr/ast/SuiteDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/antlr/ast/SuiteDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/antlr/ast/SuiteDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/antlr/ast/SuiteDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/antlr/ast/SuiteDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/antlr/ast/SuiteDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/antlr/ast/SuiteDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/AssertDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/antlr/ast/AssertDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/AssertDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/AssertDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/AssertDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/AssertDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/AssertDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/AssertDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/antlr/ast/AssertDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/AssertDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/antlr/ast/AssertDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/antlr/ast/AssertDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/antlr/ast/AssertDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/antlr/ast/AssertDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/antlr/ast/AssertDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/antlr/ast/AssertDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/antlr/ast/AssertDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/antlr/ast/AssertDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/TryExceptDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/antlr/ast/TryExceptDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/TryExceptDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/TryExceptDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/TryExceptDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/TryExceptDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/TryExceptDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/TryExceptDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/antlr/ast/TryExceptDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/TryExceptDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/antlr/ast/TryExceptDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/antlr/ast/TryExceptDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/antlr/ast/TryExceptDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/antlr/ast/TryExceptDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/antlr/ast/TryExceptDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/antlr/ast/TryExceptDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/antlr/ast/TryExceptDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/antlr/ast/TryExceptDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ExecDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/antlr/ast/ExecDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ExecDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ExecDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ExecDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ExecDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ExecDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ExecDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/antlr/ast/ExecDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ExecDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/antlr/ast/ExecDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/antlr/ast/ExecDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/antlr/ast/ExecDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/antlr/ast/ExecDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/antlr/ast/ExecDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/antlr/ast/ExecDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/antlr/ast/ExecDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/antlr/ast/ExecDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/WhileDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/antlr/ast/WhileDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/WhileDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/WhileDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/WhileDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/WhileDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/WhileDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/WhileDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/antlr/ast/WhileDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/WhileDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/antlr/ast/WhileDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/antlr/ast/WhileDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/antlr/ast/WhileDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/antlr/ast/WhileDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/antlr/ast/WhileDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/antlr/ast/WhileDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/antlr/ast/WhileDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/antlr/ast/WhileDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/keywordDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/antlr/ast/keywordDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/keywordDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/keywordDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/keywordDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/keywordDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/keywordDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/keywordDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/antlr/ast/keywordDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/keywordDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/antlr/ast/keywordDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/antlr/ast/keywordDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/antlr/ast/keywordDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/antlr/ast/keywordDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/antlr/ast/keywordDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/antlr/ast/keywordDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/antlr/ast/keywordDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/antlr/ast/keywordDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/comprehensionDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/antlr/ast/comprehensionDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/comprehensionDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/comprehensionDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/comprehensionDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/comprehensionDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/comprehensionDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/comprehensionDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/antlr/ast/comprehensionDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/comprehensionDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/antlr/ast/comprehensionDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/antlr/ast/comprehensionDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/antlr/ast/comprehensionDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/antlr/ast/comprehensionDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/antlr/ast/comprehensionDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/antlr/ast/comprehensionDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/antlr/ast/comprehensionDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/antlr/ast/comprehensionDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ExtSliceDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/antlr/ast/ExtSliceDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ExtSliceDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ExtSliceDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ExtSliceDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ExtSliceDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ExtSliceDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ExtSliceDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/antlr/ast/ExtSliceDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/ExtSliceDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/antlr/ast/ExtSliceDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/antlr/ast/ExtSliceDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/antlr/ast/ExtSliceDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/antlr/ast/ExtSliceDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/antlr/ast/ExtSliceDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/antlr/ast/ExtSliceDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/antlr/ast/ExtSliceDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/antlr/ast/ExtSliceDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/PrintDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/antlr/ast/PrintDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/PrintDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/PrintDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/PrintDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/PrintDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/PrintDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/PrintDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/antlr/ast/PrintDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/ast/PrintDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/antlr/ast/PrintDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/antlr/ast/PrintDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/antlr/ast/PrintDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/antlr/ast/PrintDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/antlr/ast/PrintDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/antlr/ast/PrintDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/antlr/ast/PrintDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/antlr/ast/PrintDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/PowDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/antlr/op/PowDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/PowDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/PowDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/PowDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/PowDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/PowDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/PowDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/antlr/op/PowDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/PowDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/antlr/op/PowDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/antlr/op/PowDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/antlr/op/PowDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/antlr/op/PowDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/antlr/op/PowDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/antlr/op/PowDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/antlr/op/PowDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/antlr/op/PowDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/LtEDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/antlr/op/LtEDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/LtEDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/LtEDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/LtEDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/LtEDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/LtEDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/LtEDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/antlr/op/LtEDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/LtEDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/antlr/op/LtEDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/antlr/op/LtEDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/antlr/op/LtEDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/antlr/op/LtEDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/antlr/op/LtEDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/antlr/op/LtEDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/antlr/op/LtEDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/antlr/op/LtEDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/ParamDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/antlr/op/ParamDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/ParamDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/ParamDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/ParamDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/ParamDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/ParamDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/ParamDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/antlr/op/ParamDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/ParamDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/antlr/op/ParamDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/antlr/op/ParamDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/antlr/op/ParamDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/antlr/op/ParamDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/antlr/op/ParamDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/antlr/op/ParamDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/antlr/op/ParamDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/antlr/op/ParamDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/EqDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/antlr/op/EqDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/EqDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/EqDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/EqDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/EqDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/EqDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/EqDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/antlr/op/EqDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/EqDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/antlr/op/EqDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/antlr/op/EqDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/antlr/op/EqDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/antlr/op/EqDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/antlr/op/EqDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/antlr/op/EqDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/antlr/op/EqDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/antlr/op/EqDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/GtDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/antlr/op/GtDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/GtDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/GtDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/GtDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/GtDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/GtDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/GtDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/antlr/op/GtDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/GtDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/antlr/op/GtDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/antlr/op/GtDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/antlr/op/GtDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/antlr/op/GtDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/antlr/op/GtDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/antlr/op/GtDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/antlr/op/GtDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/antlr/op/GtDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/IsDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/antlr/op/IsDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/IsDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/IsDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/IsDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/IsDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/IsDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/IsDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/antlr/op/IsDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/IsDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/antlr/op/IsDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/antlr/op/IsDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/antlr/op/IsDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/antlr/op/IsDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/antlr/op/IsDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/antlr/op/IsDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/antlr/op/IsDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/antlr/op/IsDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/GtEDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/antlr/op/GtEDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/GtEDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/GtEDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/GtEDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/GtEDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/GtEDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/GtEDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/antlr/op/GtEDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/GtEDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/antlr/op/GtEDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/antlr/op/GtEDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/antlr/op/GtEDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/antlr/op/GtEDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/antlr/op/GtEDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/antlr/op/GtEDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/antlr/op/GtEDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/antlr/op/GtEDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/StoreDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/antlr/op/StoreDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/StoreDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/StoreDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/StoreDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/StoreDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/StoreDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/StoreDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/antlr/op/StoreDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/StoreDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/antlr/op/StoreDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/antlr/op/StoreDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/antlr/op/StoreDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/antlr/op/StoreDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/antlr/op/StoreDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/antlr/op/StoreDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/antlr/op/StoreDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/antlr/op/StoreDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/BitOrDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/antlr/op/BitOrDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/BitOrDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/BitOrDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/BitOrDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/BitOrDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/BitOrDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/BitOrDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/antlr/op/BitOrDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/BitOrDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/antlr/op/BitOrDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/antlr/op/BitOrDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/antlr/op/BitOrDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/antlr/op/BitOrDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/antlr/op/BitOrDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/antlr/op/BitOrDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/antlr/op/BitOrDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/antlr/op/BitOrDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/RShiftDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/antlr/op/RShiftDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/RShiftDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/RShiftDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/RShiftDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/RShiftDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/RShiftDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/RShiftDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/antlr/op/RShiftDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/RShiftDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/antlr/op/RShiftDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/antlr/op/RShiftDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/antlr/op/RShiftDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/antlr/op/RShiftDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/antlr/op/RShiftDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/antlr/op/RShiftDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/antlr/op/RShiftDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/antlr/op/RShiftDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/BitAndDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/antlr/op/BitAndDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/BitAndDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/BitAndDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/BitAndDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/BitAndDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/BitAndDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/BitAndDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/antlr/op/BitAndDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/BitAndDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/antlr/op/BitAndDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/antlr/op/BitAndDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/antlr/op/BitAndDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/antlr/op/BitAndDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/antlr/op/BitAndDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/antlr/op/BitAndDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/antlr/op/BitAndDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/antlr/op/BitAndDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/NotInDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/antlr/op/NotInDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/NotInDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/NotInDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/NotInDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/NotInDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/NotInDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/NotInDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/antlr/op/NotInDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/NotInDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/antlr/op/NotInDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/antlr/op/NotInDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/antlr/op/NotInDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/antlr/op/NotInDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/antlr/op/NotInDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/antlr/op/NotInDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/antlr/op/NotInDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/antlr/op/NotInDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/LtDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/antlr/op/LtDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/LtDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/LtDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/LtDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/LtDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/LtDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/LtDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/antlr/op/LtDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/LtDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/antlr/op/LtDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/antlr/op/LtDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/antlr/op/LtDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/antlr/op/LtDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/antlr/op/LtDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/antlr/op/LtDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/antlr/op/LtDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/antlr/op/LtDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/FloorDivDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/antlr/op/FloorDivDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/FloorDivDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/FloorDivDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/FloorDivDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/FloorDivDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/FloorDivDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/FloorDivDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/antlr/op/FloorDivDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/FloorDivDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/antlr/op/FloorDivDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/antlr/op/FloorDivDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/antlr/op/FloorDivDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/antlr/op/FloorDivDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/antlr/op/FloorDivDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/antlr/op/FloorDivDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/antlr/op/FloorDivDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/antlr/op/FloorDivDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/USubDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/antlr/op/USubDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/USubDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/USubDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/USubDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/USubDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/USubDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/USubDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/antlr/op/USubDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/USubDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/antlr/op/USubDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/antlr/op/USubDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/antlr/op/USubDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/antlr/op/USubDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/antlr/op/USubDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/antlr/op/USubDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/antlr/op/USubDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/antlr/op/USubDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/InvertDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/antlr/op/InvertDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/InvertDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/InvertDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/InvertDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/InvertDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/InvertDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/InvertDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/antlr/op/InvertDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/InvertDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/antlr/op/InvertDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/antlr/op/InvertDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/antlr/op/InvertDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/antlr/op/InvertDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/antlr/op/InvertDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/antlr/op/InvertDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/antlr/op/InvertDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/antlr/op/InvertDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/AugLoadDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/antlr/op/AugLoadDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/AugLoadDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/AugLoadDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/AugLoadDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/AugLoadDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/AugLoadDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/AugLoadDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/antlr/op/AugLoadDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/AugLoadDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/antlr/op/AugLoadDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/antlr/op/AugLoadDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/antlr/op/AugLoadDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/antlr/op/AugLoadDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/antlr/op/AugLoadDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/antlr/op/AugLoadDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/antlr/op/AugLoadDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/antlr/op/AugLoadDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/AugStoreDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/antlr/op/AugStoreDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/AugStoreDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/AugStoreDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/AugStoreDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/AugStoreDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/AugStoreDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/AugStoreDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/antlr/op/AugStoreDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/AugStoreDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/antlr/op/AugStoreDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/antlr/op/AugStoreDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/antlr/op/AugStoreDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/antlr/op/AugStoreDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/antlr/op/AugStoreDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/antlr/op/AugStoreDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/antlr/op/AugStoreDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/antlr/op/AugStoreDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/LoadDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/antlr/op/LoadDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/LoadDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/LoadDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/LoadDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/LoadDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/LoadDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/LoadDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/antlr/op/LoadDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/LoadDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/antlr/op/LoadDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/antlr/op/LoadDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/antlr/op/LoadDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/antlr/op/LoadDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/antlr/op/LoadDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/antlr/op/LoadDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/antlr/op/LoadDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/antlr/op/LoadDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/IsNotDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/antlr/op/IsNotDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/IsNotDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/IsNotDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/IsNotDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/IsNotDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/IsNotDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/IsNotDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/antlr/op/IsNotDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/IsNotDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/antlr/op/IsNotDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/antlr/op/IsNotDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/antlr/op/IsNotDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/antlr/op/IsNotDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/antlr/op/IsNotDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/antlr/op/IsNotDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/antlr/op/IsNotDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/antlr/op/IsNotDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/BitXorDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/antlr/op/BitXorDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/BitXorDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/BitXorDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/BitXorDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/BitXorDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/BitXorDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/BitXorDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/antlr/op/BitXorDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/BitXorDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/antlr/op/BitXorDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/antlr/op/BitXorDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/antlr/op/BitXorDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/antlr/op/BitXorDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/antlr/op/BitXorDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/antlr/op/BitXorDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/antlr/op/BitXorDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/antlr/op/BitXorDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/NotEqDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/antlr/op/NotEqDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/NotEqDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/NotEqDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/NotEqDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/NotEqDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/NotEqDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/NotEqDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/antlr/op/NotEqDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/NotEqDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/antlr/op/NotEqDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/antlr/op/NotEqDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/antlr/op/NotEqDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/antlr/op/NotEqDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/antlr/op/NotEqDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/antlr/op/NotEqDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/antlr/op/NotEqDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/antlr/op/NotEqDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/NotDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/antlr/op/NotDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/NotDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/NotDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/NotDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/NotDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/NotDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/NotDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/antlr/op/NotDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/NotDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/antlr/op/NotDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/antlr/op/NotDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/antlr/op/NotDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/antlr/op/NotDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/antlr/op/NotDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/antlr/op/NotDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/antlr/op/NotDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/antlr/op/NotDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/AndDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/antlr/op/AndDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/AndDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/AndDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/AndDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/AndDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/AndDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/AndDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/antlr/op/AndDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/AndDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/antlr/op/AndDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/antlr/op/AndDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/antlr/op/AndDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/antlr/op/AndDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/antlr/op/AndDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/antlr/op/AndDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/antlr/op/AndDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/antlr/op/AndDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/ModDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/antlr/op/ModDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/ModDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/ModDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/ModDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/ModDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/ModDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/ModDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/antlr/op/ModDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/ModDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/antlr/op/ModDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/antlr/op/ModDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/antlr/op/ModDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/antlr/op/ModDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/antlr/op/ModDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/antlr/op/ModDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/antlr/op/ModDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/antlr/op/ModDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/AddDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/antlr/op/AddDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/AddDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/AddDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/AddDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/AddDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/AddDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/AddDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/antlr/op/AddDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/AddDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/antlr/op/AddDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/antlr/op/AddDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/antlr/op/AddDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/antlr/op/AddDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/antlr/op/AddDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/antlr/op/AddDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/antlr/op/AddDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/antlr/op/AddDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/DelDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/antlr/op/DelDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/DelDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/DelDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/DelDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/DelDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/DelDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/DelDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/antlr/op/DelDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/DelDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/antlr/op/DelDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/antlr/op/DelDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/antlr/op/DelDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/antlr/op/DelDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/antlr/op/DelDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/antlr/op/DelDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/antlr/op/DelDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/antlr/op/DelDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/DivDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/antlr/op/DivDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/DivDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/DivDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/DivDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/DivDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/DivDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/DivDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/antlr/op/DivDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/DivDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/antlr/op/DivDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/antlr/op/DivDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/antlr/op/DivDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/antlr/op/DivDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/antlr/op/DivDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/antlr/op/DivDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/antlr/op/DivDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/antlr/op/DivDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/LShiftDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/antlr/op/LShiftDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/LShiftDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/LShiftDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/LShiftDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/LShiftDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/LShiftDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/LShiftDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/antlr/op/LShiftDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/LShiftDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/antlr/op/LShiftDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/antlr/op/LShiftDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/antlr/op/LShiftDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/antlr/op/LShiftDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/antlr/op/LShiftDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/antlr/op/LShiftDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/antlr/op/LShiftDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/antlr/op/LShiftDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/InDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/antlr/op/InDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/InDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/InDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/InDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/InDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/InDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/InDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/antlr/op/InDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/InDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/antlr/op/InDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/antlr/op/InDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/antlr/op/InDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/antlr/op/InDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/antlr/op/InDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/antlr/op/InDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/antlr/op/InDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/antlr/op/InDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/MultDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/antlr/op/MultDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/MultDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/MultDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/MultDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/MultDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/MultDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/MultDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/antlr/op/MultDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/MultDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/antlr/op/MultDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/antlr/op/MultDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/antlr/op/MultDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/antlr/op/MultDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/antlr/op/MultDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/antlr/op/MultDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/antlr/op/MultDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/antlr/op/MultDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/UAddDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/antlr/op/UAddDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/UAddDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/UAddDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/UAddDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/UAddDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/UAddDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/UAddDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/antlr/op/UAddDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/UAddDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/antlr/op/UAddDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/antlr/op/UAddDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/antlr/op/UAddDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/antlr/op/UAddDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/antlr/op/UAddDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/antlr/op/UAddDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/antlr/op/UAddDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/antlr/op/UAddDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/OrDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/antlr/op/OrDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/OrDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/OrDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/OrDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/OrDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/OrDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/OrDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/antlr/op/OrDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/OrDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/antlr/op/OrDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/antlr/op/OrDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/antlr/op/OrDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/antlr/op/OrDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/antlr/op/OrDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/antlr/op/OrDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/antlr/op/OrDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/antlr/op/OrDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/SubDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/antlr/op/SubDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/SubDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/SubDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/SubDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/SubDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/SubDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/SubDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/antlr/op/SubDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/antlr/op/SubDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/antlr/op/SubDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/antlr/op/SubDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/antlr/op/SubDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/antlr/op/SubDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/antlr/op/SubDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/antlr/op/SubDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/antlr/op/SubDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/antlr/op/SubDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/jsr223/PyScriptEngineScope.java
throw Py.KeyError(key);

              
// in src/org/python/jsr223/PyScriptEngine.java
throw scriptException(pye);

              
// in src/org/python/jsr223/PyScriptEngine.java
throw scriptException(pye);

              
// in src/org/python/jsr223/PyScriptEngine.java
throw scriptException(pye);

              
// in src/org/python/jsr223/PyScriptEngine.java
throw scriptException(pye);

              
// in src/org/python/jsr223/PyScriptEngine.java
throw scriptException(pye);

              
// in src/org/python/jsr223/PyScriptEngine.java
throw scriptException(pye);

              
// in src/org/python/modules/zipimport/zipimporterDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/modules/zipimport/zipimporterDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/modules/zipimport/zipimporterDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/modules/zipimport/zipimporterDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/modules/zipimport/zipimporterDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/modules/zipimport/zipimporterDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/modules/zipimport/zipimporterDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/modules/zipimport/zipimporterDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/modules/zipimport/zipimporterDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/modules/zipimport/zipimporterDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/modules/zipimport/zipimporterDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/modules/zipimport/zipimporterDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/modules/zipimport/zipimporterDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/modules/zipimport/zipimporterDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/modules/zipimport/zipimporterDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/modules/zipimport/zipimporterDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/modules/zipimport/zipimporterDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/modules/zipimport/zipimporterDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/modules/zipimport/zipimporter.java
throw zipimport.ZipImportError("archive path is empty");

              
// in src/org/python/modules/zipimport/zipimporter.java
throw zipimport.ZipImportError("not a Zip file: " + path);

              
// in src/org/python/modules/zipimport/zipimporter.java
throw Py.IOError(path);

              
// in src/org/python/modules/zipimport/zipimporter.java
throw Py.IOError(ioe);

              
// in src/org/python/modules/zipimport/zipimporter.java
throw zipimport.ZipImportError(String.format("can't find module '%s'", fullname));

              
// in src/org/python/modules/zipimport/zipimporter.java
throw zipimport.ZipImportError(String.format("can't find module '%s'", fullname));

              
// in src/org/python/modules/zipimport/zipimporter.java
throw zipimport.ZipImportError("zipimport: can not open file: " + archive);

              
// in src/org/python/modules/zipimport/zipimporter.java
throw zipimport.ZipImportError("zipimport: can not open file: " + archive);

              
// in src/org/python/modules/zipimport/zipimporter.java
throw zipimport.ZipImportError(String.format("can't open Zip file: '%s'", archive));

              
// in src/org/python/modules/zipimport/zipimporter.java
throw zipimport.ZipImportError(String.format("can't read Zip file: '%s'", archive));

              
// in src/org/python/modules/zipimport/zipimporter.java
throw Py.IOError(ioe);

              
// in src/org/python/modules/zipimport/zipimporter.java
throw Py.IOError(ioe);

              
// in src/org/python/modules/_py_compile.java
throw Py.IOError(Errno.ENOENT, filename);

              
// in src/org/python/modules/struct.java
throw StructError("insufficient arguments to pack");

              
// in src/org/python/modules/struct.java
throw StructError("required argument is not an integer");

              
// in src/org/python/modules/struct.java
throw StructError("long int too long to convert");

              
// in src/org/python/modules/struct.java
throw StructError("unsigned long int too long to convert");

              
// in src/org/python/modules/struct.java
throw StructError("argument for 's' must be a string");

              
// in src/org/python/modules/struct.java
throw StructError("argument for 'p' must be a string");

              
// in src/org/python/modules/struct.java
throw StructError("char format require string of length 1");

              
// in src/org/python/modules/struct.java
throw StructError("can't convert negative long to unsigned");

              
// in src/org/python/modules/struct.java
throw StructError("can't convert negative long to unsigned");

              
// in src/org/python/modules/struct.java
throw Py.ValueError("can't unpack IEEE 754 special value on non-IEEE platform");

              
// in src/org/python/modules/struct.java
throw Py.ValueError("can't unpack IEEE 754 special value on non-IEEE platform");

              
// in src/org/python/modules/struct.java
throw Py.ValueError("can't unpack IEEE 754 special value on non-IEEE platform");

              
// in src/org/python/modules/struct.java
throw Py.ValueError("can't unpack IEEE 754 special value on non-IEEE platform");

              
// in src/org/python/modules/struct.java
throw StructError("bad char in struct format");

              
// in src/org/python/modules/struct.java
throw StructError("overflow in item count");

              
// in src/org/python/modules/struct.java
throw StructError("total struct size too long");

              
// in src/org/python/modules/struct.java
throw Py.TypeError("pack_into takes an array arg");

              
// in src/org/python/modules/struct.java
throw StructError("pack_into requires a buffer of at least " + res.pos + " bytes, got " + buffer.__len__());

              
// in src/org/python/modules/struct.java
throw StructError("too many arguments for pack format");

              
// in src/org/python/modules/struct.java
throw StructError("unpack str size does not match format");

              
// in src/org/python/modules/struct.java
throw StructError("unpack str size does not match format");

              
// in src/org/python/modules/struct.java
throw StructError("unpack_from str size does not match format");

              
// in src/org/python/modules/PyStruct.java
throw Py.TypeError("'" + keyword + "' is an invalid keyword argument for this function");

              
// in src/org/python/modules/PyStruct.java
throw Py.TypeError("Struct() takes exactly 1 argument (" + nargs + " given)");

              
// in src/org/python/modules/PyStruct.java
throw Py.TypeError("unpack of a str or array");

              
// in src/org/python/modules/PyStruct.java
throw struct.StructError("unpack str size does not match format");

              
// in src/org/python/modules/PyStruct.java
throw struct.StructError("unpack_from str size does not match format");

              
// in src/org/python/modules/sre/PatternObject.java
throw Py.RuntimeError("maximum recursion limit exceeded");

              
// in src/org/python/modules/sre/PatternObject.java
throw Py.RuntimeError("internal error in regular expression engine");

              
// in src/org/python/modules/sre/PatternObject.java
throw Py.TypeError("expected str or unicode but got " + obj.getType());

              
// in src/org/python/modules/sre/MatchObject.java
throw Py.TypeError("expand() takes exactly 1 argument (0 given)");

              
// in src/org/python/modules/sre/MatchObject.java
throw Py.IndexError("no such group");

              
// in src/org/python/modules/sre/MatchObject.java
throw Py.IndexError("no such group");

              
// in src/org/python/modules/sre/MatchObject.java
throw Py.IndexError("no such group");

              
// in src/org/python/modules/sre/MatchObject.java
throw Py.IndexError("no such group");

              
// in src/org/python/modules/binascii.java
throw Py.TypeError("Odd-length string");

              
// in src/org/python/modules/binascii.java
throw Py.TypeError("Non-hexadecimal digit found");

              
// in src/org/python/modules/binascii.java
throw Py.TypeError(errMsg);

              
// in src/org/python/modules/gc.java
throw Py.NotImplementedError("can't disable Java GC");

              
// in src/org/python/modules/gc.java
throw Py.NotImplementedError("not applicable to Java GC");

              
// in src/org/python/modules/gc.java
throw Py.NotImplementedError("not applicable to Java GC");

              
// in src/org/python/modules/gc.java
throw Py.NotImplementedError("not applicable to Java GC");

              
// in src/org/python/modules/gc.java
throw Py.NotImplementedError("not applicable to Java GC");

              
// in src/org/python/modules/gc.java
throw Py.NotImplementedError("not applicable to Java GC");

              
// in src/org/python/modules/gc.java
throw Py.NotImplementedError("not applicable to Java GC");

              
// in src/org/python/modules/gc.java
throw Py.NotImplementedError("not applicable to Java GC");

              
// in src/org/python/modules/math.java
throw Py.ValueError("math domain error");

              
// in src/org/python/modules/math.java
throw Py.OverflowError("math range error");

              
// in src/org/python/modules/math.java
throw Py.OverflowError("math range error");

              
// in src/org/python/modules/PyIOFileFactory.java
throw Py.ValueError("I/O operation on closed file");

              
// in src/org/python/modules/_weakref/AbstractReference.java
throw Py.ReferenceError("weakly-referenced object no longer exists");

              
// in src/org/python/modules/_weakref/GlobalRef.java
throw Py.TypeError("weak object has gone away");

              
// in src/org/python/modules/_weakref/ReferenceTypeDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/modules/_weakref/ReferenceTypeDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/modules/_weakref/ReferenceTypeDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/modules/_weakref/ReferenceTypeDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/modules/_weakref/ReferenceTypeDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/modules/_weakref/ReferenceTypeDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/modules/_weakref/ReferenceTypeDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/modules/_weakref/ReferenceTypeDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/modules/_weakref/ReferenceTypeDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/modules/_weakref/ReferenceTypeDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/modules/_weakref/ReferenceTypeDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/modules/_weakref/ReferenceTypeDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/modules/_weakref/ReferenceTypeDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/modules/_weakref/ReferenceTypeDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/modules/_weakref/ReferenceTypeDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/modules/_weakref/ReferenceTypeDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/modules/_weakref/ReferenceTypeDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/modules/_weakref/ReferenceTypeDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/modules/posix/PyStatResult.java
throw Py.TypeError(msg);

              
// in src/org/python/modules/posix/PyStatResult.java
throw Py.TypeError(msg);

              
// in src/org/python/modules/posix/PosixModule.java
throw Py.TypeError(String.format("coercing to Unicode: need string, '%s' type found",
                                             pathObj.getType().fastGetName()));

              
// in src/org/python/modules/posix/PosixModule.java
throw Py.OSError(Errno.ENOTDIR, path);

              
// in src/org/python/modules/posix/PosixModule.java
throw errorFromErrno(path);

              
// in src/org/python/modules/posix/PosixModule.java
throw errorFromErrno(path);

              
// in src/org/python/modules/posix/PosixModule.java
throw badFD();

              
// in src/org/python/modules/posix/PosixModule.java
throw Py.ValueError(String.format("invalid file mode '%s'", mode));

              
// in src/org/python/modules/posix/PosixModule.java
throw badFD();

              
// in src/org/python/modules/posix/PosixModule.java
throw Py.OSError(Errno.EINVAL);

              
// in src/org/python/modules/posix/PosixModule.java
throw Py.OSError(Errno.EINVAL);

              
// in src/org/python/modules/posix/PosixModule.java
throw Py.ValueError("I/O operation on closed file");

              
// in src/org/python/modules/posix/PosixModule.java
throw Py.OSError(ioe);

              
// in src/org/python/modules/posix/PosixModule.java
throw Py.IOError(Errno.EBADF);

              
// in src/org/python/modules/posix/PosixModule.java
throw Py.NotImplementedError("Integer file descriptor compatibility only "
                                             + "available for stdin, stdout and stderr (0-2)");

              
// in src/org/python/modules/posix/PosixModule.java
throw Py.TypeError("a file descriptor is required");

              
// in src/org/python/modules/posix/PosixModule.java
throw errorFromErrno();

              
// in src/org/python/modules/posix/PosixModule.java
throw errorFromErrno(path);

              
// in src/org/python/modules/posix/PosixModule.java
throw errorFromErrno(path);

              
// in src/org/python/modules/posix/PosixModule.java
throw Py.OSError(Errno.ENOTDIR, path);

              
// in src/org/python/modules/posix/PosixModule.java
throw Py.OSError(Errno.EACCES, path);

              
// in src/org/python/modules/posix/PosixModule.java
throw Py.OSError("listdir(): an unknown error occured: " + path);

              
// in src/org/python/modules/posix/PosixModule.java
throw badFD();

              
// in src/org/python/modules/posix/PosixModule.java
throw errorFromErrno(path);

              
// in src/org/python/modules/posix/PosixModule.java
throw Py.OSError(Errno.EINVAL, path);

              
// in src/org/python/modules/posix/PosixModule.java
throw Py.OSError(Errno.ENOENT, path);

              
// in src/org/python/modules/posix/PosixModule.java
throw Py.OSError(Errno.EEXIST, path);

              
// in src/org/python/modules/posix/PosixModule.java
throw Py.OSError(ioe);

              
// in src/org/python/modules/posix/PosixModule.java
throw Py.OSError(file.isDirectory() ? Errno.EISDIR : Errno.ENOENT, path);

              
// in src/org/python/modules/posix/PosixModule.java
throw badFD();

              
// in src/org/python/modules/posix/PosixModule.java
throw Py.OSError(ioe);

              
// in src/org/python/modules/posix/PosixModule.java
throw Py.OSError(Errno.ENOENT, path);

              
// in src/org/python/modules/posix/PosixModule.java
throw Py.OSError(Errno.ENOTDIR, path);

              
// in src/org/python/modules/posix/PosixModule.java
throw errorFromErrno();

              
// in src/org/python/modules/posix/PosixModule.java
throw errorFromErrno();

              
// in src/org/python/modules/posix/PosixModule.java
throw Py.OSError(Errno.EISDIR, path);

              
// in src/org/python/modules/posix/PosixModule.java
throw Py.OSError(Errno.EPERM, path);

              
// in src/org/python/modules/posix/PosixModule.java
throw Py.OSError("unlink(): an unknown error occured: " + path);

              
// in src/org/python/modules/posix/PosixModule.java
throw Py.TypeError("utime() arg 2 must be a tuple (atime, mtime)");

              
// in src/org/python/modules/posix/PosixModule.java
throw errorFromErrno();

              
// in src/org/python/modules/posix/PosixModule.java
throw errorFromErrno();

              
// in src/org/python/modules/posix/PosixModule.java
throw badFD();

              
// in src/org/python/modules/posix/PosixModule.java
throw Py.TypeError(String.format("coercing to Unicode: need string, %s type found",
                                             path.getType().fastGetName()));

              
// in src/org/python/modules/posix/PosixModule.java
throw Py.TypeError("coercing to Unicode: need string or buffer, NoneType found");

              
// in src/org/python/modules/posix/PosixModule.java
throw Py.TypeError(String.format("coercing to Unicode: need string or buffer, %s " +
                                                 "found", pathObj.getType().fastGetName()));

              
// in src/org/python/modules/posix/PosixModule.java
throw Py.TypeError(String.format("coercing to Unicode: need string or buffer, %s " +
                                                 "found", pathObj.getType().fastGetName()));

              
// in src/org/python/modules/posix/PythonPOSIXHandler.java
throw Py.OSError(error, extraData);

              
// in src/org/python/modules/posix/PythonPOSIXHandler.java
throw Py.NotImplementedError(methodName);

              
// in src/org/python/modules/cmath.java
throw Py.TypeError("__complex__ should return a complex object");

              
// in src/org/python/modules/thread/PyLocalDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/modules/thread/PyLocalDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/modules/thread/PyLocalDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/modules/thread/PyLocalDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/modules/thread/PyLocalDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/modules/thread/PyLocalDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/modules/thread/PyLocalDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/modules/thread/PyLocalDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/modules/thread/PyLocalDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/modules/thread/PyLocalDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/modules/thread/PyLocalDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/modules/thread/PyLocalDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/modules/thread/PyLocalDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/modules/thread/PyLocalDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/modules/thread/PyLocalDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/modules/thread/PyLocalDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/modules/thread/PyLocalDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/modules/thread/thread.java
throw Py.ValueError("size not valid: " + proposed_stack_size + " bytes");

              
// in src/org/python/modules/thread/thread.java
throw Py.TypeError("stack_size() takes at most 1 argument (" + args.length + "given)");

              
// in src/org/python/modules/thread/PyLocal.java
throw Py.TypeError("Initialization arguments are not supported");

              
// in src/org/python/modules/thread/PyLock.java
throw Py.ValueError("lock not acquired");

              
// in src/org/python/modules/_marshal.java
throw Py.ValueError("Maximum marshal stack depth");

              
// in src/org/python/modules/_marshal.java
throw Py.TypeError("NULL object in marshal data");

              
// in src/org/python/modules/_marshal.java
throw Py.EOFError("EOF read where object expected");

              
// in src/org/python/modules/_marshal.java
throw Py.ValueError("bad marshal data");

              
// in src/org/python/modules/_marshal.java
throw Py.ValueError("Maximum marshal stack depth");

              
// in src/org/python/modules/_marshal.java
throw Py.ValueError("bad marshal data");

              
// in src/org/python/modules/_marshal.java
throw Py.ValueError("bad marshal data");

              
// in src/org/python/modules/_marshal.java
throw Py.ValueError("bad marshal data");

              
// in src/org/python/modules/cPickle.java
throw Py.TypeError("dict items iterator must return 2-tuples");

              
// in src/org/python/modules/cPickle.java
throw Py.ValueError("can't make hashtable of size: " +
                                    capacity);

              
// in src/org/python/modules/cPickle.java
throw Py.ValueError("unsupported pickle protocol: " + proto);

              
// in src/org/python/modules/cPickle.java
throw Py.ValueError("could not convert string to int");

              
// in src/org/python/modules/cPickle.java
throw Py.ValueError("insecure string pickle");

              
// in src/org/python/modules/cPickle.java
throw Py.ValueError("insecure string pickle");

              
// in src/org/python/modules/cPickle.java
throw Py.ValueError("insecure string pickle " + i);

              
// in src/org/python/modules/_csv/PyDialect.java
throw Py.TypeError("bad \"quoting\" value");

              
// in src/org/python/modules/_csv/PyDialect.java
throw Py.TypeError("delimiter must be set");

              
// in src/org/python/modules/_csv/PyDialect.java
throw Py.TypeError("quotechar must be set if quoting enabled");

              
// in src/org/python/modules/_csv/PyDialect.java
throw Py.TypeError("lineterminator must be set");

              
// in src/org/python/modules/_csv/PyDialect.java
throw Py.TypeError(String.format("\"%s\" must be an 1-character string", name));

              
// in src/org/python/modules/_csv/PyDialect.java
throw Py.TypeError(String.format("\"%s\" must be an integer", name));

              
// in src/org/python/modules/_csv/PyDialect.java
throw Py.TypeError(String.format("\"%s\" must be an string", name));

              
// in src/org/python/modules/_csv/PyDialect.java
throw Py.AttributeError(String.format("attribute '%s' of '%s' objects is not writable",
                                              "quoting", getType().fastGetName()));

              
// in src/org/python/modules/_csv/PyDialect.java
throw Py.AttributeError(String.format("attribute '%s' of '%s' objects is not writable",
                                              "quoting", getType().fastGetName()));

              
// in src/org/python/modules/_csv/PyWriter.java
throw _csv.Error("writerows() argument must be iterable");

              
// in src/org/python/modules/_csv/PyWriter.java
throw _csv.Error("sequence expected");

              
// in src/org/python/modules/_csv/PyWriter.java
throw _csv.Error("need to escape, but no escapechar set");

              
// in src/org/python/modules/_csv/PyWriter.java
throw _csv.Error("single empty field record must be quoted");

              
// in src/org/python/modules/_csv/_csv.java
throw Py.TypeError("register_dialect() expected at most 2 arguments, got " + argc);

              
// in src/org/python/modules/_csv/_csv.java
throw Py.TypeError("dialect name must be a string or unicode");

              
// in src/org/python/modules/_csv/_csv.java
throw Error("unknown dialect");

              
// in src/org/python/modules/_csv/_csv.java
throw Py.TypeError("argument 1 must have a \"write\" method");

              
// in src/org/python/modules/_csv/_csv.java
throw Py.TypeError("limit must be an integer");

              
// in src/org/python/modules/_csv/_csv.java
throw Error("unknown dialect");

              
// in src/org/python/modules/_csv/PyReader.java
throw _csv.Error("newline inside string");

              
// in src/org/python/modules/_csv/PyReader.java
throw _csv.Error("line contains NULL byte");

              
// in src/org/python/modules/_csv/PyReader.java
throw _csv.Error(String.format("'%c' expected after '%c'",
                                                   dialect.delimiter, dialect.quotechar));

              
// in src/org/python/modules/_csv/PyReader.java
throw _csv.Error(err);

              
// in src/org/python/modules/_csv/PyReader.java
throw _csv.Error(String.format("field larger than field limit (%d)",
                                           _csv.field_limit));

              
// in src/org/python/modules/_csv/PyDialectDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/modules/_csv/PyDialectDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/modules/_csv/PyDialectDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/modules/_csv/PyDialectDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/modules/_csv/PyDialectDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/modules/_csv/PyDialectDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/modules/_csv/PyDialectDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/modules/_csv/PyDialectDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/modules/_csv/PyDialectDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/modules/_csv/PyDialectDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/modules/_csv/PyDialectDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/modules/_csv/PyDialectDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/modules/_csv/PyDialectDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/modules/_csv/PyDialectDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/modules/_csv/PyDialectDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/modules/_csv/PyDialectDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/modules/_csv/PyDialectDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/modules/operator.java
throw info.unexpectedCall(1, false);

              
// in src/org/python/modules/operator.java
throw info.unexpectedCall(2, false);

              
// in src/org/python/modules/operator.java
throw info.unexpectedCall(3, false);

              
// in src/org/python/modules/operator.java
throw info.unexpectedCall(4, false);

              
// in src/org/python/modules/operator.java
throw Py.ValueError("sequence.index(x): x not in list");

              
// in src/org/python/modules/operator.java
throw Py.TypeError(String.format("attribute name must be string, not '%.200s'",
                                                 name.getType().fastGetName()));

              
// in src/org/python/modules/random/PyRandom.java
throw Py.TypeError(String.format("jumpahead requires an integer, not '%s'",
                                             arg0.getType().fastGetName()));

              
// in src/org/python/modules/random/PyRandom.java
throw Py.TypeError("state vector must be a tuple");

              
// in src/org/python/modules/random/PyRandom.java
throw Py.TypeError("state vector of unexpected type: "+
                            arr[i].getClass());

              
// in src/org/python/modules/random/PyRandom.java
throw Py.SystemError("state vector invalid: "+e.getMessage());

              
// in src/org/python/modules/random/PyRandom.java
throw Py.SystemError("state vector invalid: "+e.getMessage());

              
// in src/org/python/modules/random/PyRandom.java
throw Py.SystemError("creation of state vector failed: "+
                    e.getMessage());

              
// in src/org/python/modules/random/PyRandomDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/modules/random/PyRandomDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/modules/random/PyRandomDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/modules/random/PyRandomDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/modules/random/PyRandomDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/modules/random/PyRandomDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/modules/random/PyRandomDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/modules/random/PyRandomDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/modules/random/PyRandomDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/modules/random/PyRandomDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/modules/random/PyRandomDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/modules/random/PyRandomDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/modules/random/PyRandomDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/modules/random/PyRandomDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/modules/random/PyRandomDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/modules/random/PyRandomDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/modules/random/PyRandomDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/modules/random/PyRandomDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/modules/_collections/PyDefaultDict.java
throw Py.KeyError(key);

              
// in src/org/python/modules/_collections/PyDefaultDict.java
throw Py.TypeError("first argument must be callable");

              
// in src/org/python/modules/_collections/PyDefaultDict.java
throw Py.KeyError(key);

              
// in src/org/python/modules/_collections/PyDefaultDict.java
throw Py.KeyError(key);

              
// in src/org/python/modules/_collections/PyDequeDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/modules/_collections/PyDequeDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/modules/_collections/PyDequeDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/modules/_collections/PyDequeDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/modules/_collections/PyDequeDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/modules/_collections/PyDequeDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/modules/_collections/PyDequeDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/modules/_collections/PyDequeDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/modules/_collections/PyDequeDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/modules/_collections/PyDequeDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/modules/_collections/PyDequeDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/modules/_collections/PyDequeDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/modules/_collections/PyDequeDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/modules/_collections/PyDequeDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/modules/_collections/PyDequeDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/modules/_collections/PyDequeDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/modules/_collections/PyDequeDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/modules/_collections/PyDequeDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/modules/_collections/PyDefaultDictDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/modules/_collections/PyDefaultDictDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/modules/_collections/PyDefaultDictDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/modules/_collections/PyDefaultDictDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/modules/_collections/PyDefaultDictDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/modules/_collections/PyDefaultDictDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/modules/_collections/PyDefaultDictDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/modules/_collections/PyDefaultDictDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/modules/_collections/PyDefaultDictDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/modules/_collections/PyDefaultDictDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/modules/_collections/PyDefaultDictDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/modules/_collections/PyDefaultDictDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/modules/_collections/PyDefaultDictDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/modules/_collections/PyDefaultDictDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/modules/_collections/PyDefaultDictDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/modules/_collections/PyDefaultDictDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/modules/_collections/PyDefaultDictDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/modules/_collections/PyDefaultDictDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/modules/_collections/PyDeque.java
throw Py.TypeError("deque() does not take keyword arguments");

              
// in src/org/python/modules/_collections/PyDeque.java
throw PyBuiltinCallable.DefaultInfo.unexpectedCall(nargs, false, "deque", 0, 1);

              
// in src/org/python/modules/_collections/PyDeque.java
throw Py.IndexError("pop from an empty deque");

              
// in src/org/python/modules/_collections/PyDeque.java
throw Py.IndexError("deque mutated during remove().");

              
// in src/org/python/modules/_collections/PyDeque.java
throw Py.ValueError("deque.remove(x): x not in deque");

              
// in src/org/python/modules/_collections/PyDeque.java
throw Py.TypeError(String.format("sequence index must be integer, not '%.200s'",
                                             index.getType().fastGetName()));

              
// in src/org/python/modules/_collections/PyDeque.java
throw Py.IndexError("index out of range: " + index);

              
// in src/org/python/modules/_collections/PyDeque.java
throw Py.TypeError("deque objects are unhashable");

              
// in src/org/python/modules/_collections/PyDeque.java
throw Py.RuntimeError("deque changed size during iteration");

              
// in src/org/python/modules/jffi/Function.java
throw Py.TypeError("expected memory address");

              
// in src/org/python/modules/jffi/Function.java
throw Py.TypeError("wrong argument type (expected list or tuple)");

              
// in src/org/python/modules/jffi/Function.java
throw Py.NotImplementedError("variadic functions not supported yet;  specify a parameter list");

              
// in src/org/python/modules/jffi/InvalidMemory.java
throw ex();

              
// in src/org/python/modules/jffi/InvalidMemory.java
throw ex();

              
// in src/org/python/modules/jffi/InvalidMemory.java
throw ex();

              
// in src/org/python/modules/jffi/InvalidMemory.java
throw ex();

              
// in src/org/python/modules/jffi/InvalidMemory.java
throw ex();

              
// in src/org/python/modules/jffi/InvalidMemory.java
throw ex();

              
// in src/org/python/modules/jffi/InvalidMemory.java
throw ex();

              
// in src/org/python/modules/jffi/InvalidMemory.java
throw ex();

              
// in src/org/python/modules/jffi/InvalidMemory.java
throw ex();

              
// in src/org/python/modules/jffi/InvalidMemory.java
throw ex();

              
// in src/org/python/modules/jffi/InvalidMemory.java
throw ex();

              
// in src/org/python/modules/jffi/InvalidMemory.java
throw ex();

              
// in src/org/python/modules/jffi/InvalidMemory.java
throw ex();

              
// in src/org/python/modules/jffi/InvalidMemory.java
throw ex();

              
// in src/org/python/modules/jffi/InvalidMemory.java
throw ex();

              
// in src/org/python/modules/jffi/InvalidMemory.java
throw ex();

              
// in src/org/python/modules/jffi/InvalidMemory.java
throw ex();

              
// in src/org/python/modules/jffi/InvalidMemory.java
throw ex();

              
// in src/org/python/modules/jffi/InvalidMemory.java
throw ex();

              
// in src/org/python/modules/jffi/InvalidMemory.java
throw ex();

              
// in src/org/python/modules/jffi/InvalidMemory.java
throw ex();

              
// in src/org/python/modules/jffi/InvalidMemory.java
throw ex();

              
// in src/org/python/modules/jffi/InvalidMemory.java
throw ex();

              
// in src/org/python/modules/jffi/InvalidMemory.java
throw ex();

              
// in src/org/python/modules/jffi/InvalidMemory.java
throw ex();

              
// in src/org/python/modules/jffi/InvalidMemory.java
throw ex();

              
// in src/org/python/modules/jffi/InvalidMemory.java
throw ex();

              
// in src/org/python/modules/jffi/InvalidMemory.java
throw ex();

              
// in src/org/python/modules/jffi/InvalidMemory.java
throw ex();

              
// in src/org/python/modules/jffi/InvalidMemory.java
throw ex();

              
// in src/org/python/modules/jffi/InvalidMemory.java
throw ex();

              
// in src/org/python/modules/jffi/InvalidMemory.java
throw ex();

              
// in src/org/python/modules/jffi/InvalidMemory.java
throw ex();

              
// in src/org/python/modules/jffi/InvalidMemory.java
throw ex();

              
// in src/org/python/modules/jffi/InvalidMemory.java
throw ex();

              
// in src/org/python/modules/jffi/InvalidMemory.java
throw ex();

              
// in src/org/python/modules/jffi/InvalidMemory.java
throw ex();

              
// in src/org/python/modules/jffi/InvalidMemory.java
throw ex();

              
// in src/org/python/modules/jffi/InvalidMemory.java
throw ex();

              
// in src/org/python/modules/jffi/DynamicLibrary.java
throw Py.RuntimeError("Could not open " 
                    + libname != null ? libname : "[current process]"
                    + " " + Library.getLastError());

              
// in src/org/python/modules/jffi/DynamicLibrary.java
throw Py.NameError("Could not locate symbol '" + name.asString() + "' in " + this.name);

              
// in src/org/python/modules/jffi/DefaultInvokerFactory.java
throw Py.RuntimeError("Unsupported return type: " + returnType);

              
// in src/org/python/modules/jffi/DefaultInvokerFactory.java
throw Py.RuntimeError("Unsupported parameter type: " + type);

              
// in src/org/python/modules/jffi/DefaultInvokerFactory.java
throw Py.RuntimeError("Unsupported parameter type: " + type);

              
// in src/org/python/modules/jffi/DefaultInvokerFactory.java
throw Py.TypeError(String.format("expected %d args; got %d", arity, got));

              
// in src/org/python/modules/jffi/DefaultInvokerFactory.java
throw Py.TypeError("expected pointer argument");

              
// in src/org/python/modules/jffi/Util.java
throw Py.TypeError("invalid __long__() result");

              
// in src/org/python/modules/jffi/Util.java
throw Py.IndexError("Memory access offset="
                    + off + " size=" + len + " is out of bounds");

              
// in src/org/python/modules/jffi/Util.java
throw Py.TypeError("invalid address");

              
// in src/org/python/modules/jffi/CData.java
throw Py.TypeError("expected type");

              
// in src/org/python/modules/jffi/CData.java
throw Py.TypeError("invalid memory");

              
// in src/org/python/modules/jffi/CData.java
throw Py.TypeError("expected library, not " + lib.getType().fastGetName());

              
// in src/org/python/modules/jffi/MemoryOp.java
throw Py.TypeError("invalid memory access");

              
// in src/org/python/modules/jffi/MemoryOp.java
throw Py.TypeError("invalid memory access");

              
// in src/org/python/modules/jffi/MemoryOp.java
throw Py.TypeError("Attempting to write void to memory");

              
// in src/org/python/modules/jffi/MemoryOp.java
throw Py.TypeError("Attempting to read void from memory");

              
// in src/org/python/modules/jffi/MemoryOp.java
throw Py.RuntimeError("invalid pointer");

              
// in src/org/python/modules/jffi/MemoryOp.java
throw Py.NotImplementedError("Cannot set String");

              
// in src/org/python/modules/jffi/MemoryOp.java
throw Py.NotImplementedError("Cannot get String");

              
// in src/org/python/modules/jffi/MemoryOp.java
throw Py.TypeError("invalid _jffi_type for " + type.fastGetName() + "; should be instance of jffi.StructLayout");

              
// in src/org/python/modules/jffi/MemoryOp.java
throw Py.NotImplementedError("not implemented");

              
// in src/org/python/modules/jffi/PointerCData.java
throw Py.TypeError("expected " + pointerType.pyComponentType.getName() + " instead of " + value.getType().getName());

              
// in src/org/python/modules/jffi/PointerCData.java
throw Py.TypeError("invalid _jffi_type for " + subtype.getName());

              
// in src/org/python/modules/jffi/ArrayCData.java
throw Py.TypeError("invalid _jffi_type for " + subtype.getName());

              
// in src/org/python/modules/jffi/ArrayCData.java
throw Py.TypeError("Array does not support item deletion");

              
// in src/org/python/modules/jffi/ArrayCData.java
throw Py.TypeError("expected list or tuple");

              
// in src/org/python/modules/jffi/ArrayCData.java
throw Py.TypeError("Array does not support item deletion");

              
// in src/org/python/modules/jffi/ArrayCData.java
throw Py.TypeError("Array does not support item deletion");

              
// in src/org/python/modules/jffi/StructLayout.java
throw Py.TypeError("expected pointer");

              
// in src/org/python/modules/jffi/StructLayout.java
throw Py.TypeError("expected list of jffi.StructLayout.Field");

              
// in src/org/python/modules/jffi/StructLayout.java
throw Py.TypeError(String.format("element %d of field list is not an instance of jffi.StructLayout.Field", i));

              
// in src/org/python/modules/jffi/jffi.java
throw Py.TypeError("invalid memory address");

              
// in src/org/python/modules/jffi/AllocatedNativeMemory.java
throw Py.RuntimeError("failed to allocate " + size + " bytes");

              
// in src/org/python/modules/jffi/FastIntInvokerFactory.java
throw Py.RuntimeError("fast int invoker does not support functions with arity=" + parameterConverters.length);

              
// in src/org/python/modules/jffi/FastIntInvokerFactory.java
throw Py.TypeError("cannot convert objects of type " + type + " to int");

              
// in src/org/python/modules/jffi/FastIntInvokerFactory.java
throw Py.TypeError("cannot convert objects of type " + type + " to int");

              
// in src/org/python/modules/jffi/FastIntInvokerFactory.java
throw Py.TypeError(String.format("__call__() takes exactly %d arguments (%d given)", arity, got));

              
// in src/org/python/modules/jffi/FastIntInvokerFactory.java
throw Py.RuntimeError("invalid fast-int arity");

              
// in src/org/python/modules/jffi/Structure.java
throw Py.TypeError("invalid _jffi_type for " + subtype.fastGetName() + "; should be instance of jffi.StructLayout");

              
// in src/org/python/modules/jffi/Structure.java
throw Py.RuntimeError("reference memory already initialized");

              
// in src/org/python/modules/jffi/Structure.java
throw Py.NameError(String.format("struct %s has no field '%s'", getType().fastGetName(), key.toString()));

              
// in src/org/python/modules/jffi/CType.java
throw Py.TypeError("invalid _jffi_type");

              
// in src/org/python/modules/jffi/CType.java
throw Py.TypeError(String.format("__init__() takes exactly 2 arguments (%d given)", args.length));

              
// in src/org/python/modules/jffi/CType.java
throw Py.TypeError("invalid component type");

              
// in src/org/python/modules/jffi/CType.java
throw Py.TypeError("only scalar and struct types supported");

              
// in src/org/python/modules/jffi/CType.java
throw Py.TypeError("pointer only supported for scalar types");

              
// in src/org/python/modules/jffi/CType.java
throw Py.TypeError(String.format("__init__() takes exactly 1 argument (%d given)", args.length));

              
// in src/org/python/modules/jffi/CType.java
throw Py.TypeError("expected ctypes class");

              
// in src/org/python/modules/jffi/ScalarCData.java
throw Py.TypeError("invalid _jffi_type for " + subtype.getName());

              
// in src/org/python/modules/itertools.java
throw Py.TypeError("imap requires at least two arguments");

              
// in src/org/python/modules/itertools.java
throw Py.ValueError(msg);

              
// in src/org/python/modules/itertools.java
throw Py.ValueError("Indices for islice() must be non-negative integers");

              
// in src/org/python/modules/itertools.java
throw Py.ValueError("Step must be one or larger for islice()");

              
// in src/org/python/modules/itertools.java
throw Py.TypeError("izip argument #" + (i + 1)
                        + " must support iteration");

              
// in src/org/python/modules/itertools.java
throw Py.TypeError("starmap requires 2 arguments, got "
                    + starargs.length);

              
// in src/org/python/modules/itertools.java
throw Py.TypeError("iterator must return a tuple");

              
// in src/org/python/modules/itertools.java
throw Py.TypeError("groupby takes two arguments, iterable and key");

              
// in src/org/python/modules/_functools/PyPartialDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/modules/_functools/PyPartialDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/modules/_functools/PyPartialDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/modules/_functools/PyPartialDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/modules/_functools/PyPartialDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/modules/_functools/PyPartialDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/modules/_functools/PyPartialDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/modules/_functools/PyPartialDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/modules/_functools/PyPartialDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/modules/_functools/PyPartialDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/modules/_functools/PyPartialDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/modules/_functools/PyPartialDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/modules/_functools/PyPartialDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/modules/_functools/PyPartialDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/modules/_functools/PyPartialDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/modules/_functools/PyPartialDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/modules/_functools/PyPartialDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/modules/_functools/PyPartial.java
throw Py.TypeError("type 'partial' takes at least one argument");

              
// in src/org/python/modules/_functools/PyPartial.java
throw Py.TypeError("the first argument must be callable");

              
// in src/org/python/modules/_functools/PyPartial.java
throw Py.TypeError("setting partial object's dictionary to a non-dict");

              
// in src/org/python/modules/_functools/_functools.java
throw Py.TypeError("reduce of empty sequence with no initial value");

              
// in src/org/python/modules/cStringIO.java
throw Py.ValueError("I/O operation on closed file");

              
// in src/org/python/modules/cStringIO.java
throw Py.OverflowError("long int too large to convert to int");

              
// in src/org/python/modules/_threading/Lock.java
throw Py.AssertionError("release() of un-acquire()d lock");

              
// in src/org/python/modules/imp.java
throw Py.IOError(ioe);

              
// in src/org/python/modules/imp.java
throw Py.ImportError("No module named " + name);

              
// in src/org/python/modules/imp.java
throw Py.TypeError("must be a file-like object");

              
// in src/org/python/modules/imp.java
throw Py.TypeError("must be a file-like object");

              
// in src/org/python/modules/imp.java
throw Py.ImportError("No module named " + name);

              
// in src/org/python/modules/imp.java
throw Py.TypeError("must be a file-like object");

              
// in src/org/python/modules/imp.java
throw Py.ImportError("No module named " + name);

              
// in src/org/python/modules/imp.java
throw Py.RuntimeError("not holding the import lock");

              
// in src/org/python/modules/time/Time.java
throw info.unexpectedCall(0, false);

              
// in src/org/python/modules/time/Time.java
throw Py.ValueError("timestamp out of range for platform time_t");

              
// in src/org/python/modules/time/Time.java
throw Py.TypeError("a float is required");

              
// in src/org/python/modules/time/Time.java
throw Py.TypeError("expected string of buffer");

              
// in src/org/python/modules/time/PyTimeTuple.java
throw Py.TypeError("time.struct_time() takes a 9-sequence (1-sequence given)");

              
// in src/org/python/modules/time/PyTimeTuple.java
throw Py.TypeError("time.struct_time() takes a 9-sequence (1-sequence given)");

              
// in src/org/python/modules/synchronize.java
throw Py.TypeError("synchronized callable called with 0 args");

              
// in src/org/python/modules/synchronize.java
throw Py.TypeError("synchronized callable called with 0 args");

              
// in src/org/python/modules/PyTeeIterator.java
throw Py.TypeError("tee expected 1 arguments, got " + nargs);

              
// in src/org/python/modules/PyTeeIterator.java
throw Py.ValueError("n must be >= 0");

              
// in src/org/python/modules/_codecs.java
throw Py.TypeError("character mapping must return " + "integer greater than 0 and less than sys.maxunicode");

              
// in src/org/python/modules/_codecs.java
throw Py.TypeError("character mapping must return " + "integer, None or str");

              
// in src/org/python/modules/_codecs.java
throw Py.TypeError(String.format("character mapping must be in range(0x%x)",
                                                     PySystemState.maxunicode + 1));

              
// in src/org/python/modules/_codecs.java
throw Py.TypeError("character mapping must return integer, None or unicode");

              
// in src/org/python/modules/_codecs.java
throw Py.UnicodeEncodeError("charmap",
                            str,
                            i,
                            i + 1,
                            "character maps to <undefined>");

              
// in src/org/python/modules/_codecs.java
throw Py.TypeError("character mapping must be in range(256)");

              
// in src/org/python/modules/_codecs.java
throw Py.TypeError("character mapping must return " + "integer, None or str");

              
// in src/org/python/modules/_codecs.java
throw Py.TypeError("bad argument type for built-in operation");

              
// in src/org/python/modules/_hashlib.java
throw Py.ValueError("unsupported hash type");

              
// in src/org/python/modules/_hashlib.java
throw Py.RuntimeError(String.format("_hashlib.HASH (%s) internal error", name));

              
// in src/org/python/modules/_hashlib.java
throw Py.TypeError("update() argument 1 must be string or read-only buffer, not "
                                   + obj.getType().fastGetName());

              
// in src/org/python/core/PyBuiltinMethodNarrow.java
throw info.unexpectedCall(args.length, true);

              
// in src/org/python/core/PyBuiltinMethodNarrow.java
throw info.unexpectedCall(args.length, false);

              
// in src/org/python/core/PyBuiltinMethodNarrow.java
throw info.unexpectedCall(0, false);

              
// in src/org/python/core/PyBuiltinMethodNarrow.java
throw info.unexpectedCall(1, false);

              
// in src/org/python/core/PyBuiltinMethodNarrow.java
throw info.unexpectedCall(2, false);

              
// in src/org/python/core/PyBuiltinMethodNarrow.java
throw info.unexpectedCall(3, false);

              
// in src/org/python/core/PyBuiltinMethodNarrow.java
throw info.unexpectedCall(4, false);

              
// in src/org/python/core/PyBeanProperty.java
throw Py.AttributeError("instance attr: "+__name__);

              
// in src/org/python/core/PyBeanProperty.java
throw Py.AttributeError("write-only attr: "+__name__);

              
// in src/org/python/core/PyBeanProperty.java
throw Py.JavaError(e);

              
// in src/org/python/core/PyBeanProperty.java
throw Py.AttributeError("instance attr: "+__name__);

              
// in src/org/python/core/PyBeanProperty.java
throw Py.AttributeError("read-only attr: "+__name__);

              
// in src/org/python/core/PyBeanProperty.java
throw Py.JavaError(t);

              
// in src/org/python/core/PyBeanProperty.java
throw Py.JavaError(e);

              
// in src/org/python/core/JavaImporter.java
throw Py.ImportError("unable to handle");

              
// in src/org/python/core/PyClassMethod.java
throw Py.TypeError("'" + callable.getType().fastGetName() + "' object is not callable");

              
// in src/org/python/core/PyClassMethod.java
throw Py.TypeError("classmethod does not accept keyword arguments");

              
// in src/org/python/core/PyClassMethod.java
throw Py.TypeError("classmethod expected 1 argument, got " + args.length);

              
// in src/org/python/core/PyObject.java
throw Py.TypeError("object.__new__() takes no parameters");

              
// in src/org/python/core/PyObject.java
throw Py.TypeError(String.format("Can't instantiate abstract class %s with abstract "
                                             + "methods %s", subtype.fastGetName(), methods));

              
// in src/org/python/core/PyObject.java
throw Py.TypeError("__class__ assignment: only for heap types");

              
// in src/org/python/core/PyObject.java
throw Py.TypeError("can't delete __class__ attribute");

              
// in src/org/python/core/PyObject.java
throw Py.SystemError("Automatic proxy initialization should only occur on proxy classes");

              
// in src/org/python/core/PyObject.java
throw Py.TypeError(msg);

              
// in src/org/python/core/PyObject.java
throw Py.TypeError("constructor requires arguments");

              
// in src/org/python/core/PyObject.java
throw Py.JavaError(exc);

              
// in src/org/python/core/PyObject.java
throw Py.TypeError("Proxy instance already initialized");

              
// in src/org/python/core/PyObject.java
throw Py.TypeError("Proxy initialized with another instance");

              
// in src/org/python/core/PyObject.java
throw Py.TypeError(String.format("'%s' object is not callable", getType().fastGetName()));

              
// in src/org/python/core/PyObject.java
throw Py.TypeError(name
                        + "argument after ** must be a mapping");

              
// in src/org/python/core/PyObject.java
throw Py.TypeError(
                        name
                            + "got multiple values for "
                            + "keyword argument '"
                            + keyword
                            + "'");

              
// in src/org/python/core/PyObject.java
throw Py.TypeError(name + "keywords must be strings");

              
// in src/org/python/core/PyObject.java
throw Py.TypeError(String.format("object of type '%.200s' has no len()",
                                         getType().fastGetName()));

              
// in src/org/python/core/PyObject.java
throw Py.TypeError(String.format("'%.200s' object is unsubscriptable",
                                         getType().fastGetName()));

              
// in src/org/python/core/PyObject.java
throw Py.KeyError("" + key);

              
// in src/org/python/core/PyObject.java
throw Py.KeyError(key);

              
// in src/org/python/core/PyObject.java
throw Py.TypeError(String.format("'%.200s' object does not support item assignment",
                                         getType().fastGetName()));

              
// in src/org/python/core/PyObject.java
throw Py.TypeError(String.format("'%.200s' object doesn't support item deletion",
                                         getType().fastGetName()));

              
// in src/org/python/core/PyObject.java
throw Py.TypeError(String.format("'%.200s' object is not iterable",
                                         getType().fastGetName()));

              
// in src/org/python/core/PyObject.java
throw Py.AttributeError(String.format("'%.50s' object has no attribute '%.400s'",
                                              getType().fastGetName(), name));

              
// in src/org/python/core/PyObject.java
throw Py.TypeError("readonly attribute");

              
// in src/org/python/core/PyObject.java
throw Py.AttributeError("__coerce__");

              
// in src/org/python/core/PyObject.java
throw Py.ValueError("can't order recursive values");

              
// in src/org/python/core/PyObject.java
throw Py.ValueError("can't order recursive values");

              
// in src/org/python/core/PyObject.java
throw Py.ValueError("can't order recursive values");

              
// in src/org/python/core/PyObject.java
throw Py.ValueError("can't order recursive values");

              
// in src/org/python/core/PyObject.java
throw Py.TypeError("hex() argument can't be converted to hex");

              
// in src/org/python/core/PyObject.java
throw Py.TypeError("oct() argument can't be converted to oct");

              
// in src/org/python/core/PyObject.java
throw Py.AttributeError("__int__");

              
// in src/org/python/core/PyObject.java
throw Py.AttributeError("__long__");

              
// in src/org/python/core/PyObject.java
throw Py.AttributeError("__float__");

              
// in src/org/python/core/PyObject.java
throw Py.AttributeError("__complex__");

              
// in src/org/python/core/PyObject.java
throw Py.TypeError(String.format("bad operand type for unary +: '%.200s'",
                                         getType().fastGetName()));

              
// in src/org/python/core/PyObject.java
throw Py.TypeError(String.format("bad operand type for unary -: '%.200s'",
                                         getType().fastGetName()));

              
// in src/org/python/core/PyObject.java
throw Py.TypeError(String.format("bad operand type for abs(): '%.200s'",
                                         getType().fastGetName()));

              
// in src/org/python/core/PyObject.java
throw Py.TypeError(String.format("bad operand type for unary ~: '%.200s'",
                                         getType().fastGetName()));

              
// in src/org/python/core/PyObject.java
throw Py.TypeError(String.format("'%.200s' object cannot be interpreted as an index",
                                         getType().fastGetName()));

              
// in src/org/python/core/PyObject.java
throw Py.TypeError(_unsupportedop(op, o2));

              
// in src/org/python/core/PyObject.java
throw Py.TypeError(_unsupportedop("+",o2));

              
// in src/org/python/core/PyObject.java
throw Py.TypeError(_unsupportedop("-",o2));

              
// in src/org/python/core/PyObject.java
throw Py.TypeError(_unsupportedop("*",o2));

              
// in src/org/python/core/PyObject.java
throw Py.TypeError(_unsupportedop("/",o2));

              
// in src/org/python/core/PyObject.java
throw Py.TypeError(_unsupportedop("//",o2));

              
// in src/org/python/core/PyObject.java
throw Py.TypeError(_unsupportedop("/",o2));

              
// in src/org/python/core/PyObject.java
throw Py.TypeError(_unsupportedop("%",o2));

              
// in src/org/python/core/PyObject.java
throw Py.TypeError(_unsupportedop("divmod",o2));

              
// in src/org/python/core/PyObject.java
throw Py.TypeError(_unsupportedop("**",o2));

              
// in src/org/python/core/PyObject.java
throw Py.TypeError(_unsupportedop("<<",o2));

              
// in src/org/python/core/PyObject.java
throw Py.TypeError(_unsupportedop(">>",o2));

              
// in src/org/python/core/PyObject.java
throw Py.TypeError(_unsupportedop("&",o2));

              
// in src/org/python/core/PyObject.java
throw Py.TypeError(_unsupportedop("|",o2));

              
// in src/org/python/core/PyObject.java
throw Py.TypeError(_unsupportedop("^",o2));

              
// in src/org/python/core/PyObject.java
throw Py.JavaError(t);

              
// in src/org/python/core/PyObject.java
throw Py.TypeError("can't set attribute '__dict__' of instance of " + getType().fastGetName());

              
// in src/org/python/core/PyObject.java
throw Py.TypeError("can't delete attribute '__dict__' of instance of '" + getType().fastGetName()+ "'");

              
// in src/org/python/core/PyObject.java
throw Py.AttributeError("object internal __set__ impl is abstract");

              
// in src/org/python/core/PyObject.java
throw Py.AttributeError("object internal __delete__ impl is abstract");

              
// in src/org/python/core/PyObject.java
throw Py.TypeError("attribute name must be a string");

              
// in src/org/python/core/PyObject.java
throw Py.TypeError(String.format("can't apply this %s to %s object", what,
                                             objtype.fastGetName()));

              
// in src/org/python/core/PyObject.java
throw Py.TypeError("copy_reg._slotnames didn't return a list or None");

              
// in src/org/python/core/PyObject.java
throw Py.TypeError("__getnewargs__ should return a tuple");

              
// in src/org/python/core/PyObject.java
throw Py.AssertionError("slots not a list");

              
// in src/org/python/core/PyObject.java
throw Py.TypeError("expected a str");

              
// in src/org/python/core/PyObject.java
throw Py.TypeError("an integer is required");

              
// in src/org/python/core/PyObject.java
throw Py.TypeError("nb_int should return int object");

              
// in src/org/python/core/PyObject.java
throw Py.TypeError("an integer is required");

              
// in src/org/python/core/PyObject.java
throw Py.TypeError("integer conversion failed");

              
// in src/org/python/core/PyObject.java
throw Py.TypeError("a float is required");

              
// in src/org/python/core/PyStringMap.java
throw Py.KeyError("'" + key + "'");

              
// in src/org/python/core/PyStringMap.java
throw Py.KeyError("'" + key.toString() + "'");

              
// in src/org/python/core/PyStringMap.java
throw Py.KeyError(key);

              
// in src/org/python/core/PyStringMap.java
throw Py.KeyError(key.toString());

              
// in src/org/python/core/PyStringMap.java
throw PyBuiltinCallable.DefaultInfo.unexpectedCall(nargs, false, "update", 0, 1);

              
// in src/org/python/core/PyStringMap.java
throw Py.TypeError(String.format("cannot convert dictionary update sequence "
                                                     + "element #%d to a sequence", i));

              
// in src/org/python/core/PyStringMap.java
throw Py.ValueError(String.format("dictionary update sequence element #%d "
                                                  + "has length %d; 2 is required", i, n));

              
// in src/org/python/core/PyStringMap.java
throw Py.KeyError("popitem(): dictionary is empty");

              
// in src/org/python/core/PyStringMap.java
throw Py.KeyError("pop(): dictionary is empty");

              
// in src/org/python/core/PyStringMap.java
throw Py.KeyError(key.__repr__().toString());

              
// in src/org/python/core/PyStringMap.java
throw Py.TypeError(String.format("unhashable type: '%.200s'", getType().fastGetName()));

              
// in src/org/python/core/PyStringMap.java
throw Py.RuntimeError("dictionary changed size during iteration");

              
// in src/org/python/core/PyJavaPackage.java
throw Py.TypeError("cannot set java package __mgr__ to None");

              
// in src/org/python/core/PyList.java
throw Py.MemoryError("");

              
// in src/org/python/core/PyList.java
throw Py.MemoryError("");

              
// in src/org/python/core/PyList.java
throw Py.IndexError("index out of range: " + o);

              
// in src/org/python/core/PyList.java
throw Py.ValueError(message);

              
// in src/org/python/core/PyList.java
throw Py.ValueError(message);

              
// in src/org/python/core/PyList.java
throw Py.IndexError("pop from empty list");

              
// in src/org/python/core/PyList.java
throw Py.IndexError("pop index out of range");

              
// in src/org/python/core/PyList.java
throw Py.ValueError("list modified during sort");

              
// in src/org/python/core/PyList.java
throw Py.ValueError("list modified during sort");

              
// in src/org/python/core/PyList.java
throw Py.ValueError("list modified during sort");

              
// in src/org/python/core/PyList.java
throw Py.TypeError(String.format("unhashable type: '%.200s'", getType().fastGetName()));

              
// in src/org/python/core/PyProperty.java
throw Py.AttributeError("unreadable attribute");

              
// in src/org/python/core/PyProperty.java
throw Py.AttributeError("can't set attribute");

              
// in src/org/python/core/PyProperty.java
throw Py.AttributeError("can't delete attribute");

              
// in src/org/python/core/PyFloatDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/core/PyFloatDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyFloatDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyFloatDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyFloatDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyFloatDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyFloatDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyFloatDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/core/PyFloatDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyFloatDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/core/PyFloatDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/core/PyFloatDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/core/PyFloatDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/core/PyFloatDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/core/PyFloatDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/core/PyFloatDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/core/PyFloatDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/core/PyFloatDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyUnicode.java
throw Py.TypeError("decoder did not return an unicode object (type=" +
                            decoded.getType().fastGetName() + ")");

              
// in src/org/python/core/PyUnicode.java
throw Py.TypeError("coercing to Unicode: need string or buffer, " +
                    o.getType().fastGetName() + "found");

              
// in src/org/python/core/PyUnicode.java
throw Py.TypeError("strip arg must be None, unicode or str");

              
// in src/org/python/core/PyUnicode.java
throw Py.ValueError("empty separator");

              
// in src/org/python/core/PyUnicode.java
throw Py.TypeError(function + "() argument 2 must be char, not str");

              
// in src/org/python/core/PySuper.java
throw PyBuiltinCallable.DefaultInfo.unexpectedCall(args.length, keywords.length != 0,
                                                               "super", 1, 2);

              
// in src/org/python/core/PySuper.java
throw Py.TypeError("super: argument 1 must be type");

              
// in src/org/python/core/PySuper.java
throw Py.TypeError("super(type, obj): obj must be an instance or subtype of type");

              
// in src/org/python/core/PyClass.java
throw Py.TypeError("PyClass_New: name must be a string");

              
// in src/org/python/core/PyClass.java
throw Py.TypeError("PyClass_New: dict must be a dictionary");

              
// in src/org/python/core/PyClass.java
throw Py.TypeError("PyClass_New: bases must be a tuple");

              
// in src/org/python/core/PyClass.java
throw Py.TypeError("PyClass_New: base must be a class");

              
// in src/org/python/core/PyClass.java
throw Py.AttributeError(String.format("class %.50s has no attribute '%.400s'", __name__,
                                              name));

              
// in src/org/python/core/PyClass.java
throw Py.TypeError("__dict__ must be a dictionary object");

              
// in src/org/python/core/PyClass.java
throw Py.TypeError("__bases__ must be a tuple object");

              
// in src/org/python/core/PyClass.java
throw Py.TypeError("__bases__ items must be classes");

              
// in src/org/python/core/PyClass.java
throw Py.TypeError("a __bases__ item causes an inheritance cycle");

              
// in src/org/python/core/PyClass.java
throw Py.TypeError("__name__ must be a string object");

              
// in src/org/python/core/PyClass.java
throw Py.TypeError("__name__ must not contain null bytes");

              
// in src/org/python/core/PyArrayDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/core/PyArrayDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyArrayDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyArrayDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyArrayDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyArrayDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyArrayDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyArrayDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/core/PyArrayDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyArrayDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/core/PyArrayDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/core/PyArrayDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/core/PyArrayDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/core/PyArrayDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/core/PyArrayDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/core/PyArrayDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/core/PyArrayDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/core/PyArrayDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyReflectedConstructor.java
throw Py.JavaError(t);

              
// in src/org/python/core/PyReflectedConstructor.java
throw Py.TypeError("invalid self argument to constructor");

              
// in src/org/python/core/PyReflectedConstructor.java
throw Py.TypeError("self invalid - must be a Java subclass [self=" + self + "]");

              
// in src/org/python/core/PyReflectedConstructor.java
throw Py.TypeError("No visible constructors for class (" + javaClass.getName() + ")");

              
// in src/org/python/core/PyReflectedConstructor.java
throw Py.TypeError("self invalid - must implement: " + declaringClass.getName());

              
// in src/org/python/core/PyReflectedConstructor.java
throw Py.TypeError("can't instantiate interface (" + declaringClass.getName() + ")");

              
// in src/org/python/core/PyReflectedConstructor.java
throw Py.TypeError("can't instantiate abstract class (" + declaringClass.getName() + ")");

              
// in src/org/python/core/PyReflectedConstructor.java
throw Py.TypeError("instance already instantiated for " + sup.getName());

              
// in src/org/python/core/PyReflectedConstructor.java
throw Py.TypeError("constructor requires self argument");

              
// in src/org/python/core/PyReflectedConstructor.java
throw Py.TypeError(msg);

              
// in src/org/python/core/PyReflectedConstructor.java
throw Py.JavaError(e);

              
// in src/org/python/core/PyReflectedConstructor.java
throw Py.JavaError(t);

              
// in src/org/python/core/PyMethodDescr.java
throw Py.TypeError(name + " requires at least one argument");

              
// in src/org/python/core/PyTuple.java
throw Py.MemoryError("");

              
// in src/org/python/core/PyTuple.java
throw Py.IndexError("index out of range: " + index);

              
// in src/org/python/core/PyTuple.java
throw Py.TypeError("'tuple' object does not support item assignment");

              
// in src/org/python/core/PyTuple.java
throw Py.ValueError("tuple.index(x): x not in list");

              
// in src/org/python/core/PyEnumerateDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/core/PyEnumerateDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyEnumerateDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyEnumerateDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyEnumerateDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyEnumerateDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyEnumerateDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyEnumerateDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/core/PyEnumerateDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyEnumerateDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/core/PyEnumerateDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/core/PyEnumerateDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/core/PyEnumerateDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/core/PyEnumerateDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/core/PyEnumerateDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/core/PyEnumerateDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/core/PyEnumerateDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/core/PyEnumerateDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PySystemState.java
throw Py.TypeError("readonly attribute");

              
// in src/org/python/core/PySystemState.java
throw Py.TypeError("readonly attribute");

              
// in src/org/python/core/PySystemState.java
throw Py.AttributeError(name);

              
// in src/org/python/core/PySystemState.java
throw Py.ValueError("Recursion limit must be positive");

              
// in src/org/python/core/PySystemState.java
throw Py.ValueError("call stack is not deep enough");

              
// in src/org/python/core/PySystemState.java
throw info.unexpectedCall(1, false);

              
// in src/org/python/core/PySystemState.java
throw info.unexpectedCall(3, false);

              
// in src/org/python/core/PyDataDescr.java
throw Py.TypeError(String.format("unsupported type for assignment to %s: '%.200s'",
                                             name, value.getType().fastGetName()));

              
// in src/org/python/core/MakeProxies.java
throw Py.JavaError(exc);

              
// in src/org/python/core/MakeProxies.java
throw Py.JavaError(exc);

              
// in src/org/python/core/BytecodeLoader.java
throw Py.JavaError(e);

              
// in src/org/python/core/PySet.java
throw PyBuiltinCallable.DefaultInfo.unexpectedCall(nargs, false, "Set", 0, 1);

              
// in src/org/python/core/PySet.java
throw Py.TypeError("set objects are unhashable");

              
// in src/org/python/core/PyDictionary.java
throw Py.TypeError("loop over non-sequence");

              
// in src/org/python/core/PyDictionary.java
throw Py.KeyError(key);

              
// in src/org/python/core/PyDictionary.java
throw Py.KeyError(key.toString());

              
// in src/org/python/core/PyDictionary.java
throw PyBuiltinCallable.DefaultInfo.unexpectedCall(nargs, false, methName, 0, 1);

              
// in src/org/python/core/PyDictionary.java
throw Py.TypeError(String.format("cannot convert dictionary update sequence "
                                                     + "element #%d to a sequence", i));

              
// in src/org/python/core/PyDictionary.java
throw Py.ValueError(String.format("dictionary update sequence element #%d "
                                                  + "has length %d; 2 is required", i, n));

              
// in src/org/python/core/PyDictionary.java
throw Py.KeyError("popitem(): dictionary is empty");

              
// in src/org/python/core/PyDictionary.java
throw Py.KeyError("popitem(): dictionary is empty");

              
// in src/org/python/core/PyDictionary.java
throw Py.TypeError(String.format("unhashable type: '%.200s'", getType().fastGetName()));

              
// in src/org/python/core/PyDictionary.java
throw Py.RuntimeError("dictionary changed size during iteration");

              
// in src/org/python/core/PyDictionary.java
throw Py.RuntimeError("dictionary changed size during iteration");

              
// in src/org/python/core/PyFileWriter.java
throw Py.ValueError("I/O operation on closed file");

              
// in src/org/python/core/PyFileWriter.java
throw Py.IOError(e);

              
// in src/org/python/core/PyFileWriter.java
throw Py.IOError(e);

              
// in src/org/python/core/PyFileWriter.java
throw Py.TypeError("write requires a string as its argument");

              
// in src/org/python/core/PyFileWriter.java
throw Py.IOError(e);

              
// in src/org/python/core/PyFileWriter.java
throw Py.TypeError("writelines() argument must be a sequence of strings");

              
// in src/org/python/core/PyUnicodeDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/core/PyUnicodeDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyUnicodeDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyUnicodeDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyUnicodeDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyUnicodeDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyUnicodeDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyUnicodeDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/core/PyUnicodeDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyUnicodeDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/core/PyUnicodeDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/core/PyUnicodeDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/core/PyUnicodeDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/core/PyUnicodeDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/core/PyUnicodeDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/core/PyUnicodeDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/core/PyUnicodeDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/core/PyFile.java
throw Py.TypeError("coercing to Unicode: need string, '" + name.getType().fastGetName()
                               + "' type found");

              
// in src/org/python/core/PyFile.java
throw Py.ValueError("unknown mode: '" + mode + "'");

              
// in src/org/python/core/PyFile.java
throw Py.ValueError("empty mode string");

              
// in src/org/python/core/PyFile.java
throw Py.ValueError("universal newline mode can only be used with modes starting "
                                    + "with 'r'");

              
// in src/org/python/core/PyFile.java
throw Py.ValueError("mode string must begin with one of 'r', 'w', 'a' or 'U', not '"
                                + origMode + "'");

              
// in src/org/python/core/PyFile.java
throw Py.StopIteration("");

              
// in src/org/python/core/PyFile.java
throw Py.TypeError(message);

              
// in src/org/python/core/PyFile.java
throw Py.TypeError("can't delete numeric/char attribute");

              
// in src/org/python/core/PyTableCode.java
throw Py.TypeError("readonly attribute");

              
// in src/org/python/core/PyTableCode.java
throw Py.AttributeError(name);

              
// in src/org/python/core/PyComplex.java
throw Py.TypeError("complex() can't take second arg if first is a string");

              
// in src/org/python/core/PyComplex.java
throw Py.TypeError("complex() second arg can't be a string");

              
// in src/org/python/core/PyComplex.java
throw Py.TypeError("complex() argument must be a string or a number");

              
// in src/org/python/core/PyComplex.java
throw Py.TypeError("complex() argument must be a string or a number");

              
// in src/org/python/core/PyComplex.java
throw Py.TypeError("cannot compare complex numbers using <, <=, >, >=");

              
// in src/org/python/core/PyComplex.java
throw Py.TypeError("xxx");

              
// in src/org/python/core/PyComplex.java
throw Py.ZeroDivisionError("complex division");

              
// in src/org/python/core/PyComplex.java
throw Py.ValueError("complex modulo");

              
// in src/org/python/core/PyComplex.java
throw Py.ZeroDivisionError("0.0 to a negative or complex power");

              
// in src/org/python/core/PyComplex.java
throw Py.TypeError("bad operand type for unary ~");

              
// in src/org/python/core/PyComplex.java
throw Py.TypeError("can't convert complex to int; use e.g. int(abs(z))");

              
// in src/org/python/core/PyComplex.java
throw Py.TypeError("can't convert complex to long; use e.g. long(abs(z))");

              
// in src/org/python/core/PyComplex.java
throw Py.TypeError("can't convert complex to float; use e.g. abs(z)");

              
// in src/org/python/core/PyReflectedField.java
throw Py.JavaError(exc);

              
// in src/org/python/core/PyReflectedField.java
throw Py.AttributeError("set instance variable as static: " + field.toString());

              
// in src/org/python/core/PyReflectedField.java
throw Py.JavaError(exc);

              
// in src/org/python/core/PyInstance.java
throw Py.TypeError("instance() second arg must be dictionary or None");

              
// in src/org/python/core/PyInstance.java
throw Py.ValueError("Can't find module for class: "+
                                instclass.__name__);

              
// in src/org/python/core/PyInstance.java
throw Py.ValueError("Can't find module for class with no name");

              
// in src/org/python/core/PyInstance.java
throw Py.TypeError("this constructor takes no arguments");

              
// in src/org/python/core/PyInstance.java
throw Py.TypeError("__init__() should return None");

              
// in src/org/python/core/PyInstance.java
throw Py.AttributeError(String.format("%.50s instance has no attribute '%.400s'",
                                              instclass.__name__, name));

              
// in src/org/python/core/PyInstance.java
throw Py.TypeError("__class__ must be set to a class");

              
// in src/org/python/core/PyInstance.java
throw Py.AttributeError("class " + instclass.__name__ +
                                        " has no attribute '" + name + "'");

              
// in src/org/python/core/PyInstance.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/core/PyInstance.java
throw Py.TypeError("__repr__ method must return a string");

              
// in src/org/python/core/PyInstance.java
throw Py.TypeError("__str__ method must return a string");

              
// in src/org/python/core/PyInstance.java
throw Py.TypeError("__unicode__ must return unicode or str");

              
// in src/org/python/core/PyInstance.java
throw Py.TypeError("unhashable instance");

              
// in src/org/python/core/PyInstance.java
throw Py.TypeError("__hash__() must really return int" + ret.getType() );

              
// in src/org/python/core/PyInstance.java
throw Py.TypeError("__cmp__() must return int");

              
// in src/org/python/core/PyInstance.java
throw Py.TypeError("__cmp__() must return int");

              
// in src/org/python/core/PyInstance.java
throw Py.TypeError("__len__() should return an int");

              
// in src/org/python/core/PyInstance.java
throw Py.TypeError("instance has no next() method");

              
// in src/org/python/core/PyInstance.java
throw Py.TypeError("coercion should return None or 2-tuple");

              
// in src/org/python/core/PyInstance.java
throw Py.TypeError("object cannot be interpreted as an index");

              
// in src/org/python/core/PyInstance.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",
                                         ret.getType().fastGetName()));

              
// in src/org/python/core/PyInstance.java
throw Py.TypeError("__hex__() should return a string");

              
// in src/org/python/core/PyInstance.java
throw Py.TypeError("__oct__() should return a string");

              
// in src/org/python/core/PyInstance.java
throw Py.TypeError("__int__() should return a int");

              
// in src/org/python/core/PyInstance.java
throw Py.TypeError("__float__() should return a float");

              
// in src/org/python/core/PyInstance.java
throw Py.TypeError("__long__() should return a long");

              
// in src/org/python/core/PyInstance.java
throw Py.TypeError("__complex__() should return a complex");

              
// in src/org/python/core/PyInstance.java
throw Py.RuntimeError("maximum recursion depth exceeded");

              
// in src/org/python/core/PyInstance.java
throw Py.RuntimeError("maximum recursion depth exceeded");

              
// in src/org/python/core/PyInstance.java
throw Py.RuntimeError("maximum recursion depth exceeded");

              
// in src/org/python/core/PyInstance.java
throw Py.RuntimeError("maximum recursion depth exceeded");

              
// in src/org/python/core/PyInstance.java
throw Py.RuntimeError("maximum recursion depth exceeded");

              
// in src/org/python/core/PyInstance.java
throw Py.RuntimeError("maximum recursion depth exceeded");

              
// in src/org/python/core/PyInstance.java
throw Py.RuntimeError("maximum recursion depth exceeded");

              
// in src/org/python/core/PyInstance.java
throw Py.RuntimeError("maximum recursion depth exceeded");

              
// in src/org/python/core/PyInstance.java
throw Py.RuntimeError("maximum recursion depth exceeded");

              
// in src/org/python/core/PyInstance.java
throw Py.RuntimeError("maximum recursion depth exceeded");

              
// in src/org/python/core/PyInstance.java
throw Py.RuntimeError("maximum recursion depth exceeded");

              
// in src/org/python/core/PyInstance.java
throw Py.RuntimeError("maximum recursion depth exceeded");

              
// in src/org/python/core/PyInstance.java
throw Py.RuntimeError("maximum recursion depth exceeded");

              
// in src/org/python/core/PyInstance.java
throw Py.RuntimeError("maximum recursion depth exceeded");

              
// in src/org/python/core/PyInstance.java
throw Py.RuntimeError("maximum recursion depth exceeded");

              
// in src/org/python/core/PyInstance.java
throw Py.RuntimeError("maximum recursion depth exceeded");

              
// in src/org/python/core/PyInstance.java
throw Py.RuntimeError("maximum recursion depth exceeded");

              
// in src/org/python/core/PyInstance.java
throw Py.RuntimeError("maximum recursion depth exceeded");

              
// in src/org/python/core/PyInstance.java
throw Py.RuntimeError("maximum recursion depth exceeded");

              
// in src/org/python/core/PyInstance.java
throw Py.RuntimeError("maximum recursion depth exceeded");

              
// in src/org/python/core/PyInstance.java
throw Py.RuntimeError("maximum recursion depth exceeded");

              
// in src/org/python/core/PyInstance.java
throw Py.RuntimeError("maximum recursion depth exceeded");

              
// in src/org/python/core/PyInstance.java
throw Py.RuntimeError("maximum recursion depth exceeded");

              
// in src/org/python/core/PyInstance.java
throw Py.RuntimeError("maximum recursion depth exceeded");

              
// in src/org/python/core/PyInstance.java
throw Py.RuntimeError("maximum recursion depth exceeded");

              
// in src/org/python/core/PyInstance.java
throw Py.RuntimeError("maximum recursion depth exceeded");

              
// in src/org/python/core/PyInstance.java
throw Py.RuntimeError("maximum recursion depth exceeded");

              
// in src/org/python/core/PyInstance.java
throw Py.RuntimeError("maximum recursion depth exceeded");

              
// in src/org/python/core/PyBaseException.java
throw Py.TypeError("state is not a dictionary");

              
// in src/org/python/core/PyBaseException.java
throw Py.TypeError("__dict__ must be a dictionary");

              
// in src/org/python/core/PyBaseException.java
throw Py.AttributeError("message attribute was deleted");

              
// in src/org/python/core/ContextGuard.java
throw Py.TypeError("Argument must be a generator function.");

              
// in src/org/python/core/ContextGuard.java
throw Py.RuntimeError("generator didn't yield");

              
// in src/org/python/core/ContextGuard.java
throw Py.RuntimeError("generator didn't stop");

              
// in src/org/python/core/PyReflectedFunction.java
throw Py.SystemError(msg);

              
// in src/org/python/core/PyReflectedFunction.java
throw Py.JavaError(e);

              
// in src/org/python/core/PyReflectedFunction.java
throw Py.JavaError(t);

              
// in src/org/python/core/PyReflectedFunction.java
throw Py.TypeError(__name__ + "(): " + message);

              
// in src/org/python/core/PyFrame.java
throw Py.UnboundLocalError(String.format(UNBOUNDLOCAL_ERROR_MSG, name));

              
// in src/org/python/core/PyFrame.java
throw Py.NameError(String.format(NAME_ERROR_MSG, index));

              
// in src/org/python/core/PyFrame.java
throw Py.NameError(String.format(GLOBAL_NAME_ERROR_MSG, index));

              
// in src/org/python/core/PyFrame.java
throw Py.SystemError(String.format("no locals found when storing '%s'", value));

              
// in src/org/python/core/PyFrame.java
throw Py.UnboundLocalError(String.format(UNBOUNDLOCAL_ERROR_MSG,
                                                         f_code.co_varnames[index]));

              
// in src/org/python/core/PyFrame.java
throw Py.NameError(String.format(NAME_ERROR_MSG, index));

              
// in src/org/python/core/PyFrame.java
throw Py.SystemError(String.format("no locals when deleting '%s'", index));

              
// in src/org/python/core/PyFrame.java
throw Py.NameError(String.format(GLOBAL_NAME_ERROR_MSG, index));

              
// in src/org/python/core/PyFrame.java
throw Py.UnboundLocalError(String.format(UNBOUNDLOCAL_ERROR_MSG, name));

              
// in src/org/python/core/PyLongDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/core/PyLongDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyLongDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyLongDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyLongDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyLongDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyLongDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyLongDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/core/PyLongDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyLongDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/core/PyLongDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/core/PyLongDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/core/PyLongDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/core/PyLongDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/core/PyLongDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/core/PyLongDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/core/PyLongDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/core/PyLongDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyBeanEventProperty.java
throw Py.JavaError(exc);

              
// in src/org/python/core/PyBeanEventProperty.java
throw Py.JavaError(e);

              
// in src/org/python/core/PyBeanEventProperty.java
throw Py.AttributeError("Internal bean event error: " + __name__);

              
// in src/org/python/core/PyBeanEventProperty.java
throw Py.JavaError(exc);

              
// in src/org/python/core/AstList.java
throw Py.IndexError("index out of range: " + o);

              
// in src/org/python/core/AstList.java
throw Py.MemoryError("");

              
// in src/org/python/core/AstList.java
throw Py.ValueError(message);

              
// in src/org/python/core/AstList.java
throw Py.MemoryError("");

              
// in src/org/python/core/AstList.java
throw Py.TypeError("setslice with java.util.List and step != 1 not supported yet");

              
// in src/org/python/core/AstList.java
throw Py.TypeError("can only assign an iterable");

              
// in src/org/python/core/PyFloat.java
throw Py.TypeError("float() argument must be a string or a number");

              
// in src/org/python/core/PyFloat.java
throw Py.TypeError("xxx");

              
// in src/org/python/core/PyFloat.java
throw Py.ZeroDivisionError("float division");

              
// in src/org/python/core/PyFloat.java
throw Py.ZeroDivisionError("float division");

              
// in src/org/python/core/PyFloat.java
throw Py.ZeroDivisionError("float division");

              
// in src/org/python/core/PyFloat.java
throw Py.ZeroDivisionError("float division");

              
// in src/org/python/core/PyFloat.java
throw Py.ZeroDivisionError("float division");

              
// in src/org/python/core/PyFloat.java
throw Py.ZeroDivisionError("float division");

              
// in src/org/python/core/PyFloat.java
throw Py.ZeroDivisionError("float modulo");

              
// in src/org/python/core/PyFloat.java
throw Py.ZeroDivisionError("float division");

              
// in src/org/python/core/PyFloat.java
throw Py.ZeroDivisionError("float division");

              
// in src/org/python/core/PyFloat.java
throw Py.TypeError("pow() 3rd argument not allowed unless all arguments are integers");

              
// in src/org/python/core/PyFloat.java
throw Py.ZeroDivisionError("0.0 cannot be raised to a negative power");

              
// in src/org/python/core/PyFloat.java
throw Py.ValueError("negative number cannot be raised to a fractional power");

              
// in src/org/python/core/PyFloat.java
throw Py.TypeError("bad operand type for unary ~");

              
// in src/org/python/core/PyFloat.java
throw Py.ValueError("__getformat__() argument 1 must be 'double' or 'float'");

              
// in src/org/python/core/PyFloat.java
throw Py.ValueError("__setformat__() argument 1 must be 'double' or 'float'");

              
// in src/org/python/core/PyFloat.java
throw Py.ValueError(String.format("can only set %s format to 'unknown' or the "
                                              + "detected platform value", typestr));

              
// in src/org/python/core/PyFloat.java
throw Py.ValueError("__setformat__() argument 2 must be 'unknown', " +
                                "'IEEE, little-endian' or 'IEEE, big-endian'");

              
// in src/org/python/core/PyBeanEvent.java
throw Py.TypeError("write only attribute");

              
// in src/org/python/core/PyBeanEvent.java
throw Py.TypeError("can't delete this attribute");

              
// in src/org/python/core/PyBeanEvent.java
throw Py.JavaError(e);

              
// in src/org/python/core/PySlice.java
throw Py.TypeError("slice expected at least 1 arguments, got " + args.length);

              
// in src/org/python/core/PySlice.java
throw Py.TypeError("slice expected at most 3 arguments, got " + args.length);

              
// in src/org/python/core/PySlice.java
throw Py.TypeError(String.format("unhashable type: '%.200s'", getType().fastGetName()));

              
// in src/org/python/core/PySlice.java
throw Py.ValueError("slice step cannot be zero");

              
// in src/org/python/core/PySlice.java
throw Py.TypeError("slice indices must be integers or None or have an __index__ method");

              
// in src/org/python/core/PyDescriptor.java
throw Py.TypeError(msg);

              
// in src/org/python/core/PyDescriptor.java
throw Py.TypeError(msg);

              
// in src/org/python/core/PyIntegerDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/core/PyIntegerDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyIntegerDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyIntegerDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyIntegerDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyIntegerDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyIntegerDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyIntegerDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/core/PyIntegerDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyIntegerDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/core/PyIntegerDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/core/PyIntegerDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/core/PyIntegerDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/core/PyIntegerDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/core/PyIntegerDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/core/PyIntegerDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/core/PyIntegerDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/core/PyIntegerDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyIterator.java
throw Py.StopIteration("");

              
// in src/org/python/core/PyBaseExceptionDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyBaseExceptionDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyBaseExceptionDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyBaseExceptionDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyBaseExceptionDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyBaseExceptionDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyBaseExceptionDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/core/PyBaseExceptionDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyBaseExceptionDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/core/PyBaseExceptionDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/core/PyBaseExceptionDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/core/PyBaseExceptionDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/core/PyBaseExceptionDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/core/PyBaseExceptionDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/core/PyBaseExceptionDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/core/PyBaseExceptionDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/core/PyBaseExceptionDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/ArgParser.java
throw PyBuiltinCallable.DefaultInfo.unexpectedCall(args.length,
                    false, funcname, minargs, this.params.length);

              
// in src/org/python/core/ArgParser.java
throw AST.unexpectedCall(minargs,  funcname);

              
// in src/org/python/core/ArgParser.java
throw Py.TypeError(String.format("argument %d must be %s, not %s", pos + 1,
                                             type.fastGetName(), arg.getType().fastGetName()));

              
// in src/org/python/core/ArgParser.java
throw Py.TypeError(String.format("%s does not take keyword arguments", funcname));

              
// in src/org/python/core/ArgParser.java
throw Py.TypeError("keyword parameter '"
                                + params[j]
                                + "' was given by position and by name");

              
// in src/org/python/core/ArgParser.java
throw Py.TypeError(String.format(
                                "%s got multiple values for keyword argument '%s'",
                                funcname, params[j]));

              
// in src/org/python/core/ArgParser.java
throw Py.TypeError("'" + kws[i] + "' is an invalid keyword "
                    + "argument for this function");

              
// in src/org/python/core/ArgParser.java
throw Py.TypeError(this.funcname + ": The " + ordinal(pos)
                    + " argument is required");

              
// in src/org/python/core/ArgParser.java
throw Py.TypeError("argument " + (pos + 1) + ": expected "
                    + classname + ", " + value.getType().fastGetName() + " found");

              
// in src/org/python/core/PyBaseCode.java
throw Py.TypeError(msg);

              
// in src/org/python/core/PyBaseCode.java
throw Py.TypeError(String.format("%.200s() got an unexpected keyword "
                                                         + "argument '%.400s'",
                                                         co_name, keyword));

              
// in src/org/python/core/PyBaseCode.java
throw Py.TypeError(String.format("%.200s() got multiple values for "
                                                         + "keyword argument '%.400s'",
                                                         co_name, keyword));

              
// in src/org/python/core/PyBaseCode.java
throw Py.TypeError(msg);

              
// in src/org/python/core/PyBaseCode.java
throw Py.TypeError(String.format("%.200s() takes no arguments (%d given)",
                                             co_name, argcount));

              
// in src/org/python/core/SequenceIndexDelegate.java
throw Py.TypeError(getTypeName() + " indices must be integers");

              
// in src/org/python/core/SequenceIndexDelegate.java
throw Py.ValueError(String.format("attempt to assign sequence of size %d to extended "
                                              + "slice of size %d", value.__len__(), indices[3]));

              
// in src/org/python/core/SequenceIndexDelegate.java
throw Py.TypeError(getTypeName() + " indices must be integers");

              
// in src/org/python/core/SequenceIndexDelegate.java
throw Py.IndexError("index out of range: " + idx);

              
// in src/org/python/core/SequenceIndexDelegate.java
throw Py.TypeError(getTypeName() + " indices must be integers");

              
// in src/org/python/core/SequenceIndexDelegate.java
throw Py.IndexError(getTypeName() + " assignment index out of range");

              
// in src/org/python/core/io/RawIOBase.java
throw Py.OverflowError("requested number of bytes is more than a Python "
                                           + "string can hold");

              
// in src/org/python/core/io/TextIOBase.java
throw Py.TypeError("Cannot use string as modifiable buffer");

              
// in src/org/python/core/io/TextIOBase.java
throw Py.TypeError("argument 1 must be read-write buffer, not "
                               + buf.getType().fastGetName());

              
// in src/org/python/core/io/ServerSocketIO.java
throw Py.IOError(Errno.ENOTCONN);

              
// in src/org/python/core/io/ServerSocketIO.java
throw Py.IOError(Errno.EBADF);

              
// in src/org/python/core/io/IOBase.java
throw Py.IOError(Errno.EBADF);

              
// in src/org/python/core/io/IOBase.java
throw Py.IOError(Errno.EBADF);

              
// in src/org/python/core/io/IOBase.java
throw Py.ValueError("I/O operation on closed file");

              
// in src/org/python/core/io/IOBase.java
throw Py.IOError(String.format("%s.%s() not supported", className, methodName));

              
// in src/org/python/core/io/StreamIO.java
throw Py.IOError(ioe);

              
// in src/org/python/core/io/StreamIO.java
throw Py.IOError(ioe);

              
// in src/org/python/core/io/StreamIO.java
throw Py.IOError(ioe);

              
// in src/org/python/core/io/StreamIO.java
throw Py.IOError(ioe);

              
// in src/org/python/core/io/SocketIOBase.java
throw Py.ValueError("invalid mode: '" + mode + "'");

              
// in src/org/python/core/io/SocketIOBase.java
throw Py.IOError(ioe);

              
// in src/org/python/core/io/FileIO.java
throw Py.IOError(Errno.EISDIR, name);

              
// in src/org/python/core/io/FileIO.java
throw Py.IOError(Errno.EACCES, name);

              
// in src/org/python/core/io/FileIO.java
throw Py.IOError(Errno.ENOENT, name);

              
// in src/org/python/core/io/FileIO.java
throw Py.ValueError("invalid mode: '" + mode + "'");

              
// in src/org/python/core/io/FileIO.java
throw Py.ValueError("Must have exactly one of read/write/append mode");

              
// in src/org/python/core/io/FileIO.java
throw Py.IOError(ioe);

              
// in src/org/python/core/io/FileIO.java
throw Py.IOError(ioe);

              
// in src/org/python/core/io/FileIO.java
throw Py.IOError(ioe);

              
// in src/org/python/core/io/FileIO.java
throw Py.IOError(ioe);

              
// in src/org/python/core/io/FileIO.java
throw Py.OverflowError("requested number of bytes is more than a Python string can "
                                   + "hold");

              
// in src/org/python/core/io/FileIO.java
throw Py.IOError(ioe);

              
// in src/org/python/core/io/FileIO.java
throw Py.IOError(ioe);

              
// in src/org/python/core/io/FileIO.java
throw Py.IOError(Errno.EINVAL);

              
// in src/org/python/core/io/FileIO.java
throw Py.IOError(ioe);

              
// in src/org/python/core/io/FileIO.java
throw Py.IOError(ioe);

              
// in src/org/python/core/io/FileIO.java
throw Py.IOError(ioe);

              
// in src/org/python/core/io/FileIO.java
throw Py.IOError(ioe);

              
// in src/org/python/core/io/DatagramSocketIO.java
throw Py.IOError(ioe);

              
// in src/org/python/core/io/DatagramSocketIO.java
throw Py.IOError(ioe);

              
// in src/org/python/core/io/DatagramSocketIO.java
throw Py.IOError(ioe);

              
// in src/org/python/core/io/DatagramSocketIO.java
throw Py.IOError(ioe);

              
// in src/org/python/core/io/SocketIO.java
throw Py.IOError(ioe);

              
// in src/org/python/core/io/SocketIO.java
throw Py.IOError(ioe);

              
// in src/org/python/core/io/SocketIO.java
throw Py.IOError(ioe);

              
// in src/org/python/core/io/SocketIO.java
throw Py.IOError(ioe);

              
// in src/org/python/core/stringlib/MarkupIterator.java
throw Py.ValueError(e.getMessage());

              
// in src/org/python/core/PySuperDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/core/PySuperDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PySuperDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PySuperDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PySuperDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PySuperDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PySuperDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PySuperDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/core/PySuperDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PySuperDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/core/PySuperDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/core/PySuperDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/core/PySuperDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/core/PySuperDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/core/PySuperDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/core/PySuperDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/core/PySuperDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/core/PySuperDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/StdoutWrapper.java
throw Py.AttributeError("missing sys." + this.name);

              
// in src/org/python/core/PyEnumerate.java
throw PyBuiltinCallable.DefaultInfo.unexpectedCall(args.length, false, "enumerate", 0,
                                                               1);

              
// in src/org/python/core/PyStaticMethod.java
throw Py.TypeError("staticmethod does not accept keyword arguments");

              
// in src/org/python/core/PyStaticMethod.java
throw Py.TypeError("staticmethod expected 1 argument, got " + args.length);

              
// in src/org/python/core/PyArray.java
throw Py.TypeError("array() argument 1 must be char, not str");

              
// in src/org/python/core/PyArray.java
throw Py.TypeError("array() argument 1 must be char, not " + obj.getType().fastGetName());

              
// in src/org/python/core/PyArray.java
throw Py.IndexError("index out of range: " + o);

              
// in src/org/python/core/PyArray.java
throw Py.TypeError("can only append arrays of the same type, expected '"
                               + this.type + ", found " + otherArr.type);

              
// in src/org/python/core/PyArray.java
throw Py.TypeError("can only append arrays of the same type, expected '" + this.type
                               + ", found " + otherArr.type);

              
// in src/org/python/core/PyArray.java
throw Py.TypeError("array item must be unicode character");

              
// in src/org/python/core/PyArray.java
throw Py.RuntimeError("don't know how to byteswap this array type");

              
// in src/org/python/core/PyArray.java
throw Py.ValueError("bad typecode (must be c, b, B, u, h, H, i, I, l, L, f or d)");

              
// in src/org/python/core/PyArray.java
throw Py.TypeError("array item must be char");

              
// in src/org/python/core/PyArray.java
throw Py.TypeError("an integer is required");

              
// in src/org/python/core/PyArray.java
throw Py.TypeError("can only extend with array of same kind");

              
// in src/org/python/core/PyArray.java
throw Py.TypeError("Type not compatible with array type");

              
// in src/org/python/core/PyArray.java
throw Py.TypeError("arg1 must be open file");

              
// in src/org/python/core/PyArray.java
throw Py.EOFError("not enough items in file. "
                    + Integer.toString(count) + " requested, "
                    + Integer.toString(readcount) + " actually read");

              
// in src/org/python/core/PyArray.java
throw Py.TypeError("arg must be list");

              
// in src/org/python/core/PyArray.java
throw Py.ValueError("string length not a multiple of item size");

              
// in src/org/python/core/PyArray.java
throw Py.EOFError("not enough items in string");

              
// in src/org/python/core/PyArray.java
throw Py.IOError(e);

              
// in src/org/python/core/PyArray.java
throw Py.ValueError("fromunicode argument must be an unicode object");

              
// in src/org/python/core/PyArray.java
throw Py.ValueError("fromunicode() may only be called on type 'u' arrays");

              
// in src/org/python/core/PyArray.java
throw Py.ValueError("bad typecode (must be c, b, B, u, h, H, i, I, l, L, f or d)");

              
// in src/org/python/core/PyArray.java
throw Py.ValueError("array.index(" + value + "): " + value
                            + " not found in array");

              
// in src/org/python/core/PyArray.java
throw Py.IndexError("pop from empty array");

              
// in src/org/python/core/PyArray.java
throw Py.IndexError("pop index out of range");

              
// in src/org/python/core/PyArray.java
throw Py.ValueError("array.remove(" + value + "): " + value
                + " not found in array");

              
// in src/org/python/core/PyArray.java
throw Py.TypeError("Type not compatible with array type");

              
// in src/org/python/core/PyArray.java
throw Py.OverflowError("value too small for " + type.getName());

              
// in src/org/python/core/PyArray.java
throw Py.OverflowError("value too large for " + type.getName());

              
// in src/org/python/core/PyArray.java
throw Py.TypeError("Type not compatible with array type");

              
// in src/org/python/core/PyArray.java
throw Py.OverflowError("value too small for " + type.getName());

              
// in src/org/python/core/PyArray.java
throw Py.OverflowError("value too large for " + type.getName());

              
// in src/org/python/core/PyArray.java
throw Py.TypeError("Type not compatible with array type");

              
// in src/org/python/core/PyArray.java
throw Py.OverflowError("value too small for " + type.getName());

              
// in src/org/python/core/PyArray.java
throw Py.OverflowError("value too large for " + type.getName());

              
// in src/org/python/core/PyArray.java
throw Py.OverflowError("value too small for " + type.getName());

              
// in src/org/python/core/PyArray.java
throw Py.TypeError("Type not compatible with array type");

              
// in src/org/python/core/PyArray.java
throw Py.TypeError("Type not compatible with array type");

              
// in src/org/python/core/PyArray.java
throw Py.TypeError("Type not compatible with array type");

              
// in src/org/python/core/PyArray.java
throw Py.TypeError("Type not compatible with array type");

              
// in src/org/python/core/PyArray.java
throw Py.TypeError("Type not compatible with array type");

              
// in src/org/python/core/PyArray.java
throw Py.ValueError("invalid bounds for setting from string");

              
// in src/org/python/core/PyArray.java
throw Py.ValueError("invalid bounds for setting from string");

              
// in src/org/python/core/PyArray.java
throw Py.TypeError("bad argument type for built-in operation|" + array.typecode + "|" + typecode);

              
// in src/org/python/core/PyArray.java
throw Py.TypeError("Slice typecode '" + array.typecode
                                           + "' is not compatible with this array (typecode '"
                                           + this.typecode + "')");

              
// in src/org/python/core/PyArray.java
throw Py.TypeError(String.format("can only assign array (not \"%.200s\") to array "
                                                 + "slice", value.getType().fastGetName()));

              
// in src/org/python/core/PyArray.java
throw Py.TypeError("arg must be open file");

              
// in src/org/python/core/PyArray.java
throw Py.ValueError("invalid storage");

              
// in src/org/python/core/PyArray.java
throw Py.ValueError("invalid storage");

              
// in src/org/python/core/PyArray.java
throw Py.ValueError("invalid storage");

              
// in src/org/python/core/PyArray.java
throw Py.IOError(e);

              
// in src/org/python/core/PyArray.java
throw Py.ValueError("tounicode() may only be called on type 'u' arrays");

              
// in src/org/python/core/PyClassMethodDescr.java
throw Py.TypeError(String.format("descriptor '%s' for type '%s' needs either an "
                                                 + " object or a type", name, dtype.fastGetName()));

              
// in src/org/python/core/PyClassMethodDescr.java
throw Py.TypeError(String.format("descriptor '%s' for type '%s' needs a type, not a"
                                             + " '%s' as arg 2", name, dtype.fastGetName(),
                                             type.getType().fastGetName()));

              
// in src/org/python/core/PyModuleDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyModuleDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyModuleDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyModuleDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyModuleDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyModuleDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyModuleDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/core/PyModuleDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyModuleDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/core/PyModuleDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/core/PyModuleDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/core/PyModuleDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/core/PyModuleDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/core/PyModuleDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/core/PyModuleDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/core/PyModuleDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/core/PyModuleDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyFileReader.java
throw Py.ValueError("I/O operation on closed file");

              
// in src/org/python/core/PyFileReader.java
throw Py.IOError(e);

              
// in src/org/python/core/PyFileReader.java
throw Py.IOError(e);

              
// in src/org/python/core/PyFileReader.java
throw Py.IOError(e);

              
// in src/org/python/core/PyFileReader.java
throw Py.NotImplementedError("size argument to readline not implemented for PyFileReader");

              
// in src/org/python/core/PyFileReader.java
throw Py.IOError(e);

              
// in src/org/python/core/__builtin__.java
throw info.unexpectedCall(0, false);

              
// in src/org/python/core/__builtin__.java
throw Py.TypeError("ord() expected string of length 1, but " +
                                       arg1.getType().fastGetName() + " found");

              
// in src/org/python/core/__builtin__.java
throw Py.TypeError("reload() argument must be a module");

              
// in src/org/python/core/__builtin__.java
throw info.unexpectedCall(1, false);

              
// in src/org/python/core/__builtin__.java
throw info.unexpectedCall(2, false);

              
// in src/org/python/core/__builtin__.java
throw Py.TypeError("apply() 3rd argument must be a "
                                       + "dictionary with string keys");

              
// in src/org/python/core/__builtin__.java
throw info.unexpectedCall(3, false);

              
// in src/org/python/core/__builtin__.java
throw info.unexpectedCall(4, false);

              
// in src/org/python/core/__builtin__.java
throw info.unexpectedCall(args.length, false);

              
// in src/org/python/core/__builtin__.java
throw Py.TypeError(String.format("keywords must be strings"));

              
// in src/org/python/core/__builtin__.java
throw Py.ValueError("unichr() arg not in range(0x110000)");

              
// in src/org/python/core/__builtin__.java
throw Py.ValueError("chr() arg not in range(256)");

              
// in src/org/python/core/__builtin__.java
throw Py.TypeError("number coercion failed");

              
// in src/org/python/core/__builtin__.java
throw Py.TypeError(String.format("Expected keys() to be a list, not '%s'",
                                             retObj.getType().fastGetName()));

              
// in src/org/python/core/__builtin__.java
throw Py.TypeError("globals must be a mapping");

              
// in src/org/python/core/__builtin__.java
throw Py.TypeError("locals must be a mapping");

              
// in src/org/python/core/__builtin__.java
throw Py.TypeError("eval: argument 1 must be string or code object");

              
// in src/org/python/core/__builtin__.java
throw Py.TypeError("code object passed to eval() may not contain free variables");

              
// in src/org/python/core/__builtin__.java
throw Py.IOError(e);

              
// in src/org/python/core/__builtin__.java
throw Py.IOError(e);

              
// in src/org/python/core/__builtin__.java
throw Py.TypeError(String.format("can't filter %s to %s: __getitem__ returned "
                                                 + "different type", name, name));

              
// in src/org/python/core/__builtin__.java
throw Py.TypeError("intern() argument 1 must be string, not "
                               + obj.getType().fastGetName());

              
// in src/org/python/core/__builtin__.java
throw Py.TypeError("can't intern subclass of string");

              
// in src/org/python/core/__builtin__.java
throw Py.TypeError("map requires at least two arguments");

              
// in src/org/python/core/__builtin__.java
throw Py.TypeError("ord() expected a character, but string of length " +
                           length + " found");

              
// in src/org/python/core/__builtin__.java
throw Py.TypeError(String.format("unsupported operand type(s) for pow(): '%.100s', "
                                         + "'%.100s', '%.100s'", x.getType().fastGetName(),
                                         y.getType().fastGetName(), z.getType().fastGetName()));

              
// in src/org/python/core/__builtin__.java
throw Py.ValueError("range() step argument must not be zero");

              
// in src/org/python/core/__builtin__.java
throw Py.OverflowError("range() result has too many items");

              
// in src/org/python/core/__builtin__.java
throw Py.TypeError(String.format("range() integer start argument expected, got %s.",
                                             ilow.getType().fastGetName()));

              
// in src/org/python/core/__builtin__.java
throw Py.TypeError(String.format("range() integer end argument expected, got %s.",
                                             ihigh.getType().fastGetName()));

              
// in src/org/python/core/__builtin__.java
throw Py.TypeError(String.format("range() integer step argument expected, got %s.",
                                             istep.getType().fastGetName()));

              
// in src/org/python/core/__builtin__.java
throw Py.ValueError("range() step argument must not be zero");

              
// in src/org/python/core/__builtin__.java
throw Py.OverflowError("range() result has too many items");

              
// in src/org/python/core/__builtin__.java
throw Py.TypeError("object.readline() returned non-string");

              
// in src/org/python/core/__builtin__.java
throw Py.RuntimeError("[raw_]input: lost sys.stdout");

              
// in src/org/python/core/__builtin__.java
throw Py.EOFError("raw_input()");

              
// in src/org/python/core/__builtin__.java
throw Py.RuntimeError("[raw_]input: lost sys.stdin");

              
// in src/org/python/core/__builtin__.java
throw Py.TypeError("reduce of empty sequence with no initial value");

              
// in src/org/python/core/__builtin__.java
throw Py.TypeError("sum() can't sum strings [use ''.join(seq) instead]");

              
// in src/org/python/core/__builtin__.java
throw Py.TypeError("argument to reversed() must be a sequence");

              
// in src/org/python/core/__builtin__.java
throw Py.TypeError("vars() argument must have __dict__ attribute");

              
// in src/org/python/core/__builtin__.java
throw Py.TypeError("zip argument #" + (j + 1) + " must support iteration");

              
// in src/org/python/core/__builtin__.java
throw Py.TypeError(function + "(): attribute name must be string");

              
// in src/org/python/core/__builtin__.java
throw Py.TypeError("sorted() takes at least 1 argument (0 given)");

              
// in src/org/python/core/__builtin__.java
throw Py.TypeError(String.format("sorted() takes at most 4 arguments (%s given)",
                                             args.length));

              
// in src/org/python/core/__builtin__.java
throw Py.TypeError(String.format("'%s' object is not iterable",
                                                 args[0].getType().fastGetName()));

              
// in src/org/python/core/__builtin__.java
throw Py.TypeError("'" + arg.getType().fastGetName() + "' object is not iterable");

              
// in src/org/python/core/__builtin__.java
throw Py.TypeError("'" + arg.getType().fastGetName() + "' object is not iterable");

              
// in src/org/python/core/__builtin__.java
throw Py.TypeError("max() expected 1 arguments, got 0");

              
// in src/org/python/core/__builtin__.java
throw Py.TypeError("max() got an unexpected keyword argument");

              
// in src/org/python/core/__builtin__.java
throw Py.ValueError("min of empty sequence");

              
// in src/org/python/core/__builtin__.java
throw Py.TypeError("min() expected 1 arguments, got 0");

              
// in src/org/python/core/__builtin__.java
throw Py.TypeError("min() got an unexpected keyword argument");

              
// in src/org/python/core/__builtin__.java
throw Py.ValueError("min of empty sequence");

              
// in src/org/python/core/__builtin__.java
throw Py.TypeError("expected a readable buffer object");

              
// in src/org/python/core/__builtin__.java
throw Py.TypeError("compile() expected string without null bytes");

              
// in src/org/python/core/PyTypeDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyTypeDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyTypeDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyTypeDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyTypeDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyTypeDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyTypeDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/core/PyTypeDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyTypeDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/core/PyTypeDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/core/PyTypeDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/core/PyTypeDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/core/PyTypeDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/core/PyTypeDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/core/PyTypeDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/core/PyTypeDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/core/PyTypeDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/exceptions.java
throw Py.IndexError("tuple index out of range");

              
// in src/org/python/core/exceptions.java
throw Py.TypeError(String.format("%.200s attribute must be str", name));

              
// in src/org/python/core/exceptions.java
throw Py.TypeError(String.format("%.200s attribute must be unicode", name));

              
// in src/org/python/core/exceptions.java
throw Py.JavaError(e);

              
// in src/org/python/core/exceptions.java
throw Py.JavaError(t);

              
// in src/org/python/core/PySetDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/core/PySetDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PySetDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PySetDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PySetDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PySetDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PySetDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PySetDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/core/PySetDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PySetDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/core/PySetDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/core/PySetDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/core/PySetDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/core/PySetDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/core/PySetDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/core/PySetDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/core/PySetDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/core/PySetDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyType.java
throw Py.TypeError("type() takes 1 or 3 arguments");

              
// in src/org/python/core/PyType.java
throw Py.TypeError("type(): argument 3 must be dict, not " + dict.getType());

              
// in src/org/python/core/PyType.java
throw Py.TypeError("type.__init__() takes no keyword arguments");

              
// in src/org/python/core/PyType.java
throw Py.TypeError("type.__init__() takes 1 or 3 arguments");

              
// in src/org/python/core/PyType.java
throw Py.TypeError(String.format("type '%.100s' is not an acceptable base type",
                                             base.name));

              
// in src/org/python/core/PyType.java
throw Py.TypeError("__dict__ slot disallowed: we already got one");

              
// in src/org/python/core/PyType.java
throw Py.TypeError("__weakref__ slot disallowed: we already got one");

              
// in src/org/python/core/PyType.java
throw Py.AttributeError(String.format(writeMsg, "__weakref__",
                                                          obj.getType().fastGetName()));

              
// in src/org/python/core/PyType.java
throw Py.TypeError(String.format("%s assignment: '%s' object layout differs from '%s'",
                                             attribute, other.fastGetName(), fastGetName()));

              
// in src/org/python/core/PyType.java
throw Py.TypeError(String.format(msg, proxy.getName(), baseProxy.getName()));

              
// in src/org/python/core/PyType.java
throw Py.TypeError("Can't delete __bases__ attribute");

              
// in src/org/python/core/PyType.java
throw Py.TypeError("bases must be a tuple");

              
// in src/org/python/core/PyType.java
throw Py.TypeError("can only assign non-empty tuple to __bases__, not "
                               + newBasesTuple);

              
// in src/org/python/core/PyType.java
throw Py.TypeError(name + ".__bases__ must be a tuple of old- or new-style "
                                       + "classes, not " + newBases[i]);

              
// in src/org/python/core/PyType.java
throw Py.TypeError("a __bases__ item causes an inheritance cycle");

              
// in src/org/python/core/PyType.java
throw Py.AttributeError("mro");

              
// in src/org/python/core/PyType.java
throw Py.TypeError(String.format("mro() returned a non-class ('%.500s')",
                                                     cls.getType().fastGetName()));

              
// in src/org/python/core/PyType.java
throw Py.TypeError(String.format("mro() returned base with unsuitable layout "
                                                     + "('%.500s')", t.fastGetName()));

              
// in src/org/python/core/PyType.java
throw Py.TypeError("duplicate base class " +
                                       (name == null ? "?" : name.toString()));

              
// in src/org/python/core/PyType.java
throw Py.TypeError(msg.toString());

              
// in src/org/python/core/PyType.java
throw Py.TypeError("bases must be types");

              
// in src/org/python/core/PyType.java
throw Py.TypeError("multiple bases have instance lay-out conflict");

              
// in src/org/python/core/PyType.java
throw Py.TypeError("a new-style class can't have only classic bases");

              
// in src/org/python/core/PyType.java
throw Py.TypeError("metaclass conflict: the metaclass of a derived class must be a "
                               + "(non-strict) subclass of the metaclasses of all its bases");

              
// in src/org/python/core/PyType.java
throw Py.JavaError(e);

              
// in src/org/python/core/PyType.java
throw Py.TypeError(String.format("can't set attributes of built-in/extension type "
                    + "'%s'", this.name));

              
// in src/org/python/core/PyType.java
throw Py.TypeError(String.format("can't set attributes of built-in/extension type "
                    + "'%s'", this.name));

              
// in src/org/python/core/PyType.java
throw Py.TypeError(String.format("cannot create '%.100s' instances", name));

              
// in src/org/python/core/PyType.java
throw Py.TypeError(String.format("can only assign string to %s.__name__, not '%s'",
                                             this.name, name.getType().fastGetName()));

              
// in src/org/python/core/PyType.java
throw Py.ValueError("__name__ must not contain null bytes");

              
// in src/org/python/core/PyType.java
throw Py.TypeError(String.format("can't delete %s.__name__", name));

              
// in src/org/python/core/PyType.java
throw Py.AttributeError(String.format("attribute '__dict__' of '%s' objects is not "
                                              + "writable", getType().fastGetName()));

              
// in src/org/python/core/PyType.java
throw Py.TypeError(String.format("can't delete %s.__module__", name));

              
// in src/org/python/core/PyType.java
throw Py.AttributeError(String.format("type object '%.50s' has no attribute '%.400s'",
                                              fastGetName(), name));

              
// in src/org/python/core/PyType.java
throw Py.TypeError(String.format("__slots__ items must be strings, not '%.200s'",
                                             obj.getType().fastGetName()));

              
// in src/org/python/core/PyType.java
throw Py.TypeError(msg);

              
// in src/org/python/core/PyType.java
throw Py.TypeError(msg);

              
// in src/org/python/core/PyType.java
throw Py.TypeError(module + "." + name + " must be a type for deserialization");

              
// in src/org/python/core/PyJavaType.java
throw Py.TypeError(getName()
                                + " does not have a consistent method resolution order with "
                                + conflict.getName() + ", and it already has " + name
                                + " added for Python");

              
// in src/org/python/core/PyJavaType.java
throw Py.NameError("attribute not found: "+name);

              
// in src/org/python/core/PyJavaType.java
throw Py.TypeError(String.format("Supertypes that share a modified attribute "
                            + " have an MRO conflict[attribute=%s, types=%s]", method, types));

              
// in src/org/python/core/PyJavaType.java
throw Py.JavaError(e);

              
// in src/org/python/core/PyJavaType.java
throw Py.JavaError(exc);

              
// in src/org/python/core/PyJavaType.java
throw Py.TypeError("Could not copy Java object because it is not Cloneable or known to be immutable. "
                            + "Consider monkeypatching __copy__ for " + self.getType().fastGetName());

              
// in src/org/python/core/PyJavaType.java
throw Py.TypeError("Could not deepcopy Java object because it is not Serializable. "
                            + "Consider monkeypatching __deepcopy__ for " + self.getType().fastGetName());

              
// in src/org/python/core/PyJavaType.java
throw Py.TypeError("Could not copy Java object");

              
// in src/org/python/core/PyJavaType.java
throw Py.TypeError("Could not copy Java object");

              
// in src/org/python/core/PyJavaType.java
throw Py.JavaError(e);

              
// in src/org/python/core/PyPropertyDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/core/PyPropertyDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyPropertyDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyPropertyDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyPropertyDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyPropertyDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyPropertyDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyPropertyDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/core/PyPropertyDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyPropertyDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/core/PyPropertyDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/core/PyPropertyDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/core/PyPropertyDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/core/PyPropertyDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/core/PyPropertyDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/core/PyPropertyDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/core/PyPropertyDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/core/PyPropertyDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/CompilerFacade.java
throw ParserFacade.fixParseError(null, t, filename);

              
// in src/org/python/core/Py.java
throw Py.TypeError("can't convert " + o.__repr__() + " to " +
                    c.getName());

              
// in src/org/python/core/Py.java
throw Py.TypeError("can't convert to: " + s);

              
// in src/org/python/core/Py.java
throw Py.JavaError(e);

              
// in src/org/python/core/Py.java
throw JavaError(e);

              
// in src/org/python/core/Py.java
throw JavaError(e);

              
// in src/org/python/core/Py.java
throw Py.TypeError("Proxy instance reused");

              
// in src/org/python/core/Py.java
throw Py.TypeError("code object passed to exec may not contain free variables");

              
// in src/org/python/core/Py.java
throw Py.TypeError(
                        "exec: argument 1 must be string, code or file object");

              
// in src/org/python/core/Py.java
throw Py.TypeError("integer required");

              
// in src/org/python/core/Py.java
throw Py.TypeError("integer required");

              
// in src/org/python/core/Py.java
throw Py.TypeError(msg);

              
// in src/org/python/core/Py.java
throw Py.TypeError("integer required");

              
// in src/org/python/core/Py.java
throw Py.TypeError("float required");

              
// in src/org/python/core/Py.java
throw Py.TypeError("float required");

              
// in src/org/python/core/Py.java
throw Py.TypeError(msg);

              
// in src/org/python/core/Py.java
throw Py.TypeError(msg);

              
// in src/org/python/core/Py.java
throw Py.TypeError("None required for void return");

              
// in src/org/python/core/Py.java
throw Py.TypeError("compile() expected string without null bytes");

              
// in src/org/python/core/Py.java
throw Py.ValueError(String.format("need more than %d value%s to unpack", i,
                                                  i == 1 ? "" : "s"));

              
// in src/org/python/core/Py.java
throw Py.ValueError("too many values to unpack");

              
// in src/org/python/core/Py.java
throw Py.TypeError(message);

              
// in src/org/python/core/Py.java
throw Py.TypeError(message);

              
// in src/org/python/core/Py.java
throw Py.JavaError(t);

              
// in src/org/python/core/Py.java
throw Py.TypeError("java function not settable: " + method.getName());

              
// in src/org/python/core/PyNewWrapper.java
throw Py.SystemError("__new__ wrappers are already bound");

              
// in src/org/python/core/PyNewWrapper.java
throw Py.TypeError(for_type.fastGetName() + ".__new__(): not enough arguments");

              
// in src/org/python/core/PyNewWrapper.java
throw Py.TypeError(for_type.fastGetName() + ".__new__(X): X is not a type object ("
                    + arg0.getType().fastGetName() + ")");

              
// in src/org/python/core/PyNewWrapper.java
throw Py.TypeError(for_type.fastGetName() + ".__new__(" + subtype.fastGetName() + "): "
                    + subtype.fastGetName() + " is not a subtype of " + for_type.fastGetName());

              
// in src/org/python/core/PyNewWrapper.java
throw Py.TypeError(for_type.fastGetName() + ".__new__(" + subtype.fastGetName()
                    + ") is not safe, use " + subtype.fastGetName() + ".__new__()");

              
// in src/org/python/core/CompilerFlags.java
throw Py.ValueError("compile(): unrecognised flags");

              
// in src/org/python/core/PyFileDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/core/PyFileDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyFileDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyFileDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyFileDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyFileDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyFileDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyFileDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/core/PyFileDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyFileDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/core/PyFileDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/core/PyFileDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/core/PyFileDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/core/PyFileDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/core/PyFileDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/core/PyFileDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/core/PyFileDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/core/PyFileDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PySequence.java
throw Py.TypeError("can't assign to immutable object");

              
// in src/org/python/core/PySequence.java
throw Py.TypeError(String.format("'%s' object does not support item assignment",
                                         getType().fastGetName()));

              
// in src/org/python/core/PySequence.java
throw Py.TypeError(String.format("'%s' object does not support item deletion",
                                         getType().fastGetName()));

              
// in src/org/python/core/PySequence.java
throw Py.TypeError(String.format("'%s' object does not support item deletion",
                                         getType().fastGetName()));

              
// in src/org/python/core/PyCallIter.java
throw Py.TypeError("iter(v, w): v must be callable");

              
// in src/org/python/core/PyFunction.java
throw Py.TypeError("function() argument 1 must be code, not " +
                               code.getType().fastGetName());

              
// in src/org/python/core/PyFunction.java
throw Py.TypeError("arg 3 (name) must be None or string");

              
// in src/org/python/core/PyFunction.java
throw Py.TypeError("arg 4 (defaults) must be None or tuple");

              
// in src/org/python/core/PyFunction.java
throw Py.TypeError("arg 5 (closure) must be tuple");

              
// in src/org/python/core/PyFunction.java
throw Py.TypeError("arg 5 (closure) must be None or tuple");

              
// in src/org/python/core/PyFunction.java
throw Py.ValueError(String.format("%s requires closure of length %d, not %d",
                                              tcode.co_name, nfree, nclosure));

              
// in src/org/python/core/PyFunction.java
throw Py.TypeError(String.format("arg 5 (closure) expected cell, found %s",
                                                     o.getType().fastGetName()));

              
// in src/org/python/core/PyFunction.java
throw Py.TypeError("func_defaults must be set to a tuple object");

              
// in src/org/python/core/PyFunction.java
throw Py.TypeError("func_code must be set to a code object");

              
// in src/org/python/core/PyFunction.java
throw Py.ValueError(String.format("%s() requires a code object with %d free vars,"
                                              + " not %d", __name__, nclosure, nfree));

              
// in src/org/python/core/PyFunction.java
throw Py.TypeError("setting function's dictionary to a non-dict");

              
// in src/org/python/core/PyFunction.java
throw Py.TypeError("function's dictionary may not be deleted");

              
// in src/org/python/core/PyFunction.java
throw Py.TypeError("readonly attribute");

              
// in src/org/python/core/PyFunction.java
throw Py.TypeError("readonly attribute");

              
// in src/org/python/core/PyListDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/core/PyListDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyListDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyListDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyListDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyListDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyListDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyListDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/core/PyListDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyListDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/core/PyListDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/core/PyListDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/core/PyListDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/core/PyListDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/core/PyListDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/core/PyListDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/core/PyListDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/core/PyListDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/Options.java
throw Py.ValueError("Illegal verbose option setting: '" + prop
                        + "'");

              
// in src/org/python/core/Options.java
throw Py.ValueError("Illegal divisionWarning option "
                        + "setting: '" + prop + "'");

              
// in src/org/python/core/PyXRange.java
throw Py.ValueError("xrange() arg 3 must not be zero");

              
// in src/org/python/core/PyXRange.java
throw Py.OverflowError("xrange() result has too many items");

              
// in src/org/python/core/PyXRange.java
throw Py.IndexError("xrange object index out of range");

              
// in src/org/python/core/PyFrozenSetDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/core/PyFrozenSetDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyFrozenSetDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyFrozenSetDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyFrozenSetDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyFrozenSetDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyFrozenSetDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyFrozenSetDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/core/PyFrozenSetDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyFrozenSetDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/core/PyFrozenSetDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/core/PyFrozenSetDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/core/PyFrozenSetDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/core/PyFrozenSetDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/core/PyFrozenSetDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/core/PyFrozenSetDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/core/PyFrozenSetDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/core/PyFrozenSetDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyModule.java
throw Py.TypeError("readonly attribute");

              
// in src/org/python/core/PyModule.java
throw Py.TypeError("readonly attribute");

              
// in src/org/python/core/PyModule.java
throw Py.TypeError("__path__ must be list or None");

              
// in src/org/python/core/PyModule.java
throw Py.TypeError("module.__dict__ is not a dictionary");

              
// in src/org/python/core/ParserFacade.java
throw Py.SyntaxError(msg);

              
// in src/org/python/core/ParserFacade.java
throw Py.JavaError(t);

              
// in src/org/python/core/ParserFacade.java
throw fixParseError(bufReader, tt, filename);

              
// in src/org/python/core/ParserFacade.java
throw Py.ValueError("parse kind must be eval, exec, or single");

              
// in src/org/python/core/ParserFacade.java
throw fixParseError(bufReader, t, filename);

              
// in src/org/python/core/ParserFacade.java
throw fixParseError(bufReader, t, filename);

              
// in src/org/python/core/ParserFacade.java
throw fixParseError(bufReader, t, filename);

              
// in src/org/python/core/PyDictionaryDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/core/PyDictionaryDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyDictionaryDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyDictionaryDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyDictionaryDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyDictionaryDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyDictionaryDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyDictionaryDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/core/PyDictionaryDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyDictionaryDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/core/PyDictionaryDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/core/PyDictionaryDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/core/PyDictionaryDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/core/PyDictionaryDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/core/PyDictionaryDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/core/PyDictionaryDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/core/PyDictionaryDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/core/PyDictionaryDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyBuiltinFunction.java
throw Py.TypeError("Can't bind a builtin function");

              
// in src/org/python/core/PyBytecode.java
throw Py.TypeError("readonly attribute");

              
// in src/org/python/core/PyBytecode.java
throw Py.AttributeError(name);

              
// in src/org/python/core/PyBytecode.java
throw Py.SystemError("");

              
// in src/org/python/core/PyBytecode.java
throw Py.RuntimeError("invalid argument to DUP_TOPX" +
                                    " (bytecode corruption?)");

              
// in src/org/python/core/PyBytecode.java
throw PyException.doRaise(type, value, tb);

              
// in src/org/python/core/PyBytecode.java
throw PyException.doRaise(type, value, null);

              
// in src/org/python/core/PyBytecode.java
throw PyException.doRaise(type, null, null);

              
// in src/org/python/core/PyBytecode.java
throw PyException.doRaise(null, null, null);

              
// in src/org/python/core/PyBytecode.java
throw Py.SystemError("bad RAISE_VARARGS oparg");

              
// in src/org/python/core/PyBytecode.java
throw Py.SystemError("'finally' pops bad exception");

              
// in src/org/python/core/PyBytecode.java
throw Py.ImportError("__import__ not found");

              
// in src/org/python/core/PyBytecode.java
throw Py.ImportError(String.format("cannot import name %.230s", name));

              
// in src/org/python/core/PyBytecode.java
throw Py.SystemError("unknown opcode");

              
// in src/org/python/core/PyBytecode.java
throw Py.ValueError("too many values to unpack");

              
// in src/org/python/core/PyBytecode.java
throw Py.ValueError(String.format("need more than %d value%s to unpack",
                    i, i == 1 ? "" : "s"));

              
// in src/org/python/core/PyStringDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/core/PyStringDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyStringDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyStringDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyStringDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyStringDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyStringDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyStringDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/core/PyStringDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyStringDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/core/PyStringDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/core/PyStringDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/core/PyStringDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/core/PyStringDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/core/PyStringDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/core/PyStringDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/core/PyStringDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/core/PyBuiltinMethodSet.java
throw Py.TypeError(String.format("descriptor '%s' for '%s' objects doesn't apply "
                                                 + "to '%s' object", info.getName(),
                                                 PyType.fromClass(this.type), obj.getType()));

              
// in src/org/python/core/ThreadState.java
throw Py.RuntimeError("invalid initializing proxies state");

              
// in src/org/python/core/ThreadState.java
throw Py.RuntimeError("maximum recursion depth exceeded" + where);

              
// in src/org/python/core/codecs.java
throw Py.TypeError("argument must be callable");

              
// in src/org/python/core/codecs.java
throw Py.TypeError("argument must be callable");

              
// in src/org/python/core/codecs.java
throw Py.TypeError("codec search functions must return 4-tuples");

              
// in src/org/python/core/codecs.java
throw Py.TypeError("decoder must return a tuple (object,integer)");

              
// in src/org/python/core/codecs.java
throw Py.TypeError("encoder must return a tuple (object,integer)");

              
// in src/org/python/core/codecs.java
throw Py.TypeError("encoder did not return a string/unicode object (type="
                    + encoded.getType().fastGetName() + ")");

              
// in src/org/python/core/codecs.java
throw wrong_exception_type(exc);

              
// in src/org/python/core/codecs.java
throw wrong_exception_type(exc);

              
// in src/org/python/core/codecs.java
throw wrong_exception_type(exc);

              
// in src/org/python/core/codecs.java
throw wrong_exception_type(exc);

              
// in src/org/python/core/codecs.java
throw wrong_exception_type(exc);

              
// in src/org/python/core/codecs.java
throw Py.UnicodeEncodeError(encoding, str, i + j, i + j + 1, reason);

              
// in src/org/python/core/codecs.java
throw Py.IndexError(newPosition + " out of bounds of encoded string");

              
// in src/org/python/core/codecs.java
throw Py.UnicodeEncodeError("punycode", input.getString(), codePointIndex, codePointIndex + 1, "overflow");

              
// in src/org/python/core/codecs.java
throw Py.UnicodeEncodeError("punycode", input.getString(), i, i + 1, "overflow");

              
// in src/org/python/core/codecs.java
throw Py.UnicodeDecodeError("punycode", input, j, j + 1, "not basic");

              
// in src/org/python/core/codecs.java
throw Py.UnicodeDecodeError("punycode", input, j, j + 1, "overflow");

              
// in src/org/python/core/codecs.java
throw Py.UnicodeDecodeError("punycode", input, j, j + 1, "overflow");

              
// in src/org/python/core/PyException.java
throw Py.TypeError("raise: arg 3 must be a traceback or None");

              
// in src/org/python/core/PyException.java
throw Py.TypeError("instance exception may not have a separate value");

              
// in src/org/python/core/PyException.java
throw Py.TypeError("exceptions must be old-style classes or derived from "
                               + "BaseException, not " + type.getType().fastGetName());

              
// in src/org/python/core/PyCell.java
throw Py.ValueError("Cell is empty");

              
// in src/org/python/core/BaseSet.java
throw Py.RuntimeError("set changed size during iteration");

              
// in src/org/python/core/BaseSet.java
throw Py.TypeError("cannot compare sets using cmp()");

              
// in src/org/python/core/BaseSet.java
throw Py.TypeError("can only compare to a set");

              
// in src/org/python/core/PyInteger.java
throw Py.TypeError("int: can't convert non-string with explicit base");

              
// in src/org/python/core/PyInteger.java
throw Py.OverflowError("long int too large to convert to int");

              
// in src/org/python/core/PyInteger.java
throw Py.TypeError("int: can't convert non-string with explicit base");

              
// in src/org/python/core/PyInteger.java
throw Py.TypeError("int() argument must be a string or a number");

              
// in src/org/python/core/PyInteger.java
throw Py.TypeError("xxx");

              
// in src/org/python/core/PyInteger.java
throw Py.ZeroDivisionError("integer division or modulo by zero");

              
// in src/org/python/core/PyInteger.java
throw Py.ZeroDivisionError("cannot raise 0 to a negative power");

              
// in src/org/python/core/PyInteger.java
throw Py.ValueError("pow(x, y, z) with z==0");

              
// in src/org/python/core/PyInteger.java
throw Py.ValueError("negative shift count");

              
// in src/org/python/core/PyInteger.java
throw Py.ValueError("negative shift count");

              
// in src/org/python/core/PyInteger.java
throw Py.ValueError("negative shift count");

              
// in src/org/python/core/PyInteger.java
throw Py.ValueError("negative shift count");

              
// in src/org/python/core/PyInteger.java
throw Py.TypeError("__format__ requires str or unicode");

              
// in src/org/python/core/PyInteger.java
throw Py.ValueError(e.getMessage());

              
// in src/org/python/core/PyObjectDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/core/PyObjectDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyObjectDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyObjectDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyObjectDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyObjectDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyObjectDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyObjectDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/core/PyObjectDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyObjectDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/core/PyObjectDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/core/PyObjectDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/core/PyObjectDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/core/PyObjectDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/core/PyObjectDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/core/PyObjectDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/core/PyObjectDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/core/PyObjectDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyComplexDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/core/PyComplexDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyComplexDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyComplexDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyComplexDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyComplexDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyComplexDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyComplexDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/core/PyComplexDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyComplexDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/core/PyComplexDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/core/PyComplexDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/core/PyComplexDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/core/PyComplexDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/core/PyComplexDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/core/PyComplexDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/core/PyComplexDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/core/PyComplexDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyLong.java
throw Py.TypeError(String.format("long() argument must be a string or a number, "
                                                 + "not '%.200s'", x.getType().fastGetName()));

              
// in src/org/python/core/PyLong.java
throw Py.TypeError("long: can't convert non-string with explicit base");

              
// in src/org/python/core/PyLong.java
throw Py.OverflowError("cannot convert float infinity to long");

              
// in src/org/python/core/PyLong.java
throw Py.OverflowError("long int too large to convert to float");

              
// in src/org/python/core/PyLong.java
throw Py.OverflowError(overflowMsg);

              
// in src/org/python/core/PyLong.java
throw Py.TypeError("xxx");

              
// in src/org/python/core/PyLong.java
throw Py.ZeroDivisionError("long division or modulo");

              
// in src/org/python/core/PyLong.java
throw Py.ZeroDivisionError("long division or modulo");

              
// in src/org/python/core/PyLong.java
throw Py.OverflowError("long/long too large for a float");

              
// in src/org/python/core/PyLong.java
throw Py.OverflowError("long/long too large for a float");

              
// in src/org/python/core/PyLong.java
throw Py.ZeroDivisionError("zero to a negative power");

              
// in src/org/python/core/PyLong.java
throw Py.ValueError("pow(x, y, z) with z == 0");

              
// in src/org/python/core/PyLong.java
throw Py.TypeError("xxx");

              
// in src/org/python/core/PyLong.java
throw Py.ValueError("negative shift count");

              
// in src/org/python/core/PyLong.java
throw Py.ValueError("negative shift count");

              
// in src/org/python/core/PyLong.java
throw Py.ValueError("negative shift count");

              
// in src/org/python/core/PyLong.java
throw Py.ValueError("negative shift count");

              
// in src/org/python/core/PyClassMethodDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/core/PyClassMethodDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyClassMethodDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyClassMethodDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyClassMethodDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyClassMethodDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyClassMethodDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyClassMethodDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/core/PyClassMethodDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyClassMethodDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/core/PyClassMethodDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/core/PyClassMethodDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/core/PyClassMethodDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/core/PyClassMethodDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/core/PyClassMethodDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/core/PyClassMethodDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/core/PyClassMethodDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/core/PyClassMethodDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyBuiltinFunctionNarrow.java
throw info.unexpectedCall(args.length, false);

              
// in src/org/python/core/PyBuiltinFunctionNarrow.java
throw Py.TypeError(fastGetName() + "() takes no keyword arguments");

              
// in src/org/python/core/PyBuiltinFunctionNarrow.java
throw info.unexpectedCall(0, false);

              
// in src/org/python/core/PyBuiltinFunctionNarrow.java
throw info.unexpectedCall(1, false);

              
// in src/org/python/core/PyBuiltinFunctionNarrow.java
throw info.unexpectedCall(2, false);

              
// in src/org/python/core/PyBuiltinFunctionNarrow.java
throw info.unexpectedCall(3, false);

              
// in src/org/python/core/PyBuiltinFunctionNarrow.java
throw info.unexpectedCall(4, false);

              
// in src/org/python/core/PyMethod.java
throw Py.TypeError("first argument must be callable");

              
// in src/org/python/core/PyMethod.java
throw Py.TypeError("unbound methods must have non-NULL im_class");

              
// in src/org/python/core/PyMethod.java
throw Py.TypeError(msg);

              
// in src/org/python/core/ClasspathPyImporter.java
throw Py.ImportError("path isn't for classpath importer");

              
// in src/org/python/core/ClasspathPyImporter.java
throw Py.JavaError(e);

              
// in src/org/python/core/CompileMode.java
throw Py.ValueError("compile() arg 3 must be 'exec' or 'eval' or 'single'");

              
// in src/org/python/core/PyTupleDerived.java
throw Py.TypeError("__dict__ must be set to a Dictionary "+newDict.getClass().getName());

              
// in src/org/python/core/PyTupleDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyTupleDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyTupleDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyTupleDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyTupleDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyTupleDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyTupleDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/core/PyTupleDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyTupleDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/core/PyTupleDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/core/PyTupleDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/core/PyTupleDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/core/PyTupleDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/core/PyTupleDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/core/PyTupleDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/core/PyTupleDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/core/PyTupleDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyString.java
throw Py.UnicodeError("Unicode names not loaded");

              
// in src/org/python/core/PyString.java
throw Py.IndexError("string index out of range");

              
// in src/org/python/core/PyString.java
throw Py.TypeError("'in <string>' requires string as left operand");

              
// in src/org/python/core/PyString.java
throw Py.OverflowError("max str len is " + Integer.MAX_VALUE);

              
// in src/org/python/core/PyString.java
throw Py.TypeError("bad operand type for unary +");

              
// in src/org/python/core/PyString.java
throw Py.TypeError("bad operand type for unary -");

              
// in src/org/python/core/PyString.java
throw Py.TypeError("bad operand type for unary ~");

              
// in src/org/python/core/PyString.java
throw Py.ValueError("empty string for complex()");

              
// in src/org/python/core/PyString.java
throw Py.ValueError(String.format("float() out of range: %.150s", getString()));

              
// in src/org/python/core/PyString.java
throw Py.ValueError("malformed string for complex() " +
                                getString().substring(s));

              
// in src/org/python/core/PyString.java
throw Py.ValueError("empty separator");

              
// in src/org/python/core/PyString.java
throw Py.ValueError("empty separator");

              
// in src/org/python/core/PyString.java
throw Py.TypeError("expected a character buffer object");

              
// in src/org/python/core/PyString.java
throw Py.ValueError("empty separator");

              
// in src/org/python/core/PyString.java
throw Py.ValueError("empty separator");

              
// in src/org/python/core/PyString.java
throw Py.TypeError("expected a character buffer object");

              
// in src/org/python/core/PyString.java
throw Py.ValueError("empty separator");

              
// in src/org/python/core/PyString.java
throw Py.ValueError("empty separator");

              
// in src/org/python/core/PyString.java
throw Py.ValueError("substring not found in string.index");

              
// in src/org/python/core/PyString.java
throw Py.ValueError("substring not found in string.rindex");

              
// in src/org/python/core/PyString.java
throw Py.ValueError("null byte in argument for float()");

              
// in src/org/python/core/PyString.java
throw Py.ValueError("invalid literal for __float__: "+getString());

              
// in src/org/python/core/PyString.java
throw Py.ValueError("invalid base for atoi()");

              
// in src/org/python/core/PyString.java
throw Py.OverflowError("long int too large to convert to int");

              
// in src/org/python/core/PyString.java
throw Py.ValueError("invalid literal for int() with base " + base + ": " + getString());

              
// in src/org/python/core/PyString.java
throw Py.ValueError("invalid literal for int() with base " + base + ": " + getString());

              
// in src/org/python/core/PyString.java
throw Py.ValueError("invalid base for long literal:" + base);

              
// in src/org/python/core/PyString.java
throw Py.UnicodeEncodeError("decimal", "codec can't encode character",
                        0,0, "invalid decimal Unicode string");

              
// in src/org/python/core/PyString.java
throw Py.ValueError("invalid literal for long() with base " + base + ": " + getString());

              
// in src/org/python/core/PyString.java
throw Py.ValueError("invalid literal for long() with base " + base + ": " + getString());

              
// in src/org/python/core/PyString.java
throw Py.TypeError(function + "() argument 2 must be char, not str");

              
// in src/org/python/core/PyString.java
throw Py.TypeError("str or unicode required for replace");

              
// in src/org/python/core/PyString.java
throw Py.TypeError(String.format("sequence item %d: expected string, %.80s found",
                                                 i, item.getType().fastGetName()));

              
// in src/org/python/core/PyString.java
throw Py.OverflowError("join() result is too long for a Python string");

              
// in src/org/python/core/PyString.java
throw Py.TypeError(String.format("sequence item %d: expected string or Unicode,"
                                                 + " %.80s found",
                                                 i, item.getType().fastGetName()));

              
// in src/org/python/core/PyString.java
throw Py.OverflowError("join() result is too long for a Python string");

              
// in src/org/python/core/PyString.java
throw Py.TypeError("expected a character buffer object");

              
// in src/org/python/core/PyString.java
throw Py.TypeError("expected a character buffer object or tuple");

              
// in src/org/python/core/PyString.java
throw Py.TypeError("expected a character buffer object");

              
// in src/org/python/core/PyString.java
throw Py.TypeError("expected a character buffer object or tuple");

              
// in src/org/python/core/PyString.java
throw Py.ValueError(
                "translation table must be 256 characters long");

              
// in src/org/python/core/PyString.java
throw Py.TypeError(
                    "translate() only works for 8-bit character strings");

              
// in src/org/python/core/PyString.java
throw Py.TypeError(
                     "character mapping must return integer, " +
                     "None or unicode");

              
// in src/org/python/core/PyString.java
throw Py.ValueError(e.getMessage());

              
// in src/org/python/core/PyString.java
throw Py.ValueError("Unknown conversion specifier " + chunk.conversion);

              
// in src/org/python/core/PyString.java
throw Py.IndexError("tuple index out of range");

              
// in src/org/python/core/PyString.java
throw Py.KeyError((String) head);

              
// in src/org/python/core/PyString.java
throw Py.TypeError("__format__ requires str or unicode");

              
// in src/org/python/core/PyString.java
throw Py.ValueError(e.getMessage());

              
// in src/org/python/core/PyString.java
throw Py.TypeError(description + " is required");

              
// in src/org/python/core/PyString.java
throw Py.ValueError("incomplete format");

              
// in src/org/python/core/PyString.java
throw Py.TypeError("not enough arguments for format string");

              
// in src/org/python/core/PyString.java
throw Py.TypeError("* wants int");

              
// in src/org/python/core/PyString.java
throw Py.OverflowError("formatted " + type + " is too long (precision too long?)");

              
// in src/org/python/core/PyString.java
throw Py.TypeError("int argument required");

              
// in src/org/python/core/PyString.java
throw !pye.match(Py.TypeError) ? pye : Py.TypeError("float argument required");

              
// in src/org/python/core/PyString.java
throw Py.TypeError("format requires a mapping");

              
// in src/org/python/core/PyString.java
throw Py.TypeError("int argument required");

              
// in src/org/python/core/PyString.java
throw Py.TypeError("int argument required");

              
// in src/org/python/core/PyString.java
throw Py.TypeError("int argument required");

              
// in src/org/python/core/PyString.java
throw Py.TypeError("int argument required");

              
// in src/org/python/core/PyString.java
throw Py.TypeError("%c requires int or char");

              
// in src/org/python/core/PyString.java
throw Py.TypeError("%c requires int or char");

              
// in src/org/python/core/PyString.java
throw Py.OverflowError("unsigned byte integer is less than minimum");

              
// in src/org/python/core/PyString.java
throw Py.OverflowError("unsigned byte integer is greater than maximum");

              
// in src/org/python/core/PyString.java
throw Py.OverflowError("%c arg not in range(0x110000) (wide Python build)");

              
// in src/org/python/core/PyString.java
throw Py.ValueError("unsupported format character '" +
                         codecs.encode(Py.newString(c), null, "replace") +
                         "' (0x" + Integer.toHexString(c) + ") at index " +
                         (index-1));

              
// in src/org/python/core/PyString.java
throw Py.TypeError("not all arguments converted during string formatting");

              
// in src/org/python/core/imp.java
throw Py.IOError(ioe);

              
// in src/org/python/core/imp.java
throw Py.IOError(e);

              
// in src/org/python/core/imp.java
throw Py.IOError(ioe);

              
// in src/org/python/core/imp.java
throw Py.ImportError(ioe.getMessage() + "[name=" + name + ", source=" + sourceName
                        + ", compiled=" + compiledName + "]");

              
// in src/org/python/core/imp.java
throw Py.JavaError(t);

              
// in src/org/python/core/imp.java
throw Py.ImportError("invalid api version(" + api + " != "
                        + APIVersion + ") in: " + name);

              
// in src/org/python/core/imp.java
throw ParserFacade.fixParseError(null, t, filename);

              
// in src/org/python/core/imp.java
throw Py.JavaError(e);

              
// in src/org/python/core/imp.java
throw Py.JavaError(e);

              
// in src/org/python/core/imp.java
throw Py.ImportError("Cannot import " + name
                            + ", missing class " + c.getName());

              
// in src/org/python/core/imp.java
throw Py.ValueError("Attempted relative import in non-package");

              
// in src/org/python/core/imp.java
throw Py.ValueError("Attempted relative import beyond toplevel package");

              
// in src/org/python/core/imp.java
throw Py.ImportError("No module named " + name);

              
// in src/org/python/core/imp.java
throw Py.ImportError("No module named " + name);

              
// in src/org/python/core/imp.java
throw Py.ImportError("No module named " + name);

              
// in src/org/python/core/imp.java
throw Py.ValueError("Empty module name");

              
// in src/org/python/core/imp.java
throw Py.ImportError("cannot import name " + names[i]);

              
// in src/org/python/core/imp.java
throw Py.ImportError("reload(): module " + name
                    + " not in sys.modules");

              
// in src/org/python/core/imp.java
throw Py.ImportError("reload(): parent not in sys.modules");

              
// in src/org/python/core/ClasspathPyImporterDerived.java
throw Py.TypeError("__str__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/ClasspathPyImporterDerived.java
throw Py.TypeError("__repr__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/ClasspathPyImporterDerived.java
throw Py.TypeError("__hex__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/ClasspathPyImporterDerived.java
throw Py.TypeError("__oct__"+" returned non-"+"string"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/ClasspathPyImporterDerived.java
throw Py.TypeError("__float__"+" returned non-"+"float"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/ClasspathPyImporterDerived.java
throw Py.TypeError("__complex__"+" returned non-"+"complex"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/ClasspathPyImporterDerived.java
throw Py.TypeError("__int__"+" should return an integer");

              
// in src/org/python/core/ClasspathPyImporterDerived.java
throw Py.TypeError("__long__"+" returned non-"+"long"+" (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/ClasspathPyImporterDerived.java
throw Py.TypeError("__hash__ should return a int");

              
// in src/org/python/core/ClasspathPyImporterDerived.java
throw Py.TypeError(String.format("unhashable type: '%.200s'",getType().fastGetName()));

              
// in src/org/python/core/ClasspathPyImporterDerived.java
throw Py.TypeError("__unicode__"+" should return a "+"unicode");

              
// in src/org/python/core/ClasspathPyImporterDerived.java
throw Py.TypeError(String.format("__nonzero__ should return bool or int, returned %s",self_type.getName()));

              
// in src/org/python/core/ClasspathPyImporterDerived.java
throw Py.TypeError("__len__ should return a int");

              
// in src/org/python/core/ClasspathPyImporterDerived.java
throw Py.RuntimeError("maximum __call__ recursion depth exceeded");

              
// in src/org/python/core/ClasspathPyImporterDerived.java
throw Py.TypeError(String.format("__index__ returned non-(int,long) (type %s)",res.getType().fastGetName()));

              
// in src/org/python/core/ClasspathPyImporterDerived.java
throw Py.TypeError("__coerce__ didn't return a 2-tuple");

              
// in src/org/python/core/ClasspathPyImporterDerived.java
throw Py.TypeError("__repr__ returned non-string (type "+res.getType().fastGetName()+")");

              
// in src/org/python/core/PyGenerator.java
throw Py.StopIteration("");

              
// in src/org/python/core/PyGenerator.java
throw Py.TypeError("can't send non-None value to a just-started generator");

              
// in src/org/python/core/PyGenerator.java
throw Py.TypeError("throw() third argument must be a traceback object");

              
// in src/org/python/core/PyGenerator.java
throw Py.RuntimeError("generator ignored GeneratorExit");

              
// in src/org/python/core/PyGenerator.java
throw Py.ValueError("generator already executing");

              
// in src/org/python/core/util/StringUtil.java
throw Py.SystemError("Java couldn't find the ISO-8859-1 encoding");

              
// in src/org/python/core/util/importer.java
throw Py.ImportError(ioe.getMessage() + "[path=" + fullSearchPath + "]");

              
// in src/org/python/core/Deriveds.java
throw Py.TypeError(String.format("__init__() should return None, not '%.200s'",
                                             result.getType().fastGetName()));

              
// in src/org/python/core/Deriveds.java
throw Py.SystemError(String.format("__getattribute__ not found on type %s",
                                                       type.getName()));

              
// in src/org/python/util/JLineConsole.java
throw Py.IOError(ioe);

              
// in src/org/python/util/JLineConsole.java
throw Py.IOError(e.getMessage());

              
// in src/org/python/util/JLineConsole.java
throw Py.EOFError("");

              
// in src/org/python/util/jython.java
throw Py.ValueError("jar file missing '__run__.py'");

              
// in src/org/python/util/jython.java
throw Py.IOError(e);

              
// in src/org/python/util/jython.java
throw Py.IOError(e);

            
- -
- Variable 457
              
// in src/com/ziclix/python/sql/Fetch.java
throw e;

              
// in src/com/ziclix/python/sql/Fetch.java
throw e;

              
// in src/com/ziclix/python/sql/Fetch.java
throw e;

              
// in src/com/ziclix/python/sql/Fetch.java
throw e;

              
// in src/com/ziclix/python/sql/DataHandler.java
throw ex;

              
// in src/com/ziclix/python/sql/DataHandler.java
throw ex;

              
// in src/com/ziclix/python/sql/DataHandler.java
throw ex;

              
// in src/com/ziclix/python/sql/Jython22DataHandler.java
throw ex;

              
// in src/com/ziclix/python/sql/Jython22DataHandler.java
throw ex;

              
// in src/com/ziclix/python/sql/Jython22DataHandler.java
throw ex;

              
// in src/com/ziclix/python/sql/Procedure.java
throw e;

              
// in src/com/ziclix/python/sql/PyCursor.java
throw e;

              
// in src/com/ziclix/python/sql/PyCursor.java
throw e;

              
// in src/org/python/indexer/ast/NNode.java
throw ix;

              
// in src/org/python/compiler/Module.java
throw e;

              
// in src/org/python/antlr/ast/aliasDerived.java
throw exc;

              
// in src/org/python/antlr/ast/aliasDerived.java
throw exc;

              
// in src/org/python/antlr/ast/aliasDerived.java
throw exc;

              
// in src/org/python/antlr/ast/AttributeDerived.java
throw exc;

              
// in src/org/python/antlr/ast/AttributeDerived.java
throw exc;

              
// in src/org/python/antlr/ast/AttributeDerived.java
throw exc;

              
// in src/org/python/antlr/ast/UnaryOpDerived.java
throw exc;

              
// in src/org/python/antlr/ast/UnaryOpDerived.java
throw exc;

              
// in src/org/python/antlr/ast/UnaryOpDerived.java
throw exc;

              
// in src/org/python/antlr/ast/BreakDerived.java
throw exc;

              
// in src/org/python/antlr/ast/BreakDerived.java
throw exc;

              
// in src/org/python/antlr/ast/BreakDerived.java
throw exc;

              
// in src/org/python/antlr/ast/BoolOpDerived.java
throw exc;

              
// in src/org/python/antlr/ast/BoolOpDerived.java
throw exc;

              
// in src/org/python/antlr/ast/BoolOpDerived.java
throw exc;

              
// in src/org/python/antlr/ast/ListCompDerived.java
throw exc;

              
// in src/org/python/antlr/ast/ListCompDerived.java
throw exc;

              
// in src/org/python/antlr/ast/ListCompDerived.java
throw exc;

              
// in src/org/python/antlr/ast/ContinueDerived.java
throw exc;

              
// in src/org/python/antlr/ast/ContinueDerived.java
throw exc;

              
// in src/org/python/antlr/ast/ContinueDerived.java
throw exc;

              
// in src/org/python/antlr/ast/TupleDerived.java
throw exc;

              
// in src/org/python/antlr/ast/TupleDerived.java
throw exc;

              
// in src/org/python/antlr/ast/TupleDerived.java
throw exc;

              
// in src/org/python/antlr/ast/InteractiveDerived.java
throw exc;

              
// in src/org/python/antlr/ast/InteractiveDerived.java
throw exc;

              
// in src/org/python/antlr/ast/InteractiveDerived.java
throw exc;

              
// in src/org/python/antlr/ast/DeleteDerived.java
throw exc;

              
// in src/org/python/antlr/ast/DeleteDerived.java
throw exc;

              
// in src/org/python/antlr/ast/DeleteDerived.java
throw exc;

              
// in src/org/python/antlr/ast/IndexDerived.java
throw exc;

              
// in src/org/python/antlr/ast/IndexDerived.java
throw exc;

              
// in src/org/python/antlr/ast/IndexDerived.java
throw exc;

              
// in src/org/python/antlr/ast/ModuleDerived.java
throw exc;

              
// in src/org/python/antlr/ast/ModuleDerived.java
throw exc;

              
// in src/org/python/antlr/ast/ModuleDerived.java
throw exc;

              
// in src/org/python/antlr/ast/CallDerived.java
throw exc;

              
// in src/org/python/antlr/ast/CallDerived.java
throw exc;

              
// in src/org/python/antlr/ast/CallDerived.java
throw exc;

              
// in src/org/python/antlr/ast/ReturnDerived.java
throw exc;

              
// in src/org/python/antlr/ast/ReturnDerived.java
throw exc;

              
// in src/org/python/antlr/ast/ReturnDerived.java
throw exc;

              
// in src/org/python/antlr/ast/ForDerived.java
throw exc;

              
// in src/org/python/antlr/ast/ForDerived.java
throw exc;

              
// in src/org/python/antlr/ast/ForDerived.java
throw exc;

              
// in src/org/python/antlr/ast/ExceptHandlerDerived.java
throw exc;

              
// in src/org/python/antlr/ast/ExceptHandlerDerived.java
throw exc;

              
// in src/org/python/antlr/ast/ExceptHandlerDerived.java
throw exc;

              
// in src/org/python/antlr/ast/SubscriptDerived.java
throw exc;

              
// in src/org/python/antlr/ast/SubscriptDerived.java
throw exc;

              
// in src/org/python/antlr/ast/SubscriptDerived.java
throw exc;

              
// in src/org/python/antlr/ast/DictDerived.java
throw exc;

              
// in src/org/python/antlr/ast/DictDerived.java
throw exc;

              
// in src/org/python/antlr/ast/DictDerived.java
throw exc;

              
// in src/org/python/antlr/ast/LambdaDerived.java
throw exc;

              
// in src/org/python/antlr/ast/LambdaDerived.java
throw exc;

              
// in src/org/python/antlr/ast/LambdaDerived.java
throw exc;

              
// in src/org/python/antlr/ast/GlobalDerived.java
throw exc;

              
// in src/org/python/antlr/ast/GlobalDerived.java
throw exc;

              
// in src/org/python/antlr/ast/GlobalDerived.java
throw exc;

              
// in src/org/python/antlr/ast/ListDerived.java
throw exc;

              
// in src/org/python/antlr/ast/ListDerived.java
throw exc;

              
// in src/org/python/antlr/ast/ListDerived.java
throw exc;

              
// in src/org/python/antlr/ast/BinOpDerived.java
throw exc;

              
// in src/org/python/antlr/ast/BinOpDerived.java
throw exc;

              
// in src/org/python/antlr/ast/BinOpDerived.java
throw exc;

              
// in src/org/python/antlr/ast/ClassDefDerived.java
throw exc;

              
// in src/org/python/antlr/ast/ClassDefDerived.java
throw exc;

              
// in src/org/python/antlr/ast/ClassDefDerived.java
throw exc;

              
// in src/org/python/antlr/ast/ExpressionDerived.java
throw exc;

              
// in src/org/python/antlr/ast/ExpressionDerived.java
throw exc;

              
// in src/org/python/antlr/ast/ExpressionDerived.java
throw exc;

              
// in src/org/python/antlr/ast/SliceDerived.java
throw exc;

              
// in src/org/python/antlr/ast/SliceDerived.java
throw exc;

              
// in src/org/python/antlr/ast/SliceDerived.java
throw exc;

              
// in src/org/python/antlr/ast/NumDerived.java
throw exc;

              
// in src/org/python/antlr/ast/NumDerived.java
throw exc;

              
// in src/org/python/antlr/ast/NumDerived.java
throw exc;

              
// in src/org/python/antlr/ast/ExprDerived.java
throw exc;

              
// in src/org/python/antlr/ast/ExprDerived.java
throw exc;

              
// in src/org/python/antlr/ast/ExprDerived.java
throw exc;

              
// in src/org/python/antlr/ast/NameDerived.java
throw exc;

              
// in src/org/python/antlr/ast/NameDerived.java
throw exc;

              
// in src/org/python/antlr/ast/NameDerived.java
throw exc;

              
// in src/org/python/antlr/ast/TryFinallyDerived.java
throw exc;

              
// in src/org/python/antlr/ast/TryFinallyDerived.java
throw exc;

              
// in src/org/python/antlr/ast/TryFinallyDerived.java
throw exc;

              
// in src/org/python/antlr/ast/IfExpDerived.java
throw exc;

              
// in src/org/python/antlr/ast/IfExpDerived.java
throw exc;

              
// in src/org/python/antlr/ast/IfExpDerived.java
throw exc;

              
// in src/org/python/antlr/ast/AugAssignDerived.java
throw exc;

              
// in src/org/python/antlr/ast/AugAssignDerived.java
throw exc;

              
// in src/org/python/antlr/ast/AugAssignDerived.java
throw exc;

              
// in src/org/python/antlr/ast/ImportDerived.java
throw exc;

              
// in src/org/python/antlr/ast/ImportDerived.java
throw exc;

              
// in src/org/python/antlr/ast/ImportDerived.java
throw exc;

              
// in src/org/python/antlr/ast/IfDerived.java
throw exc;

              
// in src/org/python/antlr/ast/IfDerived.java
throw exc;

              
// in src/org/python/antlr/ast/IfDerived.java
throw exc;

              
// in src/org/python/antlr/ast/PassDerived.java
throw exc;

              
// in src/org/python/antlr/ast/PassDerived.java
throw exc;

              
// in src/org/python/antlr/ast/PassDerived.java
throw exc;

              
// in src/org/python/antlr/ast/FunctionDefDerived.java
throw exc;

              
// in src/org/python/antlr/ast/FunctionDefDerived.java
throw exc;

              
// in src/org/python/antlr/ast/FunctionDefDerived.java
throw exc;

              
// in src/org/python/antlr/ast/argumentsDerived.java
throw exc;

              
// in src/org/python/antlr/ast/argumentsDerived.java
throw exc;

              
// in src/org/python/antlr/ast/argumentsDerived.java
throw exc;

              
// in src/org/python/antlr/ast/WithDerived.java
throw exc;

              
// in src/org/python/antlr/ast/WithDerived.java
throw exc;

              
// in src/org/python/antlr/ast/WithDerived.java
throw exc;

              
// in src/org/python/antlr/ast/ImportFromDerived.java
throw exc;

              
// in src/org/python/antlr/ast/ImportFromDerived.java
throw exc;

              
// in src/org/python/antlr/ast/ImportFromDerived.java
throw exc;

              
// in src/org/python/antlr/ast/CompareDerived.java
throw exc;

              
// in src/org/python/antlr/ast/CompareDerived.java
throw exc;

              
// in src/org/python/antlr/ast/CompareDerived.java
throw exc;

              
// in src/org/python/antlr/ast/ReprDerived.java
throw exc;

              
// in src/org/python/antlr/ast/ReprDerived.java
throw exc;

              
// in src/org/python/antlr/ast/ReprDerived.java
throw exc;

              
// in src/org/python/antlr/ast/StrDerived.java
throw exc;

              
// in src/org/python/antlr/ast/StrDerived.java
throw exc;

              
// in src/org/python/antlr/ast/StrDerived.java
throw exc;

              
// in src/org/python/antlr/ast/YieldDerived.java
throw exc;

              
// in src/org/python/antlr/ast/YieldDerived.java
throw exc;

              
// in src/org/python/antlr/ast/YieldDerived.java
throw exc;

              
// in src/org/python/antlr/ast/EllipsisDerived.java
throw exc;

              
// in src/org/python/antlr/ast/EllipsisDerived.java
throw exc;

              
// in src/org/python/antlr/ast/EllipsisDerived.java
throw exc;

              
// in src/org/python/antlr/ast/RaiseDerived.java
throw exc;

              
// in src/org/python/antlr/ast/RaiseDerived.java
throw exc;

              
// in src/org/python/antlr/ast/RaiseDerived.java
throw exc;

              
// in src/org/python/antlr/ast/AssignDerived.java
throw exc;

              
// in src/org/python/antlr/ast/AssignDerived.java
throw exc;

              
// in src/org/python/antlr/ast/AssignDerived.java
throw exc;

              
// in src/org/python/antlr/ast/GeneratorExpDerived.java
throw exc;

              
// in src/org/python/antlr/ast/GeneratorExpDerived.java
throw exc;

              
// in src/org/python/antlr/ast/GeneratorExpDerived.java
throw exc;

              
// in src/org/python/antlr/ast/SuiteDerived.java
throw exc;

              
// in src/org/python/antlr/ast/SuiteDerived.java
throw exc;

              
// in src/org/python/antlr/ast/SuiteDerived.java
throw exc;

              
// in src/org/python/antlr/ast/AssertDerived.java
throw exc;

              
// in src/org/python/antlr/ast/AssertDerived.java
throw exc;

              
// in src/org/python/antlr/ast/AssertDerived.java
throw exc;

              
// in src/org/python/antlr/ast/TryExceptDerived.java
throw exc;

              
// in src/org/python/antlr/ast/TryExceptDerived.java
throw exc;

              
// in src/org/python/antlr/ast/TryExceptDerived.java
throw exc;

              
// in src/org/python/antlr/ast/ExecDerived.java
throw exc;

              
// in src/org/python/antlr/ast/ExecDerived.java
throw exc;

              
// in src/org/python/antlr/ast/ExecDerived.java
throw exc;

              
// in src/org/python/antlr/ast/WhileDerived.java
throw exc;

              
// in src/org/python/antlr/ast/WhileDerived.java
throw exc;

              
// in src/org/python/antlr/ast/WhileDerived.java
throw exc;

              
// in src/org/python/antlr/ast/keywordDerived.java
throw exc;

              
// in src/org/python/antlr/ast/keywordDerived.java
throw exc;

              
// in src/org/python/antlr/ast/keywordDerived.java
throw exc;

              
// in src/org/python/antlr/ast/comprehensionDerived.java
throw exc;

              
// in src/org/python/antlr/ast/comprehensionDerived.java
throw exc;

              
// in src/org/python/antlr/ast/comprehensionDerived.java
throw exc;

              
// in src/org/python/antlr/ast/ExtSliceDerived.java
throw exc;

              
// in src/org/python/antlr/ast/ExtSliceDerived.java
throw exc;

              
// in src/org/python/antlr/ast/ExtSliceDerived.java
throw exc;

              
// in src/org/python/antlr/ast/PrintDerived.java
throw exc;

              
// in src/org/python/antlr/ast/PrintDerived.java
throw exc;

              
// in src/org/python/antlr/ast/PrintDerived.java
throw exc;

              
// in src/org/python/antlr/op/PowDerived.java
throw exc;

              
// in src/org/python/antlr/op/PowDerived.java
throw exc;

              
// in src/org/python/antlr/op/PowDerived.java
throw exc;

              
// in src/org/python/antlr/op/LtEDerived.java
throw exc;

              
// in src/org/python/antlr/op/LtEDerived.java
throw exc;

              
// in src/org/python/antlr/op/LtEDerived.java
throw exc;

              
// in src/org/python/antlr/op/ParamDerived.java
throw exc;

              
// in src/org/python/antlr/op/ParamDerived.java
throw exc;

              
// in src/org/python/antlr/op/ParamDerived.java
throw exc;

              
// in src/org/python/antlr/op/EqDerived.java
throw exc;

              
// in src/org/python/antlr/op/EqDerived.java
throw exc;

              
// in src/org/python/antlr/op/EqDerived.java
throw exc;

              
// in src/org/python/antlr/op/GtDerived.java
throw exc;

              
// in src/org/python/antlr/op/GtDerived.java
throw exc;

              
// in src/org/python/antlr/op/GtDerived.java
throw exc;

              
// in src/org/python/antlr/op/IsDerived.java
throw exc;

              
// in src/org/python/antlr/op/IsDerived.java
throw exc;

              
// in src/org/python/antlr/op/IsDerived.java
throw exc;

              
// in src/org/python/antlr/op/GtEDerived.java
throw exc;

              
// in src/org/python/antlr/op/GtEDerived.java
throw exc;

              
// in src/org/python/antlr/op/GtEDerived.java
throw exc;

              
// in src/org/python/antlr/op/StoreDerived.java
throw exc;

              
// in src/org/python/antlr/op/StoreDerived.java
throw exc;

              
// in src/org/python/antlr/op/StoreDerived.java
throw exc;

              
// in src/org/python/antlr/op/BitOrDerived.java
throw exc;

              
// in src/org/python/antlr/op/BitOrDerived.java
throw exc;

              
// in src/org/python/antlr/op/BitOrDerived.java
throw exc;

              
// in src/org/python/antlr/op/RShiftDerived.java
throw exc;

              
// in src/org/python/antlr/op/RShiftDerived.java
throw exc;

              
// in src/org/python/antlr/op/RShiftDerived.java
throw exc;

              
// in src/org/python/antlr/op/BitAndDerived.java
throw exc;

              
// in src/org/python/antlr/op/BitAndDerived.java
throw exc;

              
// in src/org/python/antlr/op/BitAndDerived.java
throw exc;

              
// in src/org/python/antlr/op/NotInDerived.java
throw exc;

              
// in src/org/python/antlr/op/NotInDerived.java
throw exc;

              
// in src/org/python/antlr/op/NotInDerived.java
throw exc;

              
// in src/org/python/antlr/op/LtDerived.java
throw exc;

              
// in src/org/python/antlr/op/LtDerived.java
throw exc;

              
// in src/org/python/antlr/op/LtDerived.java
throw exc;

              
// in src/org/python/antlr/op/FloorDivDerived.java
throw exc;

              
// in src/org/python/antlr/op/FloorDivDerived.java
throw exc;

              
// in src/org/python/antlr/op/FloorDivDerived.java
throw exc;

              
// in src/org/python/antlr/op/USubDerived.java
throw exc;

              
// in src/org/python/antlr/op/USubDerived.java
throw exc;

              
// in src/org/python/antlr/op/USubDerived.java
throw exc;

              
// in src/org/python/antlr/op/InvertDerived.java
throw exc;

              
// in src/org/python/antlr/op/InvertDerived.java
throw exc;

              
// in src/org/python/antlr/op/InvertDerived.java
throw exc;

              
// in src/org/python/antlr/op/AugLoadDerived.java
throw exc;

              
// in src/org/python/antlr/op/AugLoadDerived.java
throw exc;

              
// in src/org/python/antlr/op/AugLoadDerived.java
throw exc;

              
// in src/org/python/antlr/op/AugStoreDerived.java
throw exc;

              
// in src/org/python/antlr/op/AugStoreDerived.java
throw exc;

              
// in src/org/python/antlr/op/AugStoreDerived.java
throw exc;

              
// in src/org/python/antlr/op/LoadDerived.java
throw exc;

              
// in src/org/python/antlr/op/LoadDerived.java
throw exc;

              
// in src/org/python/antlr/op/LoadDerived.java
throw exc;

              
// in src/org/python/antlr/op/IsNotDerived.java
throw exc;

              
// in src/org/python/antlr/op/IsNotDerived.java
throw exc;

              
// in src/org/python/antlr/op/IsNotDerived.java
throw exc;

              
// in src/org/python/antlr/op/BitXorDerived.java
throw exc;

              
// in src/org/python/antlr/op/BitXorDerived.java
throw exc;

              
// in src/org/python/antlr/op/BitXorDerived.java
throw exc;

              
// in src/org/python/antlr/op/NotEqDerived.java
throw exc;

              
// in src/org/python/antlr/op/NotEqDerived.java
throw exc;

              
// in src/org/python/antlr/op/NotEqDerived.java
throw exc;

              
// in src/org/python/antlr/op/NotDerived.java
throw exc;

              
// in src/org/python/antlr/op/NotDerived.java
throw exc;

              
// in src/org/python/antlr/op/NotDerived.java
throw exc;

              
// in src/org/python/antlr/op/AndDerived.java
throw exc;

              
// in src/org/python/antlr/op/AndDerived.java
throw exc;

              
// in src/org/python/antlr/op/AndDerived.java
throw exc;

              
// in src/org/python/antlr/op/ModDerived.java
throw exc;

              
// in src/org/python/antlr/op/ModDerived.java
throw exc;

              
// in src/org/python/antlr/op/ModDerived.java
throw exc;

              
// in src/org/python/antlr/op/AddDerived.java
throw exc;

              
// in src/org/python/antlr/op/AddDerived.java
throw exc;

              
// in src/org/python/antlr/op/AddDerived.java
throw exc;

              
// in src/org/python/antlr/op/DelDerived.java
throw exc;

              
// in src/org/python/antlr/op/DelDerived.java
throw exc;

              
// in src/org/python/antlr/op/DelDerived.java
throw exc;

              
// in src/org/python/antlr/op/DivDerived.java
throw exc;

              
// in src/org/python/antlr/op/DivDerived.java
throw exc;

              
// in src/org/python/antlr/op/DivDerived.java
throw exc;

              
// in src/org/python/antlr/op/LShiftDerived.java
throw exc;

              
// in src/org/python/antlr/op/LShiftDerived.java
throw exc;

              
// in src/org/python/antlr/op/LShiftDerived.java
throw exc;

              
// in src/org/python/antlr/op/InDerived.java
throw exc;

              
// in src/org/python/antlr/op/InDerived.java
throw exc;

              
// in src/org/python/antlr/op/InDerived.java
throw exc;

              
// in src/org/python/antlr/op/MultDerived.java
throw exc;

              
// in src/org/python/antlr/op/MultDerived.java
throw exc;

              
// in src/org/python/antlr/op/MultDerived.java
throw exc;

              
// in src/org/python/antlr/op/UAddDerived.java
throw exc;

              
// in src/org/python/antlr/op/UAddDerived.java
throw exc;

              
// in src/org/python/antlr/op/UAddDerived.java
throw exc;

              
// in src/org/python/antlr/op/OrDerived.java
throw exc;

              
// in src/org/python/antlr/op/OrDerived.java
throw exc;

              
// in src/org/python/antlr/op/OrDerived.java
throw exc;

              
// in src/org/python/antlr/op/SubDerived.java
throw exc;

              
// in src/org/python/antlr/op/SubDerived.java
throw exc;

              
// in src/org/python/antlr/op/SubDerived.java
throw exc;

              
// in src/org/python/antlr/PythonTokenSource.java
throw p;

              
// in src/org/python/modules/zipimport/zipimporterDerived.java
throw exc;

              
// in src/org/python/modules/zipimport/zipimporterDerived.java
throw exc;

              
// in src/org/python/modules/zipimport/zipimporterDerived.java
throw exc;

              
// in src/org/python/modules/zipimport/zipimporter.java
throw pye;

              
// in src/org/python/modules/binascii.java
throw e;

              
// in src/org/python/modules/_weakref/ReferenceTypeDerived.java
throw exc;

              
// in src/org/python/modules/_weakref/ReferenceTypeDerived.java
throw exc;

              
// in src/org/python/modules/_weakref/ReferenceTypeDerived.java
throw exc;

              
// in src/org/python/modules/posix/PosixModule.java
throw pye;

              
// in src/org/python/modules/posix/PosixModule.java
throw pye;

              
// in src/org/python/modules/posix/PosixModule.java
throw pye;

              
// in src/org/python/modules/thread/PyLocalDerived.java
throw exc;

              
// in src/org/python/modules/thread/PyLocalDerived.java
throw exc;

              
// in src/org/python/modules/thread/PyLocalDerived.java
throw exc;

              
// in src/org/python/modules/_csv/PyDialectDerived.java
throw exc;

              
// in src/org/python/modules/_csv/PyDialectDerived.java
throw exc;

              
// in src/org/python/modules/_csv/PyDialectDerived.java
throw exc;

              
// in src/org/python/modules/random/PyRandomDerived.java
throw exc;

              
// in src/org/python/modules/random/PyRandomDerived.java
throw exc;

              
// in src/org/python/modules/random/PyRandomDerived.java
throw exc;

              
// in src/org/python/modules/_collections/PyDequeDerived.java
throw exc;

              
// in src/org/python/modules/_collections/PyDequeDerived.java
throw exc;

              
// in src/org/python/modules/_collections/PyDequeDerived.java
throw exc;

              
// in src/org/python/modules/_collections/PyDefaultDictDerived.java
throw exc;

              
// in src/org/python/modules/_collections/PyDefaultDictDerived.java
throw exc;

              
// in src/org/python/modules/_collections/PyDefaultDictDerived.java
throw exc;

              
// in src/org/python/modules/_collections/PyDeque.java
throw pe;

              
// in src/org/python/modules/itertools.java
throw pyEx;

              
// in src/org/python/modules/itertools.java
throw pyEx;

              
// in src/org/python/modules/_functools/PyPartialDerived.java
throw exc;

              
// in src/org/python/modules/_functools/PyPartialDerived.java
throw exc;

              
// in src/org/python/modules/_functools/PyPartialDerived.java
throw exc;

              
// in src/org/python/modules/time/Time.java
throw e;

              
// in src/org/python/modules/PyTeeIterator.java
throw pyEx;

              
// in src/org/python/core/PyObject.java
throw pye;

              
// in src/org/python/core/PyObject.java
throw exc;

              
// in src/org/python/core/PyObject.java
throw (Throwable) t;

              
// in src/org/python/core/PyObject.java
throw e;

              
// in src/org/python/core/PyObject.java
throw (RuntimeException) t;

              
// in src/org/python/core/PyObject.java
throw (Error) t;

              
// in src/org/python/core/PyObject.java
throw exc;

              
// in src/org/python/core/PyObject.java
throw pye;

              
// in src/org/python/core/PyObject.java
throw pye;

              
// in src/org/python/core/PyObject.java
throw pye;

              
// in src/org/python/core/PyStringMap.java
throw pye;

              
// in src/org/python/core/PyList.java
throw pye;

              
// in src/org/python/core/PyFloatDerived.java
throw exc;

              
// in src/org/python/core/PyFloatDerived.java
throw exc;

              
// in src/org/python/core/PyFloatDerived.java
throw exc;

              
// in src/org/python/core/PyArrayDerived.java
throw exc;

              
// in src/org/python/core/PyArrayDerived.java
throw exc;

              
// in src/org/python/core/PyArrayDerived.java
throw exc;

              
// in src/org/python/core/PyEnumerateDerived.java
throw exc;

              
// in src/org/python/core/PyEnumerateDerived.java
throw exc;

              
// in src/org/python/core/PyEnumerateDerived.java
throw exc;

              
// in src/org/python/core/PyDictionary.java
throw pye;

              
// in src/org/python/core/PyUnicodeDerived.java
throw exc;

              
// in src/org/python/core/PyUnicodeDerived.java
throw exc;

              
// in src/org/python/core/PyUnicodeDerived.java
throw exc;

              
// in src/org/python/core/PyFastSequenceIter.java
throw pye;

              
// in src/org/python/core/PyTableCode.java
throw pye;

              
// in src/org/python/core/PyComplex.java
throw pye;

              
// in src/org/python/core/PyComplex.java
throw pye;

              
// in src/org/python/core/PyComplex.java
throw pye;

              
// in src/org/python/core/PyInstance.java
throw e;

              
// in src/org/python/core/PyInstance.java
throw exc;

              
// in src/org/python/core/PyInstance.java
throw pye;

              
// in src/org/python/core/ContextGuard.java
throw e;

              
// in src/org/python/core/PyFrame.java
throw pye;

              
// in src/org/python/core/PyFrame.java
throw pye;

              
// in src/org/python/core/PyLongDerived.java
throw exc;

              
// in src/org/python/core/PyLongDerived.java
throw exc;

              
// in src/org/python/core/PyLongDerived.java
throw exc;

              
// in src/org/python/core/AstList.java
throw pye;

              
// in src/org/python/core/AstList.java
throw pye;

              
// in src/org/python/core/PyFloat.java
throw e;

              
// in src/org/python/core/PySlice.java
throw pye;

              
// in src/org/python/core/PyIntegerDerived.java
throw exc;

              
// in src/org/python/core/PyIntegerDerived.java
throw exc;

              
// in src/org/python/core/PyIntegerDerived.java
throw exc;

              
// in src/org/python/core/PyIterator.java
throw toThrow;

              
// in src/org/python/core/PyBaseExceptionDerived.java
throw exc;

              
// in src/org/python/core/PyBaseExceptionDerived.java
throw exc;

              
// in src/org/python/core/PyBaseExceptionDerived.java
throw exc;

              
// in src/org/python/core/PyBaseCode.java
throw pye;

              
// in src/org/python/core/io/IOBase.java
throw pye;

              
// in src/org/python/core/io/BufferedIOMixin.java
throw pye;

              
// in src/org/python/core/PySuperDerived.java
throw exc;

              
// in src/org/python/core/PySuperDerived.java
throw exc;

              
// in src/org/python/core/PySuperDerived.java
throw exc;

              
// in src/org/python/core/PyModuleDerived.java
throw exc;

              
// in src/org/python/core/PyModuleDerived.java
throw exc;

              
// in src/org/python/core/PyModuleDerived.java
throw exc;

              
// in src/org/python/core/__builtin__.java
throw pye;

              
// in src/org/python/core/__builtin__.java
throw attributeError;

              
// in src/org/python/core/__builtin__.java
throw e;

              
// in src/org/python/core/__builtin__.java
throw e;

              
// in src/org/python/core/PyTypeDerived.java
throw exc;

              
// in src/org/python/core/PyTypeDerived.java
throw exc;

              
// in src/org/python/core/PyTypeDerived.java
throw exc;

              
// in src/org/python/core/PySetDerived.java
throw exc;

              
// in src/org/python/core/PySetDerived.java
throw exc;

              
// in src/org/python/core/PySetDerived.java
throw exc;

              
// in src/org/python/core/PyType.java
throw t;

              
// in src/org/python/core/PythonTraceFunction.java
throw exc;

              
// in src/org/python/core/PyPropertyDerived.java
throw exc;

              
// in src/org/python/core/PyPropertyDerived.java
throw exc;

              
// in src/org/python/core/PyPropertyDerived.java
throw exc;

              
// in src/org/python/core/Py.java
throw e;

              
// in src/org/python/core/Py.java
throw e;

              
// in src/org/python/core/Py.java
throw pye;

              
// in src/org/python/core/Py.java
throw pye;

              
// in src/org/python/core/Py.java
throw exc;

              
// in src/org/python/core/PySequenceIter.java
throw exc;

              
// in src/org/python/core/PyFileDerived.java
throw exc;

              
// in src/org/python/core/PyFileDerived.java
throw exc;

              
// in src/org/python/core/PyFileDerived.java
throw exc;

              
// in src/org/python/core/PyCallIter.java
throw exc;

              
// in src/org/python/core/PyListDerived.java
throw exc;

              
// in src/org/python/core/PyListDerived.java
throw exc;

              
// in src/org/python/core/PyListDerived.java
throw exc;

              
// in src/org/python/core/PyFrozenSetDerived.java
throw exc;

              
// in src/org/python/core/PyFrozenSetDerived.java
throw exc;

              
// in src/org/python/core/PyFrozenSetDerived.java
throw exc;

              
// in src/org/python/core/ParserFacade.java
throw p;

              
// in src/org/python/core/PyDictionaryDerived.java
throw exc;

              
// in src/org/python/core/PyDictionaryDerived.java
throw exc;

              
// in src/org/python/core/PyDictionaryDerived.java
throw exc;

              
// in src/org/python/core/AnnotationReader.java
throw ioe;

              
// in src/org/python/core/PyBytecode.java
throw (PyException) generatorInput;

              
// in src/org/python/core/PyBytecode.java
throw pye;

              
// in src/org/python/core/PyBytecode.java
throw pye;

              
// in src/org/python/core/PyBytecode.java
throw ts.exception;

              
// in src/org/python/core/PyStringDerived.java
throw exc;

              
// in src/org/python/core/PyStringDerived.java
throw exc;

              
// in src/org/python/core/PyStringDerived.java
throw exc;

              
// in src/org/python/core/codecs.java
throw exc;

              
// in src/org/python/core/codecs.java
throw ex;

              
// in src/org/python/core/codecs.java
throw ex;

              
// in src/org/python/core/BaseSet.java
throw pye;

              
// in src/org/python/core/PyInteger.java
throw pye;

              
// in src/org/python/core/PyInteger.java
throw pye;

              
// in src/org/python/core/PyObjectDerived.java
throw exc;

              
// in src/org/python/core/PyObjectDerived.java
throw exc;

              
// in src/org/python/core/PyObjectDerived.java
throw exc;

              
// in src/org/python/core/PyComplexDerived.java
throw exc;

              
// in src/org/python/core/PyComplexDerived.java
throw exc;

              
// in src/org/python/core/PyComplexDerived.java
throw exc;

              
// in src/org/python/core/PyLong.java
throw pye;

              
// in src/org/python/core/PyClassMethodDerived.java
throw exc;

              
// in src/org/python/core/PyClassMethodDerived.java
throw exc;

              
// in src/org/python/core/PyClassMethodDerived.java
throw exc;

              
// in src/org/python/core/PyTupleDerived.java
throw exc;

              
// in src/org/python/core/PyTupleDerived.java
throw exc;

              
// in src/org/python/core/PyTupleDerived.java
throw exc;

              
// in src/org/python/core/PyString.java
throw e;

              
// in src/org/python/core/PyString.java
throw e;

              
// in src/org/python/core/PyString.java
throw !pye.match(Py.TypeError) ? pye : Py.TypeError("float argument required");

              
// in src/org/python/core/PyString.java
throw e;

              
// in src/org/python/core/imp.java
throw pye;

              
// in src/org/python/core/imp.java
throw t;

              
// in src/org/python/core/imp.java
throw e;

              
// in src/org/python/core/ClasspathPyImporterDerived.java
throw exc;

              
// in src/org/python/core/ClasspathPyImporterDerived.java
throw exc;

              
// in src/org/python/core/ClasspathPyImporterDerived.java
throw exc;

              
// in src/org/python/core/PyGenerator.java
throw e;

              
// in src/org/python/core/PyGenerator.java
throw ex;

              
// in src/org/python/core/PyGenerator.java
throw pye;

              
// in src/org/python/core/Deriveds.java
throw pye;

              
// in src/org/python/core/Deriveds.java
throw firstAttributeError;

              
// in src/org/python/util/InteractiveInterpreter.java
throw exc;

              
// in src/org/python/util/InteractiveInterpreter.java
throw exc;

              
// in src/org/python/util/PythonObjectInputStream.java
throw exc;

              
// in src/org/python/util/InteractiveConsole.java
throw exc;

            
- -
(Lib) IllegalArgumentException 61
              
// in src/org/python/indexer/Indexer.java
public void setLogger(Logger logger) { if (logger == null) { throw new IllegalArgumentException("null logger param"); } logger = logger; }
// in src/org/python/indexer/Indexer.java
public NBinding putBinding(NBinding b) { if (b == null) { throw new IllegalArgumentException("null binding arg"); } String qname = b.getQname(); if (qname == null || qname.length() == 0) { throw new IllegalArgumentException("Null/empty qname: " + b); } NBinding existing = allBindings.get(qname); if (existing == b) { return b; } if (existing != null) { duplicateBindingFailure(b, existing); // A bad edge case was triggered by an __init__.py that defined a // "Parser" binding (type unknown), and there was a Parser.py in the // same directory. Loading Parser.py resulted in infinite recursion. // // XXX: need to revisit this logic. It seems that bindings made in // __init__.py probably (?) ought to have __init__ in their qnames // to avoid dup-binding conflicts. The Indexer module table also // probably ought not be a normal scope -- it's different enough that // overloading it to handle modules is making the logic rather twisty. if (b.getKind() == NBinding.Kind.MODULE) { return b; } return existing; } allBindings.put(qname, b); return b; }
// in src/org/python/indexer/Outliner.java
public void setQname(String qname) { if (qname == null) { throw new IllegalArgumentException("qname param cannot be null"); } this.qname = qname; }
// in src/org/python/indexer/Outliner.java
public void setKind(NBinding.Kind kind) { if (kind == null) { throw new IllegalArgumentException("kind param cannot be null"); } this.kind = kind; }
// in src/org/python/indexer/types/NUnionType.java
public void addType(NType t) { if (t == null) { throw new IllegalArgumentException("null type"); } if (t.isUnionType()) { types.addAll(t.asUnionType().types); } else { types.add(t); } }
// in src/org/python/indexer/ast/NAttribute.java
public void setAttr(NName attr) { if (attr == null) { throw new IllegalArgumentException("param cannot be null"); } this.attr = attr; }
// in src/org/python/indexer/ast/NAttribute.java
public void setTarget(NNode target) { if (target == null) { throw new IllegalArgumentException("param cannot be null"); } this.target = target; }
// in src/org/python/indexer/ast/NNode.java
public NType setType(NType newType) { if (newType == null) { throw new IllegalArgumentException(); } return type = newType; }
// in src/org/python/indexer/ast/NNode.java
public NType addType(NType newType) { if (newType == null) { throw new IllegalArgumentException(); } return type = NUnionType.union(getType(), newType); }
// in src/org/python/indexer/AstCache.java
public NModule getAST(String path) throws Exception { if (path == null) throw new IllegalArgumentException("null path"); return fetch(path); }
// in src/org/python/indexer/AstCache.java
public NModule getAST(String path, String contents) throws Exception { if (path == null) throw new IllegalArgumentException("null path"); if (contents == null) throw new IllegalArgumentException("null contents"); // Cache stores null value if the parse failed. if (cache.containsKey(path)) { return cache.get(path); } NModule mod = null; try { mod = parse(path, contents); if (mod != null) { mod.setFileAndMD5(path, Util.getMD5(contents.getBytes("UTF-8"))); } } finally { cache.put(path, mod); // may be null } return mod; }
// in src/org/python/indexer/Scope.java
public NBinding put(String id, NNode loc, NType type, NBinding.Kind kind) { if (type == null) { throw new IllegalArgumentException("Null type: id=" + id + ", loc=" + loc); } NBinding b = lookupScope(id); return insertOrUpdate(b, id, loc, type, kind); }
// in src/org/python/indexer/Scope.java
public NBinding putAttr(String id, NNode loc, NType type, NBinding.Kind kind) { if (type == null) { throw new IllegalArgumentException("Null type: id=" + id + ", loc=" + loc); } // Attributes are always part of a qualified name. If there is no qname // on the target type, it's a bug (we forgot to set the path somewhere.) if ("".equals(path)) { Indexer.idx.reportFailedAssertion( "Attempting to set attr '" + id + "' at location " + loc + (loc != null ? loc.getFile() : "") + " in scope with no path (qname) set: " + this.toShortString()); return null; } NBinding b = lookupAttr(id); return insertOrUpdate(b, id, loc, type, kind); }
// in src/org/python/indexer/Scope.java
public NBinding update(String id, NNode loc, NType type, NBinding.Kind kind) { if (type == null) { throw new IllegalArgumentException("Null type: id=" + id + ", loc=" + loc); } return update(id, new Def(loc), type, kind); }
// in src/org/python/indexer/Scope.java
public NBinding update(String id, Def loc, NType type, NBinding.Kind kind) { if (type == null) { throw new IllegalArgumentException("Null type: id=" + id + ", loc=" + loc); } NBinding b = lookupScope(id); if (b == null) { return insertBinding(new NBinding(id, loc, type, kind)); } b.getDefs().clear(); // XXX: what about updating refs & idx.locations? b.addDef(loc); b.setType(type); // XXX: is this a bug? I think he meant to do this check before the // line above that sets b.type, if it's supposed to be like put(). if (b.getType().isUnknownType()) { b.setKind(kind); } return b; }
// in src/org/python/indexer/Scope.java
public void setPath(String path) { if (path == null) { throw new IllegalArgumentException("'path' param cannot be null"); } this.path = path; }
// in src/org/python/expose/generate/RestrictiveAnnotationVisitor.java
public AnnotationVisitor visitAnnotation(String name, String desc) { throw new IllegalArgumentException("Unknown annotation field '" + name + "'"); }
// in src/org/python/expose/generate/RestrictiveAnnotationVisitor.java
public AnnotationVisitor visitArray(String name) { throw new IllegalArgumentException("Unknown annotation field '" + name + "'"); }
// in src/org/python/expose/generate/RestrictiveAnnotationVisitor.java
public void visitEnum(String name, String desc, String value) { throw new IllegalArgumentException("Unknown annotation field '" + name + "'"); }
// in src/org/python/expose/generate/RestrictiveAnnotationVisitor.java
public void visit(String name, Object value) { throw new IllegalArgumentException("Unknown annotation field '" + name + "'"); }
// in src/org/python/antlr/PythonTree.java
public void setChild(int i, PythonTree t) { if ( t==null ) { return; } if ( t.isNil() ) { throw new IllegalArgumentException("Can't set single child to a list"); } if ( children==null ) { children = createChildrenList(); } children.set(i, t); t.setParent(this); t.setChildIndex(i); }
// in src/org/python/antlr/PythonTree.java
public void replaceChildren(int startChildIndex, int stopChildIndex, Object t) { if ( children==null ) { throw new IllegalArgumentException("indexes invalid; no children in list"); } int replacingHowMany = stopChildIndex - startChildIndex + 1; int replacingWithHowMany; PythonTree newTree = (PythonTree)t; List<PythonTree> newChildren = null; // normalize to a list of children to add: newChildren if ( newTree.isNil() ) { newChildren = newTree.children; } else { newChildren = new ArrayList<PythonTree>(1); newChildren.add(newTree); } replacingWithHowMany = newChildren.size(); int numNewChildren = newChildren.size(); int delta = replacingHowMany - replacingWithHowMany; // if same number of nodes, do direct replace if ( delta == 0 ) { int j = 0; // index into new children for (int i=startChildIndex; i<=stopChildIndex; i++) { PythonTree child = newChildren.get(j); children.set(i, child); child.setParent(this); child.setChildIndex(i); j++; } } else if ( delta > 0 ) { // fewer new nodes than there were // set children and then delete extra for (int j=0; j<numNewChildren; j++) { children.set(startChildIndex+j, newChildren.get(j)); } int indexToDelete = startChildIndex+numNewChildren; for (int c=indexToDelete; c<=stopChildIndex; c++) { // delete same index, shifting everybody down each time PythonTree killed = children.remove(indexToDelete); } freshenParentAndChildIndexes(startChildIndex); } else { // more new nodes than were there before // fill in as many children as we can (replacingHowMany) w/o moving data for (int j=0; j<replacingHowMany; j++) { children.set(startChildIndex+j, newChildren.get(j)); } int numToInsert = replacingWithHowMany-replacingHowMany; for (int j=replacingHowMany; j<replacingWithHowMany; j++) { children.add(startChildIndex+j, newChildren.get(j)); } freshenParentAndChildIndexes(startChildIndex); } }
// in src/org/python/jsr223/PyScriptEngine.java
public <T> T getInterface(Object obj, Class<T> clazz) { if (obj == null) { throw new IllegalArgumentException("object expected"); } if (clazz == null || !clazz.isInterface()) { throw new IllegalArgumentException("interface expected"); } interp.setLocals(new PyScriptEngineScope(this, context)); final PyObject thiz = Py.java2py(obj); @SuppressWarnings("unchecked") T proxy = (T) Proxy.newProxyInstance( clazz.getClassLoader(), new Class[] { clazz }, new InvocationHandler() { public Object invoke(Object proxy, Method method, Object[] args) throws Throwable { try { interp.setLocals(new PyScriptEngineScope(PyScriptEngine.this, context)); PyObject pyMethod = thiz.__findattr__(method.getName()); if (pyMethod == null) throw new NoSuchMethodException(method.getName()); PyObject result = pyMethod.__call__(Py.javas2pys(args)); return result.__tojava__(Object.class); } catch (PyException pye) { throw scriptException(pye); } } }); return proxy; }
// in src/org/python/modules/jffi/FastIntInvokerFactory.java
final IntResultConverter getIntResultConverter(NativeType type) { switch (type) { case VOID: return VoidResultConverter.INSTANCE; case BYTE: return Signed8ResultConverter.INSTANCE; case UBYTE: return Unsigned8ResultConverter.INSTANCE; case SHORT: return Signed16ResultConverter.INSTANCE; case USHORT: return Unsigned16ResultConverter.INSTANCE; case INT: return Signed32ResultConverter.INSTANCE; case UINT: return Unsigned32ResultConverter.INSTANCE; case LONG: if (Platform.getPlatform().longSize() == 32) { return Signed32ResultConverter.INSTANCE; } break; case ULONG: if (Platform.getPlatform().longSize() == 32) { return Unsigned32ResultConverter.INSTANCE; } break; case STRING: if (Platform.getPlatform().addressSize() == 32) { return StringResultConverter.INSTANCE; } break; default: break; } throw new IllegalArgumentException("Cannot convert objects of type " + type + " from int"); }
// in src/org/python/core/PyTuple.java
public List subList(int fromIndex, int toIndex) { if (fromIndex < 0 || toIndex > size()) { throw new IndexOutOfBoundsException(); } else if (fromIndex > toIndex) { throw new IllegalArgumentException(); } PyObject elements[] = new PyObject[toIndex - fromIndex]; for (int i = 0, j = fromIndex; i < elements.length; i++, j++) { elements[i] = array[j]; } return new PyTuple(elements); }
// in src/org/python/core/AbstractArray.java
public void replaceSubArray(int thisStart, int thisStop, Object srcArray, int srcStart, int srcStop) { this.modCountIncr = 0; if (!srcArray.getClass().isArray()) { throw new IllegalArgumentException("'array' must be an array type"); } int replacedLen = thisStop - thisStart; if (thisStart < 0 || replacedLen < 0 || thisStop > this.size) { String message = null; if (thisStart < 0) { message = "thisStart < 0 (thisStart = " + thisStart + ")"; } else if (replacedLen < 0) { message = "thisStart > thistStop (thisStart = " + thisStart + ", thisStop = " + thisStop + ")"; } else if (thisStop > this.size) { message = "thisStop > size (thisStop = " + thisStop + ", size = " + this.size + ")"; } else { throw new InternalError("Incorrect validation logic"); } throw new ArrayIndexOutOfBoundsException(message); } int srcLen = Array.getLength(srcArray); int replacementLen = srcStop - srcStart; if (srcStart < 0 || replacementLen < 0 || srcStop > srcLen) { String message = null; if (srcStart < 0) { message = "srcStart < 0 (srcStart = " + srcStart +")"; } else if (replacementLen < 0) { message = "srcStart > srcStop (srcStart = " + srcStart + ", srcStop = " + srcStop + ")"; } else if (srcStop > srcLen) { message = "srcStop > srcArray length (srcStop = " + srcStop + ", srcArray length = " +srcLen + ")"; } else { throw new InternalError("Incorrect validation logic"); } throw new IllegalArgumentException("start, stop and array must follow:\n\t" + "0 <= start <= stop <= array length\nBut found\n\t" + message); } int lengthChange = replacementLen - replacedLen; // Adjust array size if needed. if (lengthChange < 0) { remove(thisStop + lengthChange, thisStop); } else if (lengthChange > 0) { makeInsertSpace(thisStop, lengthChange); } try { this.modCountIncr = 1; System.arraycopy(srcArray, srcStart, getArray(), thisStart, replacementLen); } catch (ArrayStoreException e) { throw new IllegalArgumentException("'ofArrayType' must be compatible with existing array type of " + getArray().getClass().getName() + "\tsee java.lang.Class.getName()."); } }
// in src/org/python/core/stringlib/MarkupIterator.java
public Chunk nextChunk() { if (index == markup.length()) { return null; } Chunk result = new Chunk(); int pos = index; while (true) { pos = indexOfFirst(markup, pos, '{', '}'); if (pos >= 0 && pos < markup.length() - 1 && markup.charAt(pos + 1) == markup.charAt(pos)) { // skip escaped bracket pos += 2; } else if (pos >= 0 && markup.charAt(pos) == '}') { throw new IllegalArgumentException("Single '}' encountered in format string"); } else { break; } } if (pos < 0) { result.literalText = unescapeBraces(markup.substring(index)); result.fieldName = ""; index = markup.length(); } else { result.literalText = unescapeBraces(markup.substring(index, pos)); pos++; int fieldStart = pos; int count = 1; while (pos < markup.length()) { if (markup.charAt(pos) == '{') { count++; result.formatSpecNeedsExpanding = true; } else if (markup.charAt(pos) == '}') { count--; if (count == 0) { parseField(result, markup.substring(fieldStart, pos)); pos++; break; } } pos++; } if (count > 0) { throw new IllegalArgumentException("Single '{' encountered in format string"); } index = pos; } return result; }
// in src/org/python/core/stringlib/MarkupIterator.java
private void parseField(Chunk result, String fieldMarkup) { int pos = indexOfFirst(fieldMarkup, 0, '!', ':'); if (pos >= 0) { result.fieldName = fieldMarkup.substring(0, pos); if (fieldMarkup.charAt(pos) == '!') { if (pos == fieldMarkup.length() - 1) { throw new IllegalArgumentException("end of format while " + "looking for conversion specifier"); } result.conversion = fieldMarkup.substring(pos + 1, pos + 2); pos += 2; if (pos < fieldMarkup.length()) { if (fieldMarkup.charAt(pos) != ':') { throw new IllegalArgumentException("expected ':' " + "after conversion specifier"); } result.formatSpec = fieldMarkup.substring(pos + 1); } } else { result.formatSpec = fieldMarkup.substring(pos + 1); } } else { result.fieldName = fieldMarkup; } }
// in src/org/python/core/stringlib/InternalFormatSpecParser.java
public InternalFormatSpec parse() { InternalFormatSpec result = new InternalFormatSpec(); if (spec.length() >= 1 && isAlign(spec.charAt(0))) { result.align = spec.charAt(index); index++; } else if (spec.length() >= 2 && isAlign(spec.charAt(1))) { result.fill_char = spec.charAt(0); result.align = spec.charAt(1); index += 2; } if (isAt("+- ")) { result.sign = spec.charAt(index); index++; } if (isAt("#")) { result.alternate = true; index++; } if (isAt("0")) { result.align = '='; result.fill_char = '0'; index++; } result.width = getInteger(); if (isAt(".")) { index++; result.precision = getInteger(); if (result.precision == -1) { throw new IllegalArgumentException("Format specifier missing precision"); } } if (index < spec.length()) { result.type = spec.charAt(index); if (index + 1 != spec.length()) { throw new IllegalArgumentException("Invalid conversion specification"); } } return result; }
// in src/org/python/core/stringlib/FieldNameIterator.java
private void parseItemChunk(Chunk chunk) { chunk.is_attr = false; int endBracket = markup.indexOf(']', index+1); if (endBracket < 0) { throw new IllegalArgumentException("Missing ']' in format string"); } String itemValue = markup.substring(index + 1, endBracket); if (itemValue.length() == 0) { throw new IllegalArgumentException("Empty attribute in format string"); } try { chunk.value = Integer.parseInt(itemValue); } catch (NumberFormatException e) { chunk.value = itemValue; } index = endBracket + 1; }
// in src/org/python/core/stringlib/FieldNameIterator.java
private void parseAttrChunk(Chunk chunk) { index++; // skip dot chunk.is_attr = true; int pos = nextDotOrBracket(markup); if (pos == index) { throw new IllegalArgumentException("Empty attribute in format string"); } chunk.value = markup.substring(index, pos); index = pos; }
// in src/org/python/core/PyRunnableBootstrap.java
public static CodeBootstrap getFilenameConstructorReflectionBootstrap( Class<? extends PyRunnable> cls) { final Constructor<? extends PyRunnable> constructor; try { constructor = cls.getConstructor(String.class); } catch (Exception e) { throw new IllegalArgumentException( "PyRunnable class does not specify apropriate constructor.", e); } return new CodeBootstrap() { public PyCode loadCode(CodeLoader loader) { try { return constructor.newInstance(loader.filename).getMain(); } catch (Exception e) { throw new IllegalArgumentException( "PyRunnable class constructor does not support instantiation protocol.", e); } } }; }
// in src/org/python/core/PyRunnableBootstrap.java
public PyCode loadCode(CodeLoader loader) { try { return constructor.newInstance(loader.filename).getMain(); } catch (Exception e) { throw new IllegalArgumentException( "PyRunnable class constructor does not support instantiation protocol.", e); } }
// in src/org/python/core/Py.java
static final PyString makeCharacter(int codepoint, boolean toUnicode) { if (toUnicode) { return new PyUnicode(codepoint); } else if (codepoint > 65536) { throw new IllegalArgumentException(String.format("Codepoint > 65536 (%d) requires " + "toUnicode argument", codepoint)); } else if (codepoint > 256) { return new PyString((char)codepoint); } return letters[codepoint]; }
// in src/org/python/core/PyInteger.java
public static String formatIntOrLong(Object value, InternalFormatSpec spec) { if (spec.precision != -1) { throw new IllegalArgumentException("Precision not allowed in integer format specifier"); } int sign; if (value instanceof Integer) { int intValue = (Integer) value; sign = intValue < 0 ? -1 : intValue == 0 ? 0 : 1; } else { sign = ((BigInteger) value).signum(); } String strValue; if (spec.type == 'c') { if (spec.sign != '\0') { throw new IllegalArgumentException("Sign not allowed with integer format " + "specifier 'c'"); } if (value instanceof Integer) { int intValue = (Integer) value; if (intValue > 0xffff) { throw new IllegalArgumentException("%c arg not in range(0x10000)"); } strValue = Character.toString((char) intValue); } else { BigInteger bigInt = (BigInteger) value; if (bigInt.intValue() > 0xffff || bigInt.bitCount() > 16) { throw new IllegalArgumentException("%c arg not in range(0x10000)"); } strValue = Character.toString((char) bigInt.intValue()); } } else { int radix = 10; if (spec.type == 'o') { radix = 8; } else if (spec.type == 'x' || spec.type == 'X') { radix = 16; } else if (spec.type == 'b') { radix = 2; } // TODO locale-specific formatting for 'n' if (value instanceof BigInteger) { strValue = ((BigInteger) value).toString(radix); } else { strValue = Integer.toString((Integer) value, radix); } if (spec.alternate) { if (radix == 2) { strValue = "0b" + strValue; } else if (radix == 8) { strValue = "0o" + strValue; } else if (radix == 16) { strValue = "0x" + strValue; } } if (spec.type == 'X') { strValue = strValue.toUpperCase(); } if (sign >= 0) { if (spec.sign == '+') { strValue = "+" + strValue; } else if (spec.sign == ' ') { strValue = " " + strValue; } } } if (spec.align == '=' && (sign < 0 || spec.sign == '+' || spec.sign == ' ')) { char signChar = strValue.charAt(0); return signChar + spec.pad(strValue.substring(1), '>', 1); } return spec.pad(strValue, '>', 0); }
3
              
// in src/org/python/core/AbstractArray.java
catch (ArrayStoreException e) { throw new IllegalArgumentException("'ofArrayType' must be compatible with existing array type of " + getArray().getClass().getName() + "\tsee java.lang.Class.getName()."); }
// in src/org/python/core/PyRunnableBootstrap.java
catch (Exception e) { throw new IllegalArgumentException( "PyRunnable class does not specify apropriate constructor.", e); }
// in src/org/python/core/PyRunnableBootstrap.java
catch (Exception e) { throw new IllegalArgumentException( "PyRunnable class constructor does not support instantiation protocol.", e); }
2
              
// in src/org/python/core/CodeLoader.java
public static PyCode loadCode(Class<?> cls, String name, String filename) throws SecurityException, NoSuchMethodException, IllegalArgumentException, IllegalAccessException, InvocationTargetException { Method getBootstrap = cls.getMethod(GET_BOOTSTRAP_METHOD_NAME); CodeBootstrap bootstrap = (CodeBootstrap) getBootstrap.invoke(null); return loadCode(bootstrap, name, filename); }
// in src/org/python/core/CodeLoader.java
public static PyCode loadCode(Class<?> cls) throws SecurityException, IllegalArgumentException, NoSuchMethodException, IllegalAccessException, InvocationTargetException { return loadCode(cls, null, null); }
(Domain) PyException 56
              
// in src/org/python/modules/binascii.java
public static PyString a2b_uu(String ascii_data) { int leftbits = 0; int leftchar = 0; if (ascii_data.length() == 0) return new PyString(""); StringBuilder bin_data = new StringBuilder(); char this_ch; int i; int ascii_len = ascii_data.length()-1; int bin_len = (ascii_data.charAt(0) - ' ') & 077; for (i = 0; bin_len > 0 && ascii_len > 0; i++, ascii_len--) { this_ch = ascii_data.charAt(i+1); if (this_ch == '\n' || this_ch == '\r' || ascii_len <= 0) { // Whitespace. Assume some spaces got eaten at // end-of-line. (We check this later) this_ch = 0; } else { // Check the character for legality // The 64 in stead of the expected 63 is because // there are a few uuencodes out there that use // '@' as zero instead of space. if ( this_ch < ' ' || this_ch > (' ' + 64)) { throw new PyException(Error, "Illegal char"); } this_ch = (char)((this_ch - ' ') & 077); } // Shift it in on the low end, and see if there's // a byte ready for output. leftchar = (leftchar << 6) | (this_ch); leftbits += 6; if (leftbits >= 8) { leftbits -= 8; bin_data.append((char)((leftchar >> leftbits) & 0xff)); leftchar &= ((1 << leftbits) - 1); bin_len--; } } // Finally, check that if there's anything left on the line // that it's whitespace only. while (ascii_len-- > 0) { this_ch = ascii_data.charAt(++i); // Extra '@' may be written as padding in some cases if (this_ch != ' ' && this_ch != '@' && this_ch != '\n' && this_ch != '\r') { throw new PyException(Error, "Trailing garbage"); } } // finally, if we haven't decoded enough stuff, fill it up with zeros for (; i<bin_len; i++) bin_data.append((char)0); return new PyString(bin_data.toString()); }
// in src/org/python/modules/binascii.java
public static PyString b2a_uu(String bin_data) { int leftbits = 0; char this_ch; int leftchar = 0; int bin_len = bin_data.length(); if (bin_len > 45) { // The 45 is a limit that appears in all uuencode's throw new PyException(Error, "At most 45 bytes at once"); } StringBuilder ascii_data = new StringBuilder(); // Store the length */ ascii_data.append((char)(' ' + (bin_len & 077))); for (int i = 0; bin_len > 0 || leftbits != 0; i++, bin_len--) { // Shift the data (or padding) into our buffer if (bin_len > 0) // Data leftchar = (leftchar << 8) | bin_data.charAt(i); else // Padding leftchar <<= 8; leftbits += 8; // See if there are 6-bit groups ready while (leftbits >= 6) { this_ch = (char)((leftchar >> (leftbits-6)) & 0x3f); leftbits -= 6; ascii_data.append((char)(this_ch + ' ')); } } ascii_data.append('\n'); // Append a courtesy newline return new PyString(ascii_data.toString()); }
// in src/org/python/modules/binascii.java
public static PyString a2b_base64(String ascii_data) { int leftbits = 0; char this_ch; int leftchar = 0; int quad_pos = 0; int ascii_len = ascii_data.length(); int bin_len = 0; StringBuilder bin_data = new StringBuilder(); for(int i = 0; ascii_len > 0 ; ascii_len--, i++) { // Skip some punctuation this_ch = ascii_data.charAt(i); if (this_ch > 0x7F || this_ch == '\r' || this_ch == '\n' || this_ch == ' ') continue; if (this_ch == BASE64_PAD) { if (quad_pos < 2 || (quad_pos == 2 && binascii_find_valid(ascii_data, i, 1) != BASE64_PAD)) continue; else { // A pad sequence means no more input. // We've already interpreted the data // from the quad at this point. leftbits = 0; break; } } short this_v = table_a2b_base64[this_ch]; if (this_v == -1) continue; // Shift it in on the low end, and see if there's // a byte ready for output. quad_pos = (quad_pos + 1) & 0x03; leftchar = (leftchar << 6) | (this_v); leftbits += 6; if (leftbits >= 8) { leftbits -= 8; bin_data.append((char)((leftchar >> leftbits) & 0xff)); bin_len++; leftchar &= ((1 << leftbits) - 1); } } // Check that no bits are left if (leftbits != 0) { throw new PyException(Error, "Incorrect padding"); } return new PyString(bin_data.toString()); }
// in src/org/python/modules/binascii.java
public static PyString b2a_base64(String bin_data) { int leftbits = 0; char this_ch; int leftchar = 0; StringBuilder ascii_data = new StringBuilder(); int bin_len = bin_data.length(); if (bin_len > BASE64_MAXBIN) { throw new PyException(Error,"Too much data for base64 line"); } for (int i = 0; bin_len > 0 ; bin_len--, i++) { // Shift the data into our buffer leftchar = (leftchar << 8) | bin_data.charAt(i); leftbits += 8; // See if there are 6-bit groups ready while (leftbits >= 6) { this_ch = (char)((leftchar >> (leftbits-6)) & 0x3f); leftbits -= 6; ascii_data.append((char)table_b2a_base64[this_ch]); } } if (leftbits == 2) { ascii_data.append((char)table_b2a_base64[(leftchar&3) << 4]); ascii_data.append(BASE64_PAD); ascii_data.append(BASE64_PAD); } else if (leftbits == 4) { ascii_data.append((char)table_b2a_base64[(leftchar&0xf) << 2]); ascii_data.append(BASE64_PAD); } ascii_data.append('\n'); // Append a courtesy newline return new PyString(ascii_data.toString()); }
// in src/org/python/modules/binascii.java
public static PyTuple a2b_hqx(String ascii_data) { int leftbits = 0; char this_ch; int leftchar = 0; boolean done = false; int len = ascii_data.length(); StringBuilder bin_data = new StringBuilder(); for(int i = 0; len > 0 ; len--, i++) { // Get the byte and look it up this_ch = (char) table_a2b_hqx[ascii_data.charAt(i)]; if (this_ch == SKIP) continue; if (this_ch == FAIL) { throw new PyException(Error, "Illegal char"); } if (this_ch == DONE) { // The terminating colon done = true; break; } // Shift it into the buffer and see if any bytes are ready leftchar = (leftchar << 6) | (this_ch); leftbits += 6; if (leftbits >= 8) { leftbits -= 8; bin_data.append((char)((leftchar >> leftbits) & 0xff)); leftchar &= ((1 << leftbits) - 1); } } if (leftbits != 0 && !done) { throw new PyException(Incomplete, "String has incomplete number of bytes"); } return new PyTuple(Py.java2py(bin_data.toString()), Py.newInteger(done ? 1 : 0)); }
// in src/org/python/modules/binascii.java
static public String rledecode_hqx(String in_data) { char in_byte, in_repeat; int in_len = in_data.length(); int i = 0; // Empty string is a special case if (in_len == 0) return ""; StringBuilder out_data = new StringBuilder(); // Handle first byte separately (since we have to get angry // in case of an orphaned RLE code). if (--in_len < 0) throw new PyException(Incomplete); in_byte = in_data.charAt(i++); if (in_byte == RUNCHAR) { if (--in_len < 0) throw new PyException(Incomplete); in_repeat = in_data.charAt(i++); if (in_repeat != 0) { // Note Error, not Incomplete (which is at the end // of the string only). This is a programmer error. throw new PyException(Error, "Orphaned RLE code at start"); } out_data.append(RUNCHAR); } else { out_data.append(in_byte); } while (in_len > 0) { if (--in_len < 0) throw new PyException(Incomplete); in_byte = in_data.charAt(i++); if (in_byte == RUNCHAR) { if (--in_len < 0) throw new PyException(Incomplete); in_repeat = in_data.charAt(i++); if (in_repeat == 0) { // Just an escaped RUNCHAR value out_data.append(RUNCHAR); } else { // Pick up value and output a sequence of it in_byte = out_data.charAt(out_data.length()-1); while (--in_repeat > 0) out_data.append(in_byte); } } else { // Normal byte out_data.append(in_byte); } } return out_data.toString(); }
// in src/org/python/modules/posix/PosixModule.java
public static void rename(String oldpath, String newpath) { if (!new RelativeFile(oldpath).renameTo(new RelativeFile(newpath))) { PyObject args = new PyTuple(Py.Zero, new PyString("Couldn't rename file")); throw new PyException(Py.OSError, args); } }
// in src/org/python/modules/posix/PosixModule.java
public static void rmdir(String path) { File file = new RelativeFile(path); if (!file.exists()) { throw Py.OSError(Errno.ENOENT, path); } else if (!file.isDirectory()) { throw Py.OSError(Errno.ENOTDIR, path); } else if (!file.delete()) { PyObject args = new PyTuple(Py.Zero, new PyString("Couldn't delete directory"), new PyString(path)); throw new PyException(Py.OSError, args); } }
// in src/org/python/modules/thread/thread.java
public static void exit_thread() { throw new PyException(Py.SystemExit, new PyInteger(0)); }
// in src/org/python/modules/cPickle.java
private void save(PyObject object, boolean pers_save) { if (!pers_save && persistent_id != null && save_pers(object, persistent_id)) { return; } int d = get_id(object); PyType t = object.getType(); if (t == TupleType && object.__len__() == 0) { if (protocol > 0) save_empty_tuple(object); else save_tuple(object); return; } int m = getMemoPosition(d, object); if (m >= 0) { get(m); return; } if (save_type(object, t)) return; if (!pers_save && inst_persistent_id != null && save_pers(object, inst_persistent_id)) { return; } if (Py.isSubClass(t, PyType.TYPE)) { save_global(object); return; } PyObject tup = null; PyObject reduce = dispatch_table.__finditem__(t); if (reduce == null) { reduce = object.__findattr__("__reduce_ex__"); if (reduce != null) { tup = reduce.__call__(Py.newInteger(protocol)); } else { reduce = object.__findattr__("__reduce__"); if (reduce == null) throw new PyException(UnpickleableError, object); tup = reduce.__call__(); } } else { tup = reduce.__call__(object); } if (tup instanceof PyString) { save_global(object, tup); return; } if (!(tup instanceof PyTuple)) { throw new PyException(PicklingError, "Value returned by " + reduce.__repr__() + " must be a tuple"); } int l = tup.__len__(); if (l < 2 || l > 5) { throw new PyException(PicklingError, "tuple returned by " + reduce.__repr__() + " must contain two to five elements"); } PyObject callable = tup.__finditem__(0); PyObject arg_tup = tup.__finditem__(1); PyObject state = (l > 2) ? tup.__finditem__(2) : Py.None; PyObject listitems = (l > 3) ? tup.__finditem__(3) : Py.None; PyObject dictitems = (l > 4) ? tup.__finditem__(4) : Py.None; if (!(arg_tup instanceof PyTuple) && arg_tup != Py.None) { throw new PyException(PicklingError, "Second element of tupe returned by " + reduce.__repr__() + " must be a tuple"); } save_reduce(callable, arg_tup, state, listitems, dictitems, object); }
// in src/org/python/modules/cPickle.java
final private boolean save_pers(PyObject object, PyObject pers_func) { PyObject pid = pers_func.__call__(object); if (pid == Py.None) { return false; } if (protocol == 0) { if (!Py.isInstance(pid, PyString.TYPE)) { throw new PyException(PicklingError, "persistent id must be string"); } file.write(PERSID); file.write(pid.toString()); file.write("\n"); } else { save(pid, true); file.write(BINPERSID); } return true; }
// in src/org/python/modules/cPickle.java
final private void save_reduce(PyObject callable, PyObject arg_tup, PyObject state, PyObject listitems, PyObject dictitems, PyObject object) { PyObject callableName = callable.__findattr__("__name__"); if(protocol >= 2 && callableName != null && "__newobj__".equals(callableName.toString())) { PyObject cls = arg_tup.__finditem__(0); if(cls.__findattr__("__new__") == null) throw new PyException(PicklingError, "args[0] from __newobj__ args has no __new__"); // TODO: check class save(cls); save(arg_tup.__getslice__(Py.One, Py.None)); file.write(NEWOBJ); } else { save(callable); save(arg_tup); file.write(REDUCE); } // Memoize put(putMemo(get_id(object), object)); if (listitems != Py.None) { batch_appends(listitems); } if (dictitems != Py.None) { batch_setitems(dictitems); } if (state != Py.None) { save(state); file.write(BUILD); } }
// in src/org/python/modules/cPickle.java
public PyObject load() { stackTop = 0; stack = new PyObject[10]; while (true) { String s = file.read(1); // System.out.println("load:" + s); // for (int i = 0; i < stackTop; i++) // System.out.println(" " + stack[i]); if (s.length() < 1) load_eof(); char key = s.charAt(0); switch (key) { case PERSID: load_persid(); break; case BINPERSID: load_binpersid(); break; case NONE: load_none(); break; case INT: load_int(); break; case BININT: load_binint(); break; case BININT1: load_binint1(); break; case BININT2: load_binint2(); break; case LONG: load_long(); break; case FLOAT: load_float(); break; case BINFLOAT: load_binfloat(); break; case STRING: load_string(); break; case BINSTRING: load_binstring(); break; case SHORT_BINSTRING: load_short_binstring(); break; case UNICODE: load_unicode(); break; case BINUNICODE: load_binunicode(); break; case TUPLE: load_tuple(); break; case EMPTY_TUPLE: load_empty_tuple(); break; case EMPTY_LIST: load_empty_list(); break; case EMPTY_DICT: load_empty_dictionary(); break; case LIST: load_list(); break; case DICT: load_dict(); break; case INST: load_inst(); break; case OBJ: load_obj(); break; case GLOBAL: load_global(); break; case REDUCE: load_reduce(); break; case POP: load_pop(); break; case POP_MARK: load_pop_mark(); break; case DUP: load_dup(); break; case GET: load_get(); break; case BINGET: load_binget(); break; case LONG_BINGET: load_long_binget(); break; case PUT: load_put(); break; case BINPUT: load_binput(); break; case LONG_BINPUT: load_long_binput(); break; case APPEND: load_append(); break; case APPENDS: load_appends(); break; case SETITEM: load_setitem(); break; case SETITEMS: load_setitems(); break; case BUILD: load_build(); break; case MARK: load_mark(); break; case PROTO: load_proto(); break; case NEWOBJ: load_newobj(); break; case EXT1: load_ext(1); break; case EXT2: load_ext(2); break; case EXT4: load_ext(4); break; case TUPLE1: load_small_tuple(1); break; case TUPLE2: load_small_tuple(2); break; case TUPLE3: load_small_tuple(3); break; case NEWTRUE: load_boolean(true); break; case NEWFALSE: load_boolean(false); break; case LONG1: load_bin_long(1); break; case LONG4: load_bin_long(4); break; case STOP: return load_stop(); default: throw new PyException(UnpicklingError, String.format("invalid load key, '%s'.", key)); } } }
// in src/org/python/modules/cPickle.java
final private int marker() { for (int k = stackTop-1; k >= 0; k--) if (stack[k] == mark) return stackTop-k-1; throw new PyException(UnpicklingError, "Inputstream corrupt, marker not found"); }
// in src/org/python/modules/cPickle.java
final private void load_eof() { throw new PyException(Py.EOFError); }
// in src/org/python/modules/cPickle.java
final private void load_persid(PyObject pid) { if (persistent_load == null) { throw new PyException(UnpicklingError, "A load persistent id instruction was encountered,\n" + "but no persistent_load function was specified."); } if (persistent_load instanceof PyList) { ((PyList)persistent_load).append(pid); } else { pid = persistent_load.__call__(pid); } push(pid); }
// in src/org/python/modules/cPickle.java
final private PyObject find_class(String module, String name) { if (find_global != null) { if (find_global == Py.None) throw new PyException(UnpicklingError, "Global and instance pickles are not supported."); return find_global.__call__(new PyString(module), new PyString(name)); } PyObject modules = Py.getSystemState().modules; PyObject mod = modules.__finditem__(module.intern()); if (mod == null) { mod = importModule(module); } PyObject global = mod.__findattr__(name.intern()); if (global == null) { throw new PyException(Py.SystemError, "Failed to import class " + name + " from module " + module); } return global; }
// in src/org/python/modules/cPickle.java
private void load_ext(int length) { int code = read_binint(length); // TODO: support _extension_cache PyObject key = inverted_registry.get(Py.newInteger(code)); if (key == null) { throw new PyException(Py.ValueError, "unregistered extension code " + code); } String module = key.__finditem__(0).toString(); String name = key.__finditem__(1).toString(); push(find_class(module, name)); }
// in src/org/python/modules/cPickle.java
final private void load_get() { String py_str = file.readlineNoNl(); PyObject value = memo.get(py_str); if (value == null) { throw new PyException(BadPickleGet, py_str); } push(value); }
// in src/org/python/modules/cPickle.java
final private void load_binget() { String py_key = String.valueOf((int)file.read(1).charAt(0)); PyObject value = memo.get(py_key); if (value == null) { throw new PyException(BadPickleGet, py_key); } push(value); }
// in src/org/python/modules/cPickle.java
final private void load_long_binget() { int i = read_binint(); String py_key = String.valueOf(i); PyObject value = memo.get(py_key); if (value == null) { throw new PyException(BadPickleGet, py_key); } push(value); }
// in src/org/python/modules/cPickle.java
private void load_build() { PyObject state = pop(); PyObject inst = peek(); PyObject setstate = inst.__findattr__("__setstate__"); if (setstate != null) { // The explicit __setstate__ is responsible for everything. setstate.__call__(state); return; } // A default __setstate__. First see whether state embeds a slot state dict // too (a proto 2 addition). PyObject slotstate = null; if (state instanceof PyTuple && state.__len__() == 2) { PyObject temp = state; state = temp.__getitem__(0); slotstate = temp.__getitem__(1); } if (state != Py.None) { if (!(state instanceof PyDictionary)) { throw new PyException(UnpicklingError, "state is not a dictionary"); } PyObject dict = inst.__getattr__("__dict__"); for (PyObject item : ((PyDictionary)state).iteritems().asIterable()) { dict.__setitem__(item.__getitem__(0), item.__getitem__(1)); } } // Also set instance attributes from the slotstate dict (if any). if (slotstate != null) { if (!(slotstate instanceof PyDictionary)) { throw new PyException(UnpicklingError, "slot state is not a dictionary"); } for (PyObject item : ((PyDictionary)slotstate).iteritems().asIterable()) { inst.__setattr__(PyObject.asName(item.__getitem__(0)), item.__getitem__(1)); } } }
// in src/org/python/modules/time/Time.java
private static void throwValueError(String msg) { throw new PyException(Py.ValueError, new PyString(msg)); }
// in src/org/python/modules/time/Time.java
private synchronized static String _shortday(int dow) { // we need to hand craft shortdays[] because Java and Python have // different specifications. Java (undocumented) appears to be // first element "", followed by 0=Sun. Python says 0=Mon if (shortdays == null) { shortdays = new String[7]; String[] names = datesyms.getShortWeekdays(); for (int i = 0; i < 6; i++) { shortdays[i] = names[i + 2]; } shortdays[6] = names[1]; } try { return shortdays[dow]; } catch (ArrayIndexOutOfBoundsException e) { throw new PyException(Py.ValueError, new PyString("day of week out of range (0-6)")); } }
// in src/org/python/modules/time/Time.java
private synchronized static String _shortmonth(int month0to11) { // getShortWeekdays() returns a 13 element array with the last item // being the empty string. This is also undocumented ;-/ if (shortmonths == null) { shortmonths = new String[12]; String[] names = datesyms.getShortMonths(); for (int i = 0; i < 12; i++) { shortmonths[i] = names[i]; } } try { return shortmonths[month0to11]; } catch (ArrayIndexOutOfBoundsException e) { throw new PyException(Py.ValueError, new PyString("month out of range (1-12)")); } }
// in src/org/python/modules/time/Time.java
public static void sleep(double secs) { try { java.lang.Thread.sleep((long)(secs * 1000)); } catch (java.lang.InterruptedException e) { throw new PyException(Py.KeyboardInterrupt, "interrupted sleep"); } }
// in src/org/python/core/PySystemState.java
public static void exit(PyObject status) { throw new PyException(Py.SystemExit, status); }
// in src/org/python/core/PyTableCode.java
Override public PyObject call(ThreadState ts, PyFrame frame, PyObject closure) { // System.err.println("tablecode call: "+co_name); if (ts.systemState == null) { ts.systemState = Py.defaultSystemState; } //System.err.println("got ts: "+ts+", "+ts.systemState); // Cache previously defined exception PyException previous_exception = ts.exception; // Push frame frame.f_back = ts.frame; if (frame.f_builtins == null) { if (frame.f_back != null) { frame.f_builtins = frame.f_back.f_builtins; } else { //System.err.println("ts: "+ts); //System.err.println("ss: "+ts.systemState); frame.f_builtins = PySystemState.builtins; } } // nested scopes: setup env with closure // this should only be done once, so let the frame take care of it frame.setupEnv((PyTuple)closure); ts.frame = frame; // Handle trace function for debugging if (ts.tracefunc != null) { frame.f_lineno = co_firstlineno; frame.tracefunc = ts.tracefunc.traceCall(frame); } // Handle trace function for profiling if (ts.profilefunc != null) { ts.profilefunc.traceCall(frame); } PyObject ret; try { ret = funcs.call_function(func_id, frame, ts); } catch (Throwable t) { // Convert exceptions that occured in Java code to PyExceptions PyException pye = Py.JavaError(t); pye.tracebackHere(frame); frame.f_lasti = -1; if (frame.tracefunc != null) { frame.tracefunc.traceException(frame, pye); } if (ts.profilefunc != null) { ts.profilefunc.traceException(frame, pye); } // Rethrow the exception to the next stack frame ts.exception = previous_exception; ts.frame = ts.frame.f_back; throw pye; } if (frame.tracefunc != null) { frame.tracefunc.traceReturn(frame, ret); } // Handle trace function for profiling if (ts.profilefunc != null) { ts.profilefunc.traceReturn(frame, ret); } // Restore previously defined exception ts.exception = previous_exception; ts.frame = ts.frame.f_back; // Check for interruption, which is used for restarting the interpreter // on Jython if (ts.systemState._systemRestart && Thread.currentThread().isInterrupted()) { throw new PyException(_systemrestart.SystemRestart); } return ret; }
// in src/org/python/core/PyBaseCode.java
public PyObject call(ThreadState ts, PyFrame frame, PyObject closure) { // System.err.println("tablecode call: "+co_name); if (ts.systemState == null) { ts.systemState = Py.defaultSystemState; } //System.err.println("got ts: "+ts+", "+ts.systemState); // Cache previously defined exception PyException previous_exception = ts.exception; // Push frame frame.f_back = ts.frame; if (frame.f_builtins == null) { if (frame.f_back != null) { frame.f_builtins = frame.f_back.f_builtins; } else { //System.err.println("ts: "+ts); //System.err.println("ss: "+ts.systemState); frame.f_builtins = PySystemState.builtins; } } // nested scopes: setup env with closure // this should only be done once, so let the frame take care of it frame.setupEnv((PyTuple)closure); ts.frame = frame; // Handle trace function for debugging if (ts.tracefunc != null) { frame.f_lineno = co_firstlineno; frame.tracefunc = ts.tracefunc.traceCall(frame); } // Handle trace function for profiling if (ts.profilefunc != null) { ts.profilefunc.traceCall(frame); } PyObject ret; try { ret = interpret(frame, ts); } catch (Throwable t) { // Convert exceptions that occured in Java code to PyExceptions PyException pye = Py.JavaError(t); pye.tracebackHere(frame); frame.f_lasti = -1; if (frame.tracefunc != null) { frame.tracefunc.traceException(frame, pye); } if (ts.profilefunc != null) { ts.profilefunc.traceException(frame, pye); } // Rethrow the exception to the next stack frame ts.exception = previous_exception; ts.frame = ts.frame.f_back; throw pye; } if (frame.tracefunc != null) { frame.tracefunc.traceReturn(frame, ret); } // Handle trace function for profiling if (ts.profilefunc != null) { ts.profilefunc.traceReturn(frame, ret); } // Restore previously defined exception ts.exception = previous_exception; ts.frame = ts.frame.f_back; // Check for interruption, which is used for restarting the interpreter // on Jython if (ts.systemState._systemRestart && Thread.currentThread().isInterrupted()) { throw new PyException(_systemrestart.SystemRestart); } return ret; }
// in src/org/python/core/PyArray.java
public void append(PyObject value) { // Currently, this is asymmetric with extend, which // *will* do conversions like append(5.0) to an int array. // Also, cpython 2.2 will do the append coersion. However, // it is deprecated in cpython 2.3, so maybe we are just // ahead of our time ;-) int afterLast = delegate.getSize(); if ("u".equals(typecode)) { int codepoint = getCodePoint(value); delegate.makeInsertSpace(afterLast); Array.setInt(data, afterLast, codepoint); } else { delegate.makeInsertSpace(afterLast); try { set(afterLast, value); } catch (PyException e) { delegate.setSize(afterLast); throw new PyException(e.type, e.value); } } }
// in src/org/python/core/PyArray.java
public void fromlist(PyObject obj) { if(!(obj instanceof PyList)) { throw Py.TypeError("arg must be list"); } // store the current size of the internal array int size = delegate.getSize(); try { extendInternalIter(obj); } catch(PyException e) { // trap any exception - any error invalidates the whole list delegate.setSize(size); // re-throw throw new PyException(e.type, e.value); } }
// in src/org/python/core/Py.java
public static void assert_(PyObject test, PyObject message) { if (!test.__nonzero__()) { throw new PyException(Py.AssertionError, message); } }
// in src/org/python/core/codecs.java
public static PyObject lookup_error(String handlerName) { registry_init(); if (handlerName == null) { handlerName = "strict"; } PyObject handler = errorHandlers.__finditem__(handlerName.intern()); if (handler == null) { throw new PyException(Py.LookupError, "unknown error handler name '" + handlerName + "'"); } return handler; }
// in src/org/python/core/codecs.java
public static PyTuple lookup(String encoding) { registry_init(); PyString v = new PyString(normalizestring(encoding)); PyObject cached = searchCache.__finditem__(v); if (cached != null) { return (PyTuple)cached; } if (searchPath.__len__() == 0) { throw new PyException(Py.LookupError, "no codec search functions registered: can't find encoding '" + encoding + "'"); } for (PyObject func : searchPath.asIterable()) { PyObject created = func.__call__(v); if (created == Py.None) { continue; } if (!(created instanceof PyTuple) || created.__len__() != 4) { throw Py.TypeError("codec search functions must return 4-tuples"); } searchCache.__setitem__(v, created); return (PyTuple)created; } throw new PyException(Py.LookupError, "unknown encoding '" + encoding + "'"); }
// in src/org/python/core/codecs.java
public static PyObject strict_errors(PyObject[] args, String[] kws) { ArgParser ap = new ArgParser("strict_errors", args, kws, "exc"); PyObject exc = ap.getPyObject(0); if (Py.isInstance(exc, Py.UnicodeDecodeError)) { throw new PyException(Py.UnicodeDecodeError, exc); } else if (Py.isInstance(exc, Py.UnicodeEncodeError)) { throw new PyException(Py.UnicodeEncodeError, exc); } else if (Py.isInstance(exc, Py.UnicodeTranslateError)) { throw new PyException(Py.UnicodeTranslateError, exc); } throw wrong_exception_type(exc); }
// in src/org/python/core/codecs.java
private static void checkErrorHandlerReturn(String errors, PyObject replacement) { if (!(replacement instanceof PyTuple) || replacement.__len__() != 2 || !(replacement.__getitem__(0) instanceof PyBaseString) || !(replacement.__getitem__(1) instanceof PyInteger)) { throw new PyException(Py.TypeError, "error_handler " + errors + " must return a tuple of (replacement, new position)"); } }
// in src/org/python/core/PyLong.java
Override public int asIndex(PyObject err) { boolean tooLow = getValue().compareTo(PyInteger.MIN_INT) < 0; boolean tooHigh = getValue().compareTo(PyInteger.MAX_INT) > 0; if (tooLow || tooHigh) { if (err != null) { throw new PyException(err, "cannot fit 'long' into an index-sized integer"); } return tooLow ? Integer.MIN_VALUE : Integer.MAX_VALUE; } return (int) getValue().longValue(); }
// in src/org/python/core/PyString.java
public String translate(PyObject table) { StringBuilder v = new StringBuilder(getString().length()); for (int i=0; i < getString().length(); i++) { char ch = getString().charAt(i); PyObject w = Py.newInteger(ch); PyObject x = table.__finditem__(w); if (x == null) { /* No mapping found: default to 1-1 mapping */ v.append(ch); continue; } /* Apply mapping */ if (x instanceof PyInteger) { int value = ((PyInteger) x).getValue(); v.append((char) value); } else if (x == Py.None) { ; } else if (x instanceof PyString) { if (x.__len__() != 1) { /* 1-n mapping */ throw new PyException(Py.NotImplementedError, "1-n mappings are currently not implemented"); } v.append(x.toString()); } else { /* wrong return value */ throw Py.TypeError( "character mapping must return integer, " + "None or unicode"); } } return v.toString(); }
// in src/org/python/util/ReadlineConsole.java
public String raw_input(PyObject prompt) { try { String line = Readline.readline(prompt == null ? "" : prompt.toString()); return (line == null ? "" : line); } catch(EOFException eofe) { throw new PyException(Py.EOFError); } catch(IOException ioe) { throw new PyException(Py.IOError); } }
8
              
// in src/org/python/modules/time/Time.java
catch (ArrayIndexOutOfBoundsException e) { throw new PyException(Py.ValueError, new PyString("day of week out of range (0-6)")); }
// in src/org/python/modules/time/Time.java
catch (ArrayIndexOutOfBoundsException e) { throw new PyException(Py.ValueError, new PyString("month out of range (1-12)")); }
// in src/org/python/modules/time/Time.java
catch (java.lang.InterruptedException e) { throw new PyException(Py.KeyboardInterrupt, "interrupted sleep"); }
// in src/org/python/core/PySet.java
catch (NoSuchElementException e) { throw new PyException(Py.KeyError, "pop from an empty set"); }
// in src/org/python/core/PyArray.java
catch (PyException e) { delegate.setSize(afterLast); throw new PyException(e.type, e.value); }
// in src/org/python/core/PyArray.java
catch(PyException e) { // trap any exception - any error invalidates the whole list delegate.setSize(size); // re-throw throw new PyException(e.type, e.value); }
// in src/org/python/util/ReadlineConsole.java
catch(EOFException eofe) { throw new PyException(Py.EOFError); }
// in src/org/python/util/ReadlineConsole.java
catch(IOException ioe) { throw new PyException(Py.IOError); }
4
              
// in src/com/ziclix/python/sql/zxJDBC.java
protected static void _addSqlTypes(PyObject dict) throws PyException { PyDictionary sqltype = new PyDictionary(); dict.__setitem__("sqltype", sqltype); try { Class<?> c = Class.forName("java.sql.Types"); Field[] fields = c.getFields(); for (Field f : fields) { PyString name = Py.newString(f.getName()); PyObject value = new DBApiType(f.getInt(c)); dict.__setitem__(name, value); sqltype.__setitem__(value, name); } c = Class.forName("java.sql.ResultSet"); fields = c.getFields(); for (Field f : fields) { PyString name = Py.newString(f.getName()); PyObject value = Py.newInteger(f.getInt(c)); dict.__setitem__(name, value); } } catch (Throwable t) { throw makeException(t); } dict.__setitem__("ROWID", dict.__getitem__(Py.newString("OTHER"))); dict.__setitem__("NUMBER", dict.__getitem__(Py.newString("NUMERIC"))); dict.__setitem__("STRING", dict.__getitem__(Py.newString("VARCHAR"))); dict.__setitem__("DATETIME", dict.__getitem__(Py.newString("TIMESTAMP"))); }
// in src/com/ziclix/python/sql/zxJDBC.java
protected static void _addConnectors(PyObject dict) throws PyException { PyObject connector = Py.None; Properties props = new Properties(); props.put("connect", "com.ziclix.python.sql.connect.Connect"); props.put("lookup", "com.ziclix.python.sql.connect.Lookup"); props.put("connectx", "com.ziclix.python.sql.connect.Connectx"); Enumeration<?> names = props.propertyNames(); while (names.hasMoreElements()) { String name = ((String) names.nextElement()).trim(); String className = props.getProperty(name).trim(); try { connector = (PyObject) Class.forName(className).newInstance(); dict.__setitem__(name, connector); Py.writeComment("zxJDBC", "loaded connector [" + className + "] as [" + name + "]"); } catch (Throwable t) { Py.writeComment("zxJDBC", "failed to load connector [" + name + "] using class [" + className + "]"); } } }
// in src/com/xhaus/modjy/ModjyJServlet.java
protected void setupEnvironment(PythonInterpreter interp, Properties props, PySystemState systemState) throws PyException { processPythonLib(interp, systemState); checkSitePackages(props); }
// in src/com/xhaus/modjy/ModjyJServlet.java
protected void checkSitePackages(Properties props) throws PyException { String loadSitePackagesParam = props.getProperty(LOAD_SITE_PACKAGES_PARAM); boolean loadSitePackages = true; if (loadSitePackagesParam != null && loadSitePackagesParam.trim().compareTo("0") == 0) loadSitePackages = false; if (loadSitePackages) imp.load("site"); }
(Lib) UnsupportedOperationException 43
              
// in src/org/python/indexer/Outliner.java
public void setChildren(List<Entry> children) { throw new UnsupportedOperationException("Leaf nodes cannot have children."); }
// in src/org/python/indexer/ast/NNode.java
protected void bindNames(Scope s) throws Exception { throw new UnsupportedOperationException("Not a name-binding node type"); }
// in src/org/python/modules/jffi/MemoryOp.java
public static final MemoryOp getMemoryOp(NativeType type) { switch (type) { case VOID: return VOID; case BYTE: return INT8; case UBYTE: return UINT8; case SHORT: return INT16; case USHORT: return UINT16; case INT: return INT32; case UINT: return UINT32; case LONGLONG: return INT64; case ULONGLONG: return UINT64; case LONG: return com.kenai.jffi.Platform.getPlatform().longSize() == 32 ? INT32 : INT64; case ULONG: return com.kenai.jffi.Platform.getPlatform().longSize() == 32 ? UINT32 : UINT64; case FLOAT: return FLOAT; case DOUBLE: return DOUBLE; case POINTER: return POINTER; case STRING: return STRING; case BOOL: return BOOL; default: throw new UnsupportedOperationException("No MemoryOp for " + type); } }
// in src/org/python/core/PyFrozenSet.java
public void clear() { throw new UnsupportedOperationException(); }
// in src/org/python/core/PyFrozenSet.java
public boolean add(Object o) { throw new UnsupportedOperationException(); }
// in src/org/python/core/PyFrozenSet.java
public boolean remove(Object o) { throw new UnsupportedOperationException(); }
// in src/org/python/core/PyFrozenSet.java
public boolean addAll(Collection c) { throw new UnsupportedOperationException(); }
// in src/org/python/core/PyFrozenSet.java
public boolean removeAll(Collection c) { throw new UnsupportedOperationException(); }
// in src/org/python/core/PyFrozenSet.java
public boolean retainAll(Collection c) { throw new UnsupportedOperationException(); }
// in src/org/python/core/PyFrozenSet.java
public void remove() { throw new UnsupportedOperationException(); }
// in src/org/python/core/PyUnicode.java
public void remove() { throw new UnsupportedOperationException("Not supported on PyUnicode objects (immutable)"); }
// in src/org/python/core/PyUnicode.java
public void remove() { throw new UnsupportedOperationException(); }
// in src/org/python/core/PyUnicode.java
public void remove() { throw new UnsupportedOperationException(); }
// in src/org/python/core/PyUnicode.java
public void remove() { throw new UnsupportedOperationException(); }
// in src/org/python/core/PyUnicode.java
public void remove() { throw new UnsupportedOperationException(); }
// in src/org/python/core/PyUnicode.java
public void remove() { throw new UnsupportedOperationException(); }
// in src/org/python/core/PyUnicode.java
public void remove() { throw new UnsupportedOperationException(); }
// in src/org/python/core/PyTuple.java
public void remove() { throw new UnsupportedOperationException(); }
// in src/org/python/core/PyTuple.java
public boolean add(Object o) { throw new UnsupportedOperationException(); }
// in src/org/python/core/PyTuple.java
public boolean remove(Object o) { throw new UnsupportedOperationException(); }
// in src/org/python/core/PyTuple.java
public boolean addAll(Collection coll) { throw new UnsupportedOperationException(); }
// in src/org/python/core/PyTuple.java
public boolean removeAll(Collection coll) { throw new UnsupportedOperationException(); }
// in src/org/python/core/PyTuple.java
public boolean retainAll(Collection coll) { throw new UnsupportedOperationException(); }
// in src/org/python/core/PyTuple.java
public void clear() { throw new UnsupportedOperationException(); }
// in src/org/python/core/PyTuple.java
public Object set(int index, Object element) { throw new UnsupportedOperationException(); }
// in src/org/python/core/PyTuple.java
public void add(int index, Object element) { throw new UnsupportedOperationException(); }
// in src/org/python/core/PyTuple.java
public Object remove(int index) { throw new UnsupportedOperationException(); }
// in src/org/python/core/PyTuple.java
public boolean addAll(int index, Collection c) { throw new UnsupportedOperationException(); }
// in src/org/python/core/PyTuple.java
public void remove() { throw new UnsupportedOperationException(); }
// in src/org/python/core/PyTuple.java
public void set(Object o) { throw new UnsupportedOperationException(); }
// in src/org/python/core/PyTuple.java
public void add(Object o) { throw new UnsupportedOperationException(); }
// in src/org/python/core/PyTuple.java
Override public void pyadd(int index, PyObject element) { throw new UnsupportedOperationException(); }
// in src/org/python/core/PyTuple.java
Override public boolean pyadd(PyObject o) { throw new UnsupportedOperationException(); }
// in src/org/python/core/PyTuple.java
Override public void remove(int start, int stop) { throw new UnsupportedOperationException(); }
// in src/org/python/core/PyDataDescr.java
public void invokeSet(PyObject obj, Object converted) { throw new UnsupportedOperationException("Must be overriden by a subclass"); }
// in src/org/python/core/PyDataDescr.java
public void invokeDelete(PyObject obj) { throw new UnsupportedOperationException("Must be overriden by a subclass"); }
// in src/org/python/core/PyDictionary.java
public Object setValue(Object val) { throw new UnsupportedOperationException("Not supported by this view"); }
// in src/org/python/core/PyTableCode.java
Override protected PyObject interpret(PyFrame f, ThreadState ts) { throw new UnsupportedOperationException("Inlined interpret to improve call performance (may want to reconsider in the future)."); }
// in src/org/python/core/WrappedIterIterator.java
public void remove() { throw new UnsupportedOperationException("Can't remove from a Python iterator"); }
// in src/org/python/core/CodeFlag.java
public void remove() { throw new UnsupportedOperationException(); }
// in src/org/python/core/codecs.java
public static String PyUnicode_EncodeIDNA(PyUnicode input, String errors) { throw new UnsupportedOperationException(); // 1. If the sequence contains any code points outside the ASCII range // (0..7F) then proceed to step 2, otherwise skip to step 3. // // 2. Perform the steps specified in [NAMEPREP] and fail if there is an // error. The AllowUnassigned flag is used in [NAMEPREP]. // this basically enails changing out space, etc. // // 3. If the UseSTD3ASCIIRules flag is set, then perform these checks: // // (a) Verify the absence of non-LDH ASCII code points; that is, the // absence of 0..2C, 2E..2F, 3A..40, 5B..60, and 7B..7F. // // (b) Verify the absence of leading and trailing hyphen-minus; that // is, the absence of U+002D at the beginning and end of the // sequence. // // 4. If the sequence contains any code points outside the ASCII range // (0..7F) then proceed to step 5, otherwise skip to step 8. // // 5. Verify that the sequence does NOT begin with the ACE prefix. // // 6. Encode the sequence using the encoding algorithm in [PUNYCODE] and // fail if there is an error. // // 7. Prepend the ACE prefix. // // 8. Verify that the number of code points is in the range 1 to 63 // inclusive. }
// in src/org/python/core/codecs.java
public static PyUnicode PyUnicode_DecodeIDNA(String input, String errors) { throw new UnsupportedOperationException(); }
// in src/org/python/core/codecs.java
public void remove() { throw new UnsupportedOperationException("Not supported on String objects (immutable)"); }
0 0
(Domain) ParseException 38
              
// in src/org/python/compiler/ScopeInfo.java
public void defineAsGenerator(expr node) { generator = true; if (hasReturnWithValue) { throw new ParseException("'return' with argument " + "inside generator", node); } }
// in src/org/python/compiler/ScopeInfo.java
public void noteReturnValue(Return node) { if (generator) { throw new ParseException("'return' with argument " + "inside generator", node); } hasReturnWithValue = true; }
// in src/org/python/compiler/Future.java
private boolean check(ImportFrom cand) throws Exception { if (!cand.getInternalModule().equals(FutureFeature.MODULE_NAME)) return false; if (cand.getInternalNames().isEmpty()) { throw new ParseException( "future statement does not support import *", cand); } try { for (alias feature : cand.getInternalNames()) { // *known* features FutureFeature.addFeature(feature.getInternalName(), features); } } catch (ParseException pe) { throw new ParseException(pe.getMessage(), cand); } return true; }
// in src/org/python/compiler/Future.java
public static void checkFromFuture(ImportFrom node) throws Exception { if (node.from_future_checked) return; if (node.getInternalModule().equals(FutureFeature.MODULE_NAME)) { throw new ParseException("from __future__ imports must occur " + "at the beginning of the file", node); } node.from_future_checked = true; }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitBreak(Break node) throws Exception { //setline(node); Not needed here... if (breakLabels.empty()) { throw new ParseException("'break' outside loop", node); } doFinallysDownTo(bcfLevel); code.goto_(breakLabels.peek()); return null; }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitContinue(Continue node) throws Exception { //setline(node); Not needed here... if (continueLabels.empty()) { throw new ParseException("'continue' not properly in loop", node); } doFinallysDownTo(bcfLevel); code.goto_(continueLabels.peek()); return Exit; }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitYield(Yield node) throws Exception { setline(node); if (!fast_locals) { throw new ParseException("'yield' outside function", node); } int stackState = saveStack(); if (node.getInternalValue() != null) { visit(node.getInternalValue()); } else { getNone(); } setLastI(++yield_count); saveLocals(); code.areturn(); Label restart = new Label(); yields.addElement(restart); code.label(restart); restoreLocals(); restoreStack(stackState); loadFrame(); code.invokevirtual(p(PyFrame.class), "getGeneratorInput", sig(Object.class)); code.dup(); code.instanceof_(p(PyException.class)); Label done2 = new Label(); code.ifeq(done2); code.checkcast(p(Throwable.class)); code.athrow(); code.label(done2); code.checkcast(p(PyObject.class)); return null; }
// in src/org/python/compiler/CodeCompiler.java
public Object visitReturn(Return node, boolean inEval) throws Exception { setline(node); if (!inEval && !fast_locals) { throw new ParseException("'return' outside function", node); } int tmp = 0; if (node.getInternalValue() != null) { if (my_scope.generator) { throw new ParseException("'return' with argument " + "inside generator", node); } visit(node.getInternalValue()); tmp = code.getReturnLocal(); code.astore(tmp); } doFinallysDownTo(0); setLastI(-1); if (node.getInternalValue() != null) { code.aload(tmp); } else { getNone(); } code.areturn(); return Exit; }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitImportFrom(ImportFrom node) throws Exception { Future.checkFromFuture(node); // future stmt support setline(node); code.ldc(node.getInternalModule()); java.util.List<alias> aliases = node.getInternalNames(); if (aliases == null || aliases.size() == 0) { throw new ParseException("Internel parser error", node); } else if (aliases.size() == 1 && aliases.get(0).getInternalName().equals("*")) { if (node.getInternalLevel() > 0) { throw new ParseException("'import *' not allowed with 'from .'", node); } if (my_scope.func_level > 0) { module.error("import * only allowed at module level", false, node); if (my_scope.contains_ns_free_vars) { module.error("import * is not allowed in function '" + my_scope.scope_name + "' because it contains a nested function with free variables", true, node); } } if (my_scope.func_level > 1) { module.error("import * is not allowed in function '" + my_scope.scope_name + "' because it is a nested function", true, node); } loadFrame(); defaultImportLevel(); code.invokestatic(p(imp.class), "importAll", sig(Void.TYPE, String.class, PyFrame.class, Integer.TYPE)); } else { java.util.List<String> fromNames = new ArrayList<String>();//[names.size()]; java.util.List<String> asnames = new ArrayList<String>();//[names.size()]; for (int i = 0; i < aliases.size(); i++) { fromNames.add(aliases.get(i).getInternalName()); asnames.add(aliases.get(i).getInternalAsname()); if (asnames.get(i) == null) { asnames.set(i, fromNames.get(i)); } } int strArray = makeStrings(code, fromNames); code.aload(strArray); code.freeLocal(strArray); loadFrame(); if (node.getInternalLevel() == 0) { defaultImportLevel(); } else { code.iconst(node.getInternalLevel()); } code.invokestatic(p(imp.class), "importFrom", sig(PyObject[].class, String.class, String[].class, PyFrame.class, Integer.TYPE)); int tmp = storeTop(); for (int i = 0; i < aliases.size(); i++) { code.aload(tmp); code.iconst(i); code.aaload(); set(new Name(aliases.get(i), asnames.get(i), expr_contextType.Store)); } code.freeLocal(tmp); } return null; }
// in src/org/python/compiler/CodeCompiler.java
public void exceptionTest(int exc, Label end_of_exceptions, TryExcept node, int index) throws Exception { for (int i = 0; i < node.getInternalHandlers().size(); i++) { ExceptHandler handler = (ExceptHandler) node.getInternalHandlers().get(i); //setline(name); Label end_of_self = new Label(); if (handler.getInternalType() != null) { code.aload(exc); //get specific exception visit(handler.getInternalType()); code.invokevirtual(p(PyException.class), "match", sig(Boolean.TYPE, PyObject.class)); code.ifeq(end_of_self); } else { if (i != node.getInternalHandlers().size() - 1) { throw new ParseException( "default 'except:' must be last", handler); } } if (handler.getInternalName() != null) { code.aload(exc); code.getfield(p(PyException.class), "value", ci(PyObject.class)); set(handler.getInternalName()); } //do exception body suite(handler.getInternalBody()); code.goto_(end_of_exceptions); code.label(end_of_self); } code.aload(exc); code.athrow(); }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitName(Name node) throws Exception { String name; if (fast_locals) { name = node.getInternalId(); } else { name = getName(node.getInternalId()); } SymInfo syminf = tbl.get(name); expr_contextType ctx = node.getInternalCtx(); if (ctx == expr_contextType.AugStore) { ctx = augmode; } switch (ctx) { case Load: loadFrame(); if (syminf != null) { int flags = syminf.flags; if ((flags & ScopeInfo.GLOBAL) != 0 || optimizeGlobals && (flags & (ScopeInfo.BOUND | ScopeInfo.CELL | ScopeInfo.FREE)) == 0) { emitGetGlobal(name); return null; } if (fast_locals) { if ((flags & ScopeInfo.CELL) != 0) { code.iconst(syminf.env_index); code.invokevirtual(p(PyFrame.class), "getderef", sig(PyObject.class, Integer.TYPE)); return null; } if ((flags & ScopeInfo.BOUND) != 0) { code.iconst(syminf.locals_index); code.invokevirtual(p(PyFrame.class), "getlocal", sig(PyObject.class, Integer.TYPE)); return null; } } if ((flags & ScopeInfo.FREE) != 0 && (flags & ScopeInfo.BOUND) == 0) { code.iconst(syminf.env_index); code.invokevirtual(p(PyFrame.class), "getderef", sig(PyObject.class, Integer.TYPE)); return null; } } code.ldc(name); code.invokevirtual(p(PyFrame.class), "getname", sig(PyObject.class, String.class)); return null; case Param: case Store: loadFrame(); if (syminf != null && (syminf.flags & ScopeInfo.GLOBAL) != 0) { code.ldc(name); code.aload(temporary); code.invokevirtual(p(PyFrame.class), "setglobal", sig(Void.TYPE, String.class, PyObject.class)); } else { if (!fast_locals) { code.ldc(name); code.aload(temporary); code.invokevirtual(p(PyFrame.class), "setlocal", sig(Void.TYPE, String.class, PyObject.class)); } else { if (syminf == null) { throw new ParseException("internal compiler error", node); } if ((syminf.flags & ScopeInfo.CELL) != 0) { code.iconst(syminf.env_index); code.aload(temporary); code.invokevirtual(p(PyFrame.class), "setderef", sig(Void.TYPE, Integer.TYPE, PyObject.class)); } else { code.iconst(syminf.locals_index); code.aload(temporary); code.invokevirtual(p(PyFrame.class), "setlocal", sig(Void.TYPE, Integer.TYPE, PyObject.class)); } } } return null; case Del: { loadFrame(); if (syminf != null && (syminf.flags & ScopeInfo.GLOBAL) != 0) { code.ldc(name); code.invokevirtual(p(PyFrame.class), "delglobal", sig(Void.TYPE, String.class)); } else { if (!fast_locals) { code.ldc(name); code.invokevirtual(p(PyFrame.class), "dellocal", sig(Void.TYPE, String.class)); } else { if (syminf == null) { throw new ParseException("internal compiler error", node); } if ((syminf.flags & ScopeInfo.CELL) != 0) { module.error("can not delete variable '" + name + "' referenced in nested scope", true, node); } code.iconst(syminf.locals_index); code.invokevirtual(p(PyFrame.class), "dellocal", sig(Void.TYPE, Integer.TYPE)); } } return null; } } return null; }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitWith(With node) throws Exception { if (!module.getFutures().withStatementSupported()) { throw new ParseException("'with' will become a reserved keyword in Python 2.6", node); } final Label label_body_start = new Label(); final Label label_body_end = new Label(); final Label label_catch = new Label(); final Label label_end = new Label(); final Method contextGuard_getManager = Method.getMethod( "org.python.core.ContextManager getManager (org.python.core.PyObject)"); final Method __enter__ = Method.getMethod( "org.python.core.PyObject __enter__ (org.python.core.ThreadState)"); final Method __exit__ = Method.getMethod( "boolean __exit__ (org.python.core.ThreadState,org.python.core.PyException)"); // mgr = (EXPR) visit(node.getInternalContext_expr()); // wrap the manager with the ContextGuard (or get it directly if it // supports the ContextManager interface) code.invokestatic(Type.getType(ContextGuard.class).getInternalName(), contextGuard_getManager.getName(), contextGuard_getManager.getDescriptor()); code.dup(); final int mgr_tmp = code.getLocal(Type.getType(ContextManager.class).getInternalName()); code.astore(mgr_tmp); // value = mgr.__enter__() loadThreadState(); code.invokeinterface(Type.getType(ContextManager.class).getInternalName(), __enter__.getName(), __enter__.getDescriptor()); int value_tmp = code.getLocal(p(PyObject.class)); code.astore(value_tmp); // exc = True # not necessary, since we don't exec finally if exception // FINALLY (preparation) // ordinarily with a finally, we need to duplicate the code. that's not the case // here // # The normal and non-local-goto cases are handled here // if exc: # implicit // exit(None, None, None) ExceptionHandler normalExit = new ExceptionHandler() { @Override public boolean isFinallyHandler() { return true; } @Override public void finalBody(CodeCompiler compiler) throws Exception { compiler.code.aload(mgr_tmp); loadThreadState(); compiler.code.aconst_null(); compiler.code.invokeinterface(Type.getType(ContextManager.class).getInternalName(), __exit__.getName(), __exit__.getDescriptor()); compiler.code.pop(); } }; exceptionHandlers.push(normalExit); // try-catch block here ExceptionHandler handler = new ExceptionHandler(); exceptionHandlers.push(handler); handler.exceptionStarts.addElement(label_body_start); // VAR = value # Only if "as VAR" is present code.label(label_body_start); if (node.getInternalOptional_vars() != null) { set(node.getInternalOptional_vars(), value_tmp); } code.freeLocal(value_tmp); // BLOCK + FINALLY if non-local-goto Object blockResult = suite(node.getInternalBody()); normalExit.bodyDone = true; exceptionHandlers.pop(); exceptionHandlers.pop(); code.label(label_body_end); handler.exceptionEnds.addElement(label_body_end); // FINALLY if *not* non-local-goto if (blockResult == NoExit) { // BLOCK would have generated FINALLY for us if it exited (due to a break, // continue or return) inlineFinally(normalExit); code.goto_(label_end); } // CATCH code.label(label_catch); loadFrame(); code.invokestatic(p(Py.class), "setException", sig(PyException.class, Throwable.class, PyFrame.class)); code.aload(mgr_tmp); code.swap(); loadThreadState(); code.swap(); code.invokeinterface(Type.getType(ContextManager.class).getInternalName(), __exit__.getName(), __exit__.getDescriptor()); // # The exceptional case is handled here // exc = False # implicit // if not exit(*sys.exc_info()): code.ifne(label_end); // raise // # The exception is swallowed if exit() returns true code.invokestatic(p(Py.class), "makeException", sig(PyException.class)); code.checkcast(p(Throwable.class)); code.athrow(); code.label(label_end); code.freeLocal(mgr_tmp); handler.addExceptionHandlers(label_catch); return null; }
// in src/org/python/compiler/Module.java
public void error(String msg, boolean err, PythonTree node) throws Exception { if (!err) { try { Py.warning(Py.SyntaxWarning, msg, (sfilename != null) ? sfilename : "?", node.getLine(), null, Py.None); return; } catch (PyException e) { if (!e.match(Py.SyntaxWarning)) { throw e; } } } throw new ParseException(msg, node); }
// in src/org/python/compiler/ArgListCompiler.java
public void visitArgs(arguments args) throws Exception { for (int i = 0; i < args.getInternalArgs().size(); i++) { String name = (String) visit(args.getInternalArgs().get(i)); names.add(name); if (args.getInternalArgs().get(i) instanceof Tuple) { List<expr> targets = new ArrayList<expr>(); targets.add(args.getInternalArgs().get(i)); Assign ass = new Assign(args.getInternalArgs().get(i), targets, new Name(args.getInternalArgs().get(i), name, expr_contextType.Load)); init_code.add(ass); } } if (args.getInternalVararg() != null) { arglist = true; names.add(args.getInternalVararg()); } if (args.getInternalKwarg() != null) { keywordlist = true; names.add(args.getInternalKwarg()); } defaults = args.getInternalDefaults(); for (int i = 0; i < defaults.size(); i++) { if (defaults.get(i) == null) throw new ParseException( "non-default argument follows default argument", args.getInternalArgs().get(args.getInternalArgs().size() - defaults.size() + i)); } }
// in src/org/python/compiler/ArgListCompiler.java
Override public Object visitName(Name node) throws Exception { //FIXME: do we need Store and Param, or just Param? if (node.getInternalCtx() != expr_contextType.Store && node.getInternalCtx() != expr_contextType.Param) { return null; } if (fpnames.contains(node.getInternalId())) { throw new ParseException("duplicate argument name found: " + node.getInternalId(), node); } fpnames.add(node.getInternalId()); return node.getInternalId(); }
// in src/org/python/antlr/FailFastHandler.java
public void reportError(BaseRecognizer br, RecognitionException re) { throw new ParseException(message(br,re), re); }
// in src/org/python/antlr/FailFastHandler.java
public void recover(Lexer lex, RecognitionException re) { throw new ParseException(message(lex,re), re); }
// in src/org/python/antlr/FailFastHandler.java
public void recover(BaseRecognizer br, IntStream input, RecognitionException re) { throw new ParseException(message(br,re), re); }
// in src/org/python/antlr/FailFastHandler.java
public expr errorExpr(PythonTree t) { throw new ParseException("Bad Expr Node", t); }
// in src/org/python/antlr/FailFastHandler.java
public mod errorMod(PythonTree t) { throw new ParseException("Bad Mod Node", t); }
// in src/org/python/antlr/FailFastHandler.java
public slice errorSlice(PythonTree t) { throw new ParseException("Bad Slice Node", t); }
// in src/org/python/antlr/FailFastHandler.java
public stmt errorStmt(PythonTree t) { throw new ParseException("Bad Stmt Node", t); }
// in src/org/python/antlr/FailFastHandler.java
public void error(String message, PythonTree t) { throw new ParseException(message, t); }
// in src/org/python/core/FutureFeature.java
Override public Pragma getStarPragma() { throw new ParseException("future feature * is not defined"); }
// in src/org/python/core/FutureFeature.java
private static FutureFeature getFeature(String featureName) { try { return valueOf(featureName); } catch (IllegalArgumentException ex) { throw new ParseException("future feature " + featureName + " is not defined"); } }
// in src/org/python/core/ParserFacade.java
private static ExpectedEncodingBufferedReader prepBufReader(Reader reader, CompilerFlags cflags, String filename) throws IOException { cflags.source_is_utf8 = true; cflags.encoding = "utf-8"; BufferedReader bufferedReader = new BufferedReader(reader); bufferedReader.mark(MARK_LIMIT); if (findEncoding(bufferedReader) != null) throw new ParseException("encoding declaration in Unicode string"); bufferedReader.reset(); return new ExpectedEncodingBufferedReader(bufferedReader, null); }
// in src/org/python/core/ParserFacade.java
private static ExpectedEncodingBufferedReader prepBufReader(InputStream input, CompilerFlags cflags, String filename, boolean fromString, boolean universalNewlines) throws IOException { input = new BufferedInputStream(input); boolean bom = adjustForBOM(input); String encoding = readEncoding(input); if (encoding == null) { if (bom) { encoding = "utf-8"; } else if (cflags != null && cflags.encoding != null) { encoding = cflags.encoding; } } if (cflags.source_is_utf8) { if (encoding != null) { throw new ParseException("encoding declaration in Unicode string"); } encoding = "utf-8"; } cflags.encoding = encoding; if (universalNewlines) { // Enable universal newlines mode on the input StreamIO rawIO = new StreamIO(input, true); org.python.core.io.BufferedReader bufferedIO = new org.python.core.io.BufferedReader(rawIO, 0); UniversalIOWrapper textIO = new UniversalIOWrapper(bufferedIO); input = new TextIOInputStream(textIO); } Charset cs; try { // Use ascii for the raw bytes when no encoding was specified if (encoding == null) { if (fromString) { cs = Charset.forName("ISO-8859-1"); } else { cs = Charset.forName("ascii"); } } else { cs = Charset.forName(encoding); } } catch (UnsupportedCharsetException exc) { throw new PySyntaxError("Unknown encoding: " + encoding, 1, 0, "", filename); } CharsetDecoder dec = cs.newDecoder(); dec.onMalformedInput(CodingErrorAction.REPORT); dec.onUnmappableCharacter(CodingErrorAction.REPORT); return new ExpectedEncodingBufferedReader(new InputStreamReader(input, dec), encoding); }
// in src/org/python/core/ParserFacade.java
private static boolean adjustForBOM(InputStream stream) throws IOException { stream.mark(3); int ch = stream.read(); if (ch == 0xEF) { if (stream.read() != 0xBB) { throw new ParseException("Incomplete BOM at beginning of file"); } if (stream.read() != 0xBF) { throw new ParseException("Incomplete BOM at beginning of file"); } return true; } stream.reset(); return false; }
// in src/org/python/core/Pragma.java
Override public Pragma getPragma(String name) { throw new ParseException(message); }
// in src/org/python/core/Pragma.java
Override public Pragma getStarPragma() { throw new ParseException(message); }
// in src/org/python/core/Pragma.java
public void addTo(PragmaReceiver receiver) { throw new ParseException(message); }
2
              
// in src/org/python/compiler/Future.java
catch (ParseException pe) { throw new ParseException(pe.getMessage(), cand); }
// in src/org/python/core/FutureFeature.java
catch (IllegalArgumentException ex) { throw new ParseException("future feature " + featureName + " is not defined"); }
0
(Lib) RuntimeException 18
              
// in src/org/python/expose/generate/TypeExposer.java
public TypeBuilder makeBuilder() { BytecodeLoader.Loader l = new BytecodeLoader.Loader(); if(ne != null) { ne.load(l); } for(DescriptorExposer de : descriptors) { de.load(l); } for(MethodExposer me : methods) { me.load(l); } Class descriptor = load(l); try { return (TypeBuilder)descriptor.newInstance(); } catch(Exception e) { // If we're unable to create the generated class, the process is // definitely ill, but that shouldn't be the case most of the time // so make this a runtime exception throw new RuntimeException("Unable to create generated builder", e); } }
// in src/org/python/Version.java
private static void loadProperties() { boolean loaded = false; final String versionProperties = "/org/python/version.properties"; InputStream in = Version.class.getResourceAsStream(versionProperties); if (in != null) { try { Properties properties = new Properties(); properties.load(in); loaded = true; PY_VERSION = properties.getProperty("jython.version"); PY_MAJOR_VERSION = Integer.valueOf(properties.getProperty("jython.major_version")); PY_MINOR_VERSION = Integer.valueOf(properties.getProperty("jython.minor_version")); PY_MICRO_VERSION = Integer.valueOf(properties.getProperty("jython.micro_version")); PY_RELEASE_LEVEL = Integer.valueOf(properties.getProperty("jython.release_level")); PY_RELEASE_SERIAL = Integer.valueOf(properties.getProperty("jython.release_serial")); DATE = properties.getProperty("jython.build.date"); TIME = properties.getProperty("jython.build.time"); SVN_REVISION = properties.getProperty("jython.build.svn_revision"); HG_BRANCH = properties.getProperty("jython.build.hg_branch"); HG_TAG = properties.getProperty("jython.build.hg_tag"); HG_VERSION = properties.getProperty("jython.build.hg_version"); } catch (IOException ioe) { System.err.println("There was a problem loading ".concat(versionProperties) .concat(":")); ioe.printStackTrace(); } finally { try { in.close(); } catch (IOException ioe) { // ok } } } if (!loaded) { // fail with a meaningful exception (cannot use Py exceptions here) throw new RuntimeException("unable to load ".concat(versionProperties)); } }
// in src/org/python/antlr/PythonTree.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { throw new RuntimeException("Unexpected node: " + this); }
// in src/org/python/antlr/PythonTree.java
public void traverse(VisitorIF<?> visitor) throws Exception { throw new RuntimeException("Cannot traverse node: " + this); }
// in src/org/python/antlr/PythonTree.java
public void addChild(PythonTree t) { if ( t==null ) { return; // do nothing upon addChild(null) } PythonTree childTree = t; if ( childTree.isNil() ) { // t is an empty node possibly with children if ( this.children!=null && this.children == childTree.children ) { throw new RuntimeException("attempt to add child list to itself"); } // just add all of childTree's children to this if ( childTree.children!=null ) { if ( this.children!=null ) { // must copy, this has children already int n = childTree.children.size(); for (int i = 0; i < n; i++) { PythonTree c = childTree.children.get(i); this.children.add(c); // handle double-link stuff for each child of nil root c.setParent(this); c.setChildIndex(children.size()-1); } } else { // no children for this but t has children; just set pointer // call general freshener routine this.children = childTree.children; this.freshenParentAndChildIndexes(); } } } else { // child is not nil (don't care about children) if ( children==null ) { children = createChildrenList(); // create children list on demand } children.add(t); childTree.setParent(this); childTree.setChildIndex(children.size()-1); } }
// in src/org/python/antlr/PythonTreeAdaptor.java
Override public Object becomeRoot(Object newRoot, Object oldRoot) { //System.out.println("becomeroot new "+newRoot.toString()+" old "+oldRoot); PythonTree newRootTree = (PythonTree)newRoot; PythonTree oldRootTree = (PythonTree)oldRoot; if ( oldRoot==null ) { return newRoot; } // handle ^(nil real-node) if ( newRootTree.isNil() ) { int nc = newRootTree.getChildCount(); if ( nc==1 ) newRootTree = newRootTree.getChild(0); else if ( nc >1 ) { // TODO: make tree run time exceptions hierarchy throw new RuntimeException("more than one node as root (TODO: make exception hierarchy)"); } } // add oldRoot to newRoot; addChild takes care of case where oldRoot // is a flat list (i.e., nil-rooted tree). All children of oldRoot // are added to newRoot. newRootTree.addChild(oldRootTree); return newRootTree; }
// in src/org/python/modules/jffi/NativeType.java
static final com.kenai.jffi.Type jffiType(NativeType type) { switch (type) { case VOID: return com.kenai.jffi.Type.VOID; case BYTE: return com.kenai.jffi.Type.SINT8; case UBYTE: return com.kenai.jffi.Type.UINT8; case SHORT: return com.kenai.jffi.Type.SINT16; case USHORT: return com.kenai.jffi.Type.UINT16; case INT: case BOOL: return com.kenai.jffi.Type.SINT32; case UINT: return com.kenai.jffi.Type.UINT32; case LONGLONG: return com.kenai.jffi.Type.SINT64; case ULONGLONG: return com.kenai.jffi.Type.UINT64; case LONG: return com.kenai.jffi.Type.SLONG; case ULONG: return com.kenai.jffi.Type.ULONG; case FLOAT: return com.kenai.jffi.Type.FLOAT; case DOUBLE: return com.kenai.jffi.Type.DOUBLE; case POINTER: case STRING: return com.kenai.jffi.Type.POINTER; default: throw new RuntimeException("Unknown type " + type); } }
// in src/org/python/core/SyspathJavaLoader.java
Override protected URL findResource(String res) { PySystemState sys = Py.getSystemState(); if (res.charAt(0) == SLASH_CHAR) { res = res.substring(1); } String entryRes = res; if (File.separatorChar != SLASH_CHAR) { res = res.replace(SLASH_CHAR, File.separatorChar); entryRes = entryRes.replace(File.separatorChar, SLASH_CHAR); } PyList path = sys.path; for (int i = 0; i < path.__len__(); i++) { PyObject entry = replacePathItem(sys, i, path); if (entry instanceof SyspathArchive) { SyspathArchive archive = (SyspathArchive) entry; ZipEntry ze = archive.getEntry(entryRes); if (ze != null) { try { return new URL("jar:file:" + entry.__str__().toString() + "!/" + entryRes); } catch (MalformedURLException e) { throw new RuntimeException(e); } } continue; } if (!(entry instanceof PyUnicode)) { entry = entry.__str__(); } String dir = sys.getPath(entry.toString()); try { File resource = new File(dir, res); if (!resource.exists()) { continue; } return resource.toURI().toURL(); } catch (MalformedURLException e) { throw new RuntimeException(e); } } return null; }
// in src/org/python/core/PySystemState.java
private static void initStaticFields() { Py.None = new PyNone(); Py.NotImplemented = new PyNotImplemented(); Py.NoKeywords = new String[0]; Py.EmptyObjects = new PyObject[0]; Py.EmptyTuple = new PyTuple(Py.EmptyObjects); Py.EmptyFrozenSet = new PyFrozenSet(); Py.NoConversion = new PySingleton("Error"); Py.Ellipsis = new PyEllipsis(); Py.Zero = new PyInteger(0); Py.One = new PyInteger(1); Py.False = new PyBoolean(false); Py.True = new PyBoolean(true); Py.EmptyString = new PyString(""); Py.Newline = new PyString("\n"); Py.Space = new PyString(" "); // Setup standard wrappers for stdout and stderr... Py.stderr = new StderrWrapper(); Py.stdout = new StdoutWrapper(); String s; if(Version.PY_RELEASE_LEVEL == 0x0A) s = "alpha"; else if(Version.PY_RELEASE_LEVEL == 0x0B) s = "beta"; else if(Version.PY_RELEASE_LEVEL == 0x0C) s = "candidate"; else if(Version.PY_RELEASE_LEVEL == 0x0F) s = "final"; else if(Version.PY_RELEASE_LEVEL == 0xAA) s = "snapshot"; else throw new RuntimeException("Illegal value for PY_RELEASE_LEVEL: " + Version.PY_RELEASE_LEVEL); version_info = new PyTuple(Py.newInteger(Version.PY_MAJOR_VERSION), Py.newInteger(Version.PY_MINOR_VERSION), Py.newInteger(Version.PY_MICRO_VERSION), Py.newString(s), Py.newInteger(Version.PY_RELEASE_SERIAL)); subversion = new PyTuple(Py.newString("Jython"), Py.newString(Version.BRANCH), Py.newString(Version.SVN_REVISION)); _mercurial = new PyTuple(Py.newString("Jython"), Py.newString(Version.getHGIdentifier()), Py.newString(Version.getHGVersion())); }
// in src/org/python/core/PyType.java
private static TypeBuilder getBuilder(Class<?> c) { if (classToBuilder == null) { // PyType itself has yet to be initialized. This should be a bootstrap type, so it'll // go through the builder process in a second return null; } if (c.isPrimitive() || !PyObject.class.isAssignableFrom(c)) { // If this isn't a PyObject, don't bother forcing it to be initialized to load its // builder return null; } // This is a PyObject, call forName to force static initialization on the class so if it has // a builder, it'll be filled in SecurityException exc = null; try { Class.forName(c.getName(), true, c.getClassLoader()); } catch (ClassNotFoundException e) { // Well, this is certainly surprising. throw new RuntimeException("Got ClassNotFound calling Class.forName on an already " + " found class.", e); } catch (ExceptionInInitializerError e) { throw Py.JavaError(e); } catch (SecurityException e) { exc = e; } TypeBuilder builder = classToBuilder.get(c); if (builder == null && exc != null) { Py.writeComment("type", "Unable to initialize " + c.getName() + ", a PyObject subclass, due to a " + "security exception, and no type builder could be found for it. If it's an " + "exposed type, it may not work properly. Security exception: " + exc.getMessage()); } return builder; }
// in src/org/python/core/PyBuiltinMethodSet.java
Override public PyBuiltinCallable bind(PyObject bindTo) { if (__self__ != Py.None) { return this; } PyBuiltinMethodSet bindable; try { bindable = (PyBuiltinMethodSet)clone(); } catch (CloneNotSupportedException e) { throw new RuntimeException("Didn't expect PyBuiltinMethodSet to throw " + "CloneNotSupported since it implements Cloneable", e); } bindable.__self__ = bindTo; return bindable; }
// in src/org/python/core/PyBuiltinMethod.java
Override public PyBuiltinCallable bind(PyObject bindTo) { if(self == null) { PyBuiltinMethod bindable; try { bindable = (PyBuiltinMethod)clone(); } catch(CloneNotSupportedException e) { throw new RuntimeException("Didn't expect PyBuiltinMethodto throw " + "CloneNotSupported since it implements Cloneable", e); } bindable.self = bindTo; return bindable; } return this; }
// in src/org/python/util/CodegenUtils.java
public static String ci(Class n) { if (n.isArray()) { n = n.getComponentType(); if (n.isPrimitive()) { if (n == Byte.TYPE) { return "[B"; } else if (n == Boolean.TYPE) { return "[Z"; } else if (n == Short.TYPE) { return "[S"; } else if (n == Character.TYPE) { return "[C"; } else if (n == Integer.TYPE) { return "[I"; } else if (n == Float.TYPE) { return "[F"; } else if (n == Double.TYPE) { return "[D"; } else if (n == Long.TYPE) { return "[J"; } else { throw new RuntimeException("Unrecognized type in compiler: " + n.getName()); } } else { return "[" + ci(n); } } else { if (n.isPrimitive()) { if (n == Byte.TYPE) { return "B"; } else if (n == Boolean.TYPE) { return "Z"; } else if (n == Short.TYPE) { return "S"; } else if (n == Character.TYPE) { return "C"; } else if (n == Integer.TYPE) { return "I"; } else if (n == Float.TYPE) { return "F"; } else if (n == Double.TYPE) { return "D"; } else if (n == Long.TYPE) { return "J"; } else if (n == Void.TYPE) { return "V"; } else { throw new RuntimeException("Unrecognized type in compiler: " + n.getName()); } } else { return "L" + p(n) + ";"; } } }
9
              
// in src/com/ziclix/python/sql/zxJDBC.java
catch (MissingResourceException e) { throw new RuntimeException("missing zxjdbc resource bundle"); }
// in src/com/ziclix/python/sql/JDBC30DataHandler.java
catch (ClassNotFoundException e) { throw new RuntimeException("JDBC3.0 required to use this DataHandler"); }
// in src/org/python/expose/generate/TypeExposer.java
catch(Exception e) { // If we're unable to create the generated class, the process is // definitely ill, but that shouldn't be the case most of the time // so make this a runtime exception throw new RuntimeException("Unable to create generated builder", e); }
// in src/org/python/core/SyspathJavaLoader.java
catch (MalformedURLException e) { throw new RuntimeException(e); }
// in src/org/python/core/SyspathJavaLoader.java
catch (MalformedURLException e) { throw new RuntimeException(e); }
// in src/org/python/core/PyType.java
catch (ClassNotFoundException e) { // Well, this is certainly surprising. throw new RuntimeException("Got ClassNotFound calling Class.forName on an already " + " found class.", e); }
// in src/org/python/core/PyBuiltinMethodSet.java
catch (CloneNotSupportedException e) { throw new RuntimeException("Didn't expect PyBuiltinMethodSet to throw " + "CloneNotSupported since it implements Cloneable", e); }
// in src/org/python/core/PyBuiltinMethod.java
catch(CloneNotSupportedException e) { throw new RuntimeException("Didn't expect PyBuiltinMethodto throw " + "CloneNotSupported since it implements Cloneable", e); }
// in src/org/python/util/JLineConsole.java
catch (IOException e) { throw new RuntimeException(e); }
0
(Lib) BuildException 17
              
// in src/org/python/expose/generate/ExposeTask.java
private void expose(Set<File> toExpose) { for (File f : toExpose) { ExposedTypeProcessor etp; try { etp = new ExposedTypeProcessor(new FileInputStream(f)); } catch (IOException e) { throw new BuildException("Unable to read '" + f + "' to expose it", e); } catch (InvalidExposingException iee) { throw new BuildException(iee.getMessage()); } for (MethodExposer exposer : etp.getMethodExposers()) { generate(exposer); } for (DescriptorExposer exposer : etp.getDescriptorExposers()) { generate(exposer); } if (etp.getNewExposer() != null) { generate(etp.getNewExposer()); } generate(etp.getTypeExposer()); write(etp.getExposedClassName(), etp.getBytecode()); } }
// in src/org/python/expose/generate/ExposeTask.java
private void write(String destClass, byte[] newClassfile) { File dest = new File(destDir, destClass.replace('.', '/') + ".class"); dest.getParentFile().mkdirs();// TODO - check for success FileOutputStream out = null; try { out = new FileOutputStream(dest); out.write(newClassfile); } catch (IOException e) { throw new BuildException("Unable to write to '" + dest + "'", e); } finally { if (out != null) { try { out.close(); } catch (IOException e) { // Le sigh... } } } }
// in src/org/python/util/JycompileAntTask.java
protected void compile(File src, File compiled, String moduleName) { byte[] bytes; try { bytes = imp.compileSource(moduleName, src); } catch (PyException pye) { pye.printStackTrace(); throw new BuildException("Compile failed; see the compiler error output for details."); } File dir = compiled.getParentFile(); if (!dir.exists() && !compiled.getParentFile().mkdirs()) { throw new BuildException("Unable to make directory for compiled file: " + compiled); } imp.cacheCompiledSource(src.getAbsolutePath(), compiled.getAbsolutePath(), bytes); }
// in src/org/python/util/TemplateAntTask.java
public void execute() { if(null == srcDir) { throw new BuildException("no srcdir specified"); } else if(!srcDir.exists()) { throw new BuildException("srcdir '" + srcDir + "' doesn't exist"); } File gexposeScript = new File(srcDir.getAbsolutePath() + File.separator + "gexpose.py"); File gderiveScript = new File(srcDir.getAbsolutePath() + File.separator + "gderived.py"); if(!gexposeScript.exists()) { throw new BuildException("no gexpose.py script found at: " + gexposeScript); } if(!gderiveScript.exists()) { throw new BuildException("no gderive.py script found at: " + gderiveScript); } runPythonScript(gexposeScript.getAbsolutePath()); runPythonScript(gderiveScript.getAbsolutePath()); }
// in src/org/python/util/TemplateAntTask.java
private void runPythonScript(String script) throws BuildException { if(null == python) { python = "python"; } Execute e = new Execute(); e.setWorkingDirectory(srcDir); String[] command; if(lazy) { command = new String[] {python, script, "--lazy"}; } else { command = new String[] {python, script}; } e.setCommandline(command); if(verbose) { String out = ""; for(int k = 0; k < e.getCommandline().length; k++) { out += (e.getCommandline()[k] + " "); } log("executing: " + out); } try { e.execute(); } catch(IOException e2) { throw new BuildException(e2.toString(), e2); } }
// in src/org/python/util/GlobMatchingTask.java
Override public void execute() throws BuildException { checkParameters(); toExpose.clear(); for (String srcEntry : src.list()) { File srcDir = getProject().resolveFile(srcEntry); if (!srcDir.exists()) { throw new BuildException("srcdir '" + srcDir.getPath() + "' does not exist!", getLocation()); } String[] files = getDirectoryScanner(srcDir).getIncludedFiles(); scanDir(srcDir, destDir != null ? destDir : srcDir, files); } process(toExpose); }
// in src/org/python/util/GlobMatchingTask.java
protected void checkParameters() throws BuildException { if (src == null || src.size() == 0) { throw new BuildException("srcdir attribute must be set!", getLocation()); } if (destDir != null && !destDir.isDirectory()) { throw new BuildException("destination directory '" + destDir + "' does not exist " + "or is not a directory", getLocation()); } }
// in src/org/python/util/JythoncAntTask.java
public void setWorkdir(File aValue) { if( aValue.exists() ) { if( ! aValue.isDirectory() ) { throw new BuildException( "Workdir ("+ aValue + ") is not a directory" ); } } else { aValue.mkdirs(); } workdir = aValue; }
// in src/org/python/util/JythoncAntTask.java
public File getPythonHome() { if(jythonHome == null ) { String aPythonHome = getProject().getProperty("python.home"); if(aPythonHome == null ) { throw new BuildException("No python.home or home specified"); } jythonHome = new File(aPythonHome); } return jythonHome; }
// in src/org/python/util/JythoncAntTask.java
public void execute() { try { Java javaTask = null; javaTask = (Java)getProject().createTask("java"); javaTask.setTaskName("jythonc"); javaTask.setClassname( JYTHON_CLASS ); javaTask.createJvmarg().setValue( "-Dpython.home=" + getPythonHome() ); // classpath File aJythonJarFile = new File(getPythonHome(), PySystemState.JYTHON_JAR ); createClasspath().setLocation(aJythonJarFile); javaTask.setClasspath(classpath); // jythonc file javaTask.createArg().setFile( getJythoncPY() ); if( packageName != null ) { javaTask.createArg().setValue("--package"); javaTask.createArg().setValue(packageName); } if( jarFile != null ) { javaTask.createArg().setValue( "--jar" ); javaTask.createArg().setFile( jarFile ); } if(deep) { javaTask.createArg().setValue( "--deep" ); } if(core) { javaTask.createArg().setValue( "--core" ); } if(all) { javaTask.createArg().setValue( "--all" ); } if( jarFileBean != null ) { javaTask.createArg().setValue( "--bean" ); javaTask.createArg().setFile( jarFileBean ); } if( addpackages != null ) { javaTask.createArg().setValue( "--addpackages " ); javaTask.createArg().setValue( addpackages ); } if( workdir != null ) { javaTask.createArg().setValue( "--workdir " ); javaTask.createArg().setFile( workdir ); } if( skipModule != null ) { javaTask.createArg().setValue("--skip"); javaTask.createArg().setValue(skipModule); } // --compiler if( compiler == null ) { // try to use the compiler specified by build.compiler. Right now we are // just going to allow Jikes String buildCompiler = getProject().getProperty("build.compiler"); if (buildCompiler != null && buildCompiler.equals("jikes")) { javaTask.createArg().setValue("--compiler"); javaTask.createArg().setValue("jikes"); } } else { javaTask.createArg().setValue("--compiler"); javaTask.createArg().setValue(compiler); } String aCompilerOpts = getCompilerOptions(); if( aCompilerOpts != null ) { javaTask.createArg().setValue("--compileropts"); javaTask.createArg().setValue(aCompilerOpts); } if( falsenames != null ) { javaTask.createArg().setValue("--falsenames"); javaTask.createArg().setValue(falsenames); } if( extraArgs != null ) { javaTask.createArg().setLine(extraArgs); } //get dependencies list. if( srcDir == null ) { srcDir = getProject().resolveFile("."); } DirectoryScanner scanner = super.getDirectoryScanner(srcDir); String[] dependencies = scanner.getIncludedFiles(); log("compiling " + dependencies.length + " file" + ((dependencies.length == 1)?"":"s")); String baseDir = scanner.getBasedir().toString() + File.separator; //add to the command for (int i = 0; i < dependencies.length; i++) { String targetFile = dependencies[i]; javaTask.createArg().setValue(baseDir + targetFile); } // change the location directory javaTask.setDir(srcDir); javaTask.setFork(true); if (javaTask.executeJava() != 0) { throw new BuildException("jythonc reported an error"); } } catch (Exception e) { // Have to catch this because of the semantics of calling main() String msg = "Exception while calling " + JYTHON_CLASS + ". Details: " + e.toString(); throw new BuildException(msg, e); } }
6
              
// in src/org/python/expose/generate/ExposeTask.java
catch (IOException e) { throw new BuildException("Unable to read '" + f + "' to expose it", e); }
// in src/org/python/expose/generate/ExposeTask.java
catch (InvalidExposingException iee) { throw new BuildException(iee.getMessage()); }
// in src/org/python/expose/generate/ExposeTask.java
catch (IOException e) { throw new BuildException("Unable to write to '" + dest + "'", e); }
// in src/org/python/util/JycompileAntTask.java
catch (PyException pye) { pye.printStackTrace(); throw new BuildException("Compile failed; see the compiler error output for details."); }
// in src/org/python/util/TemplateAntTask.java
catch(IOException e2) { throw new BuildException(e2.toString(), e2); }
// in src/org/python/util/JythoncAntTask.java
catch (Exception e) { // Have to catch this because of the semantics of calling main() String msg = "Exception while calling " + JYTHON_CLASS + ". Details: " + e.toString(); throw new BuildException(msg, e); }
5
              
// in src/org/python/expose/generate/ExposeTask.java
Override public void process(Set<File> toExpose) throws BuildException { if (toExpose.size() > 1) { log("Exposing " + toExpose.size() + " classes"); } else if (toExpose.size() == 1) { log("Exposing 1 class"); } // Quiet harmless unbootstrapped warnings during the expose process int verbose = Options.verbose; Options.verbose = Py.ERROR; try { expose(toExpose); } finally { Options.verbose = verbose; } }
// in src/org/python/util/JycompileAntTask.java
Override public void process(Set<File> toCompile) throws BuildException { if (toCompile.size() == 0) { return; } else if (toCompile.size() > 1) { log("Compiling " + toCompile.size() + " files"); } else if (toCompile.size() == 1) { log("Compiling 1 file"); } Properties props = new Properties(); props.setProperty(PySystemState.PYTHON_CACHEDIR_SKIP, "true"); PySystemState.initialize(System.getProperties(), props); for (File src : toCompile) { String name = _py_compile.getModuleName(src); String compiledFilePath = name.replace('.', '/'); if (src.getName().endsWith("__init__.py")) { compiledFilePath += "/__init__"; } File compiled = new File(destDir, compiledFilePath + "$py.class"); compile(src, compiled, name); } }
// in src/org/python/util/TemplateAntTask.java
private void runPythonScript(String script) throws BuildException { if(null == python) { python = "python"; } Execute e = new Execute(); e.setWorkingDirectory(srcDir); String[] command; if(lazy) { command = new String[] {python, script, "--lazy"}; } else { command = new String[] {python, script}; } e.setCommandline(command); if(verbose) { String out = ""; for(int k = 0; k < e.getCommandline().length; k++) { out += (e.getCommandline()[k] + " "); } log("executing: " + out); } try { e.execute(); } catch(IOException e2) { throw new BuildException(e2.toString(), e2); } }
// in src/org/python/util/GlobMatchingTask.java
Override public void execute() throws BuildException { checkParameters(); toExpose.clear(); for (String srcEntry : src.list()) { File srcDir = getProject().resolveFile(srcEntry); if (!srcDir.exists()) { throw new BuildException("srcdir '" + srcDir.getPath() + "' does not exist!", getLocation()); } String[] files = getDirectoryScanner(srcDir).getIncludedFiles(); scanDir(srcDir, destDir != null ? destDir : srcDir, files); } process(toExpose); }
// in src/org/python/util/GlobMatchingTask.java
protected void checkParameters() throws BuildException { if (src == null || src.size() == 0) { throw new BuildException("srcdir attribute must be set!", getLocation()); } if (destDir != null && !destDir.isDirectory()) { throw new BuildException("destination directory '" + destDir + "' does not exist " + "or is not a directory", getLocation()); } }
(Lib) ServletException 12
              
// in src/com/xhaus/modjy/ModjyJServlet.java
Override public void init() throws ServletException { try { Properties props = readConfiguration(); PythonInterpreter.initialize(System.getProperties(), props, new String[0]); PySystemState systemState = new PySystemState(); interp = new PythonInterpreter(null, systemState); setupEnvironment(interp, props, systemState); try { interp.exec("from modjy.modjy import " + MODJY_PYTHON_CLASSNAME); } catch (PyException ix) { throw new ServletException("Unable to import '" + MODJY_PYTHON_CLASSNAME + "': maybe you need to set the '" + PYTHON_HOME_PARAM + "' parameter?", ix); } PyObject pyServlet = ((PyType)interp.get(MODJY_PYTHON_CLASSNAME)).__call__(); Object temp = pyServlet.__tojava__(HttpServlet.class); if (temp == Py.NoConversion) throw new ServletException("Corrupted modjy file: cannot find definition of '" + MODJY_PYTHON_CLASSNAME + "' class"); modjyServlet = (HttpServlet)temp; modjyServlet.init(this); } catch (PyException pyx) { throw new ServletException("Exception creating modjy servlet: " + pyx.toString(), pyx); } }
// in src/org/python/util/PyFilter.java
public void init(FilterConfig config) throws ServletException { if (config.getServletContext().getAttribute(PyServlet.INIT_ATTR) == null) { throw new ServletException("Jython has not been initialized. Add " + "org.python.util.PyServletInitializer as a listener to your " + "web.xml."); } this.config = config; String filterPath = config.getInitParameter(FILTER_PATH_PARAM); if (filterPath == null) { throw new ServletException("Missing required param '" + FILTER_PATH_PARAM + "'"); } source = new File(getRealPath(config.getServletContext(), filterPath)); if (!source.exists()) { throw new ServletException(source.getAbsolutePath() + " does not exist."); } interp = PyServlet.createInterpreter(config.getServletContext()); }
// in src/org/python/util/PyFilter.java
private Filter loadFilter() throws ServletException, IOException { loadedMtime = source.lastModified(); cached = PyServlet.createInstance(interp, source, Filter.class); try { cached.init(config); } catch (PyException e) { throw new ServletException(e); } return cached; }
// in src/org/python/util/PyServlet.java
private HttpServlet loadServlet(String path) throws ServletException, IOException { File file = new File(path); HttpServlet servlet = createInstance(interp, file, HttpServlet.class); try { servlet.init(getServletConfig()); } catch (PyException e) { throw new ServletException(e); } cache.put(path, new CacheEntry(servlet, file.lastModified())); return servlet; }
// in src/org/python/util/PyServlet.java
protected static <T> T createInstance(PythonInterpreter interp, File file, Class<T> type) throws ServletException { Matcher m = FIND_NAME.matcher(file.getName()); if (!m.find()) { throw new ServletException("I can't guess the name of the class from " + file.getAbsolutePath()); } String name = m.group(1); try { interp.set("__file__", file.getAbsolutePath()); interp.execfile(file.getAbsolutePath()); PyObject cls = interp.get(name); if (cls == null) { throw new ServletException("No callable (class or function) named " + name + " in " + file.getAbsolutePath()); } PyObject pyServlet = cls.__call__(); Object o = pyServlet.__tojava__(type); if (o == Py.NoConversion) { throw new ServletException("The value from " + name + " must extend " + type.getSimpleName()); } @SuppressWarnings("unchecked") T asT = (T)o; return asT; } catch (PyException e) { throw new ServletException(e); } }
5
              
// in src/com/xhaus/modjy/ModjyJServlet.java
catch (PyException ix) { throw new ServletException("Unable to import '" + MODJY_PYTHON_CLASSNAME + "': maybe you need to set the '" + PYTHON_HOME_PARAM + "' parameter?", ix); }
// in src/com/xhaus/modjy/ModjyJServlet.java
catch (PyException pyx) { throw new ServletException("Exception creating modjy servlet: " + pyx.toString(), pyx); }
// in src/org/python/util/PyFilter.java
catch (PyException e) { throw new ServletException(e); }
// in src/org/python/util/PyServlet.java
catch (PyException e) { throw new ServletException(e); }
// in src/org/python/util/PyServlet.java
catch (PyException e) { throw new ServletException(e); }
10
              
// in src/com/xhaus/modjy/ModjyJServlet.java
Override public void init() throws ServletException { try { Properties props = readConfiguration(); PythonInterpreter.initialize(System.getProperties(), props, new String[0]); PySystemState systemState = new PySystemState(); interp = new PythonInterpreter(null, systemState); setupEnvironment(interp, props, systemState); try { interp.exec("from modjy.modjy import " + MODJY_PYTHON_CLASSNAME); } catch (PyException ix) { throw new ServletException("Unable to import '" + MODJY_PYTHON_CLASSNAME + "': maybe you need to set the '" + PYTHON_HOME_PARAM + "' parameter?", ix); } PyObject pyServlet = ((PyType)interp.get(MODJY_PYTHON_CLASSNAME)).__call__(); Object temp = pyServlet.__tojava__(HttpServlet.class); if (temp == Py.NoConversion) throw new ServletException("Corrupted modjy file: cannot find definition of '" + MODJY_PYTHON_CLASSNAME + "' class"); modjyServlet = (HttpServlet)temp; modjyServlet.init(this); } catch (PyException pyx) { throw new ServletException("Exception creating modjy servlet: " + pyx.toString(), pyx); } }
// in src/com/xhaus/modjy/ModjyJServlet.java
Override public void service(HttpServletRequest req, HttpServletResponse resp) throws ServletException, IOException { modjyServlet.service(req, resp); }
// in src/org/python/util/PyFilter.java
public void doFilter(ServletRequest request, ServletResponse response, FilterChain chain) throws IOException, ServletException { request.setAttribute("pyfilter", this); getFilter().doFilter(request, response, chain); }
// in src/org/python/util/PyFilter.java
public void init(FilterConfig config) throws ServletException { if (config.getServletContext().getAttribute(PyServlet.INIT_ATTR) == null) { throw new ServletException("Jython has not been initialized. Add " + "org.python.util.PyServletInitializer as a listener to your " + "web.xml."); } this.config = config; String filterPath = config.getInitParameter(FILTER_PATH_PARAM); if (filterPath == null) { throw new ServletException("Missing required param '" + FILTER_PATH_PARAM + "'"); } source = new File(getRealPath(config.getServletContext(), filterPath)); if (!source.exists()) { throw new ServletException(source.getAbsolutePath() + " does not exist."); } interp = PyServlet.createInterpreter(config.getServletContext()); }
// in src/org/python/util/PyFilter.java
private Filter getFilter() throws ServletException, IOException { if (cached == null || source.lastModified() > loadedMtime) { return loadFilter(); } return cached; }
// in src/org/python/util/PyFilter.java
private Filter loadFilter() throws ServletException, IOException { loadedMtime = source.lastModified(); cached = PyServlet.createInstance(interp, source, Filter.class); try { cached.init(config); } catch (PyException e) { throw new ServletException(e); } return cached; }
// in src/org/python/util/PyServlet.java
Override public void service(ServletRequest req, ServletResponse res) throws ServletException, IOException { req.setAttribute("pyservlet", this); String spath = (String) req.getAttribute("javax.servlet.include.servlet_path"); if (spath == null) { spath = ((HttpServletRequest)req).getServletPath(); if (spath == null || spath.length() == 0) { // Servlet 2.1 puts the path of an extension-matched servlet in PathInfo. spath = ((HttpServletRequest)req).getPathInfo(); } } String rpath = getServletContext().getRealPath(spath); getServlet(rpath).service(req, res); }
// in src/org/python/util/PyServlet.java
private synchronized HttpServlet getServlet(String path) throws ServletException, IOException { CacheEntry entry = cache.get(path); if (entry == null || new File(path).lastModified() > entry.date) { return loadServlet(path); } return entry.servlet; }
// in src/org/python/util/PyServlet.java
private HttpServlet loadServlet(String path) throws ServletException, IOException { File file = new File(path); HttpServlet servlet = createInstance(interp, file, HttpServlet.class); try { servlet.init(getServletConfig()); } catch (PyException e) { throw new ServletException(e); } cache.put(path, new CacheEntry(servlet, file.lastModified())); return servlet; }
// in src/org/python/util/PyServlet.java
protected static <T> T createInstance(PythonInterpreter interp, File file, Class<T> type) throws ServletException { Matcher m = FIND_NAME.matcher(file.getName()); if (!m.find()) { throw new ServletException("I can't guess the name of the class from " + file.getAbsolutePath()); } String name = m.group(1); try { interp.set("__file__", file.getAbsolutePath()); interp.execfile(file.getAbsolutePath()); PyObject cls = interp.get(name); if (cls == null) { throw new ServletException("No callable (class or function) named " + name + " in " + file.getAbsolutePath()); } PyObject pyServlet = cls.__call__(); Object o = pyServlet.__tojava__(type); if (o == Py.NoConversion) { throw new ServletException("The value from " + name + " must extend " + type.getSimpleName()); } @SuppressWarnings("unchecked") T asT = (T)o; return asT; } catch (PyException e) { throw new ServletException(e); } }
(Lib) IOException 8
              
// in src/org/python/indexer/Util.java
public static byte[] getBytesFromFile(File file) throws IOException { InputStream is = null; try { is = new FileInputStream(file); long length = file.length(); if (length > Integer.MAX_VALUE) { throw new IOException("file too large: " + file); } byte[] bytes = new byte[(int)length]; int offset = 0; int numRead = 0; while (offset < bytes.length && (numRead = is.read(bytes, offset, bytes.length-offset)) >= 0) { offset += numRead; } if (offset < bytes.length) { throw new IOException("Failed to read whole file " + file); } return bytes; } finally { if (is != null) { is.close(); } } }
// in src/org/python/modules/ucnhash.java
public static void loadTables() throws Exception { InputStream instream = ucnhash.class. getResourceAsStream("ucnhash.dat"); if (instream == null) throw new IOException("Unicode name database not found: " + "ucnhash.dat"); DataInputStream in = new DataInputStream( new BufferedInputStream(instream)); n = in.readShort(); m = in.readShort(); minchar= in.readShort(); maxchar = in.readShort(); alphasz = in.readShort(); maxlen = in.readShort(); maxidx = maxlen*alphasz-minchar; G = readShortTable(in); if (in.readShort() != 3) throw new IOException("UnicodeNameMap file corrupt, " + "unknown dimension"); T0 = readShortTable(in); T1 = readShortTable(in); T2 = readShortTable(in); wordoffs = readShortTable(in); worddata = readByteTable(in); wordstart = in.readShort(); wordcutoff = in.readShort(); maxklen = in.readShort(); rawdata = readByteTable(in); rawindex = readCharTable(in); codepoint = readCharTable(in); }
// in src/org/python/modules/ucnhash.java
private static short[] readShortTable(DataInputStream in) throws IOException { if (in.read() != 't') throw new IOException("UnicodeNameMap file corrupt, shorttable"); int n = in.readUnsignedShort() / 2; short[] table = new short[n]; for (int i = 0; i < n; i++) { table[i] = in.readShort(); } return table; }
// in src/org/python/modules/ucnhash.java
private static char[] readCharTable(DataInputStream in) throws IOException { if (in.read() != 't') throw new IOException("UnicodeNameMap file corrupt, chartable"); int n = in.readUnsignedShort() / 2; char[] table = new char[n]; for (int i = 0; i < n; i++) { table[i] = in.readChar(); } return table; }
// in src/org/python/modules/ucnhash.java
private static byte[] readByteTable(DataInputStream in) throws IOException { if (in.read() != 't') throw new IOException("UnicodeNameMap file corrupt, byte table"); int n = in.readUnsignedShort(); byte[] table = new byte[n]; in.readFully(table); return table; }
0 94
              
// in src/com/xhaus/modjy/ModjyJServlet.java
Override public void service(HttpServletRequest req, HttpServletResponse resp) throws ServletException, IOException { modjyServlet.service(req, resp); }
// in src/org/python/indexer/Indexer.java
public void setProjectDir(String cd) throws IOException { projDir = Util.canonicalize(cd); }
// in src/org/python/indexer/Indexer.java
public void addPaths(List<String> p) throws IOException { for (String s : p) { addPath(s); } }
// in src/org/python/indexer/Indexer.java
public void addPath(String p) throws IOException { path.add(Util.canonicalize(p)); }
// in src/org/python/indexer/Indexer.java
public void setPath(List<String> path) throws IOException { this.path = new ArrayList<String>(path.size()); addPaths(path); }
// in src/org/python/indexer/Util.java
public static byte[] getBytesFromFile(File file) throws IOException { InputStream is = null; try { is = new FileInputStream(file); long length = file.length(); if (length > Integer.MAX_VALUE) { throw new IOException("file too large: " + file); } byte[] bytes = new byte[(int)length]; int offset = 0; int numRead = 0; while (offset < bytes.length && (numRead = is.read(bytes, offset, bytes.length-offset)) >= 0) { offset += numRead; } if (offset < bytes.length) { throw new IOException("Failed to read whole file " + file); } return bytes; } finally { if (is != null) { is.close(); } } }
// in src/org/python/compiler/ClassFile.java
public void addInterface(String name) throws IOException { String[] new_interfaces = new String[interfaces.length+1]; System.arraycopy(interfaces, 0, new_interfaces, 0, interfaces.length); new_interfaces[interfaces.length] = name; interfaces = new_interfaces; }
// in src/org/python/compiler/ClassFile.java
public Code addMethod(String name, String type, int access) throws IOException { MethodVisitor mv = cw.visitMethod(access, name, type, null, null); Code pmv = new Code(mv, type, access); methodVisitors.add(pmv); return pmv; }
// in src/org/python/compiler/ClassFile.java
public void addField(String name, String type, int access) throws IOException { FieldVisitor fv = cw.visitField(access, name, type, null, null); fieldVisitors.add(fv); }
// in src/org/python/compiler/ClassFile.java
public void endFields() throws IOException { for (FieldVisitor fv : fieldVisitors) { fv.visitEnd(); } }
// in src/org/python/compiler/ClassFile.java
public void endMethods() throws IOException { for (int i=0; i<methodVisitors.size(); i++) { MethodVisitor mv = methodVisitors.get(i); mv.visitMaxs(0,0); mv.visitEnd(); } }
// in src/org/python/compiler/ClassFile.java
public void write(OutputStream stream) throws IOException { cw.visit(Opcodes.V1_5, Opcodes.ACC_PUBLIC + Opcodes.ACC_SUPER, this.name, null, this.superclass, interfaces); AnnotationVisitor av = cw.visitAnnotation("Lorg/python/compiler/APIVersion;", true); // XXX: should imp.java really house this value or should imp.java point into // org.python.compiler? av.visit("value", new Integer(imp.getAPIVersion())); av.visitEnd(); av = cw.visitAnnotation("Lorg/python/compiler/MTime;", true); av.visit("value", new Long(mtime)); av.visitEnd(); if (sfilename != null) { cw.visitSource(sfilename, null); } endFields(); endMethods(); byte[] ba = cw.toByteArray(); //fos = io.FileOutputStream("%s.class" % self.name) ByteArrayOutputStream baos = new ByteArrayOutputStream(ba.length); baos.write(ba, 0, ba.length); baos.writeTo(stream); //debug(baos); baos.close(); }
// in src/org/python/compiler/CodeCompiler.java
public void getNone() throws IOException { code.getstatic(p(Py.class), "None", ci(PyObject.class)); }
// in src/org/python/compiler/CodeCompiler.java
static int makeStrings(Code c, Collection<String> names) throws IOException { if (names != null) { c.iconst(names.size()); } else { c.iconst_0(); } c.anewarray(p(String.class)); int strings = c.getLocal(ci(String[].class)); c.astore(strings); if (names != null) { int i = 0; for (String name : names) { c.aload(strings); c.iconst(i); c.ldc(name); c.aastore(); i++; } } return strings; }
// in src/org/python/compiler/Module.java
void get(Code c) throws IOException { c.getstatic(module.classfile.name, name, ci(PyInteger.class)); }
// in src/org/python/compiler/Module.java
void put(Code c) throws IOException { module.classfile.addField(name, ci(PyInteger.class), access); c.iconst(value); c.invokestatic(p(Py.class), "newInteger", sig(PyInteger.class, Integer.TYPE)); c.putstatic(module.classfile.name, name, ci(PyInteger.class)); }
// in src/org/python/compiler/Module.java
void get(Code c) throws IOException { c.getstatic(module.classfile.name, name, ci(PyFloat.class)); }
// in src/org/python/compiler/Module.java
void put(Code c) throws IOException { module.classfile.addField(name, ci(PyFloat.class), access); c.ldc(new Double(value)); c.invokestatic(p(Py.class), "newFloat", sig(PyFloat.class, Double.TYPE)); c.putstatic(module.classfile.name, name, ci(PyFloat.class)); }
// in src/org/python/compiler/Module.java
void get(Code c) throws IOException { c.getstatic(module.classfile.name, name, ci(PyComplex.class)); }
// in src/org/python/compiler/Module.java
void put(Code c) throws IOException { module.classfile.addField(name, ci(PyComplex.class), access); c.ldc(new Double(value)); c.invokestatic(p(Py.class), "newImaginary", sig(PyComplex.class, Double.TYPE)); c.putstatic(module.classfile.name, name, ci(PyComplex.class)); }
// in src/org/python/compiler/Module.java
void get(Code c) throws IOException { c.getstatic(module.classfile.name, name, ci(PyString.class)); }
// in src/org/python/compiler/Module.java
void put(Code c) throws IOException { module.classfile.addField(name, ci(PyString.class), access); c.ldc(value); c.invokestatic(p(PyString.class), "fromInterned", sig(PyString.class, String.class)); c.putstatic(module.classfile.name, name, ci(PyString.class)); }
// in src/org/python/compiler/Module.java
void get(Code c) throws IOException { c.getstatic(module.classfile.name, name, ci(PyUnicode.class)); }
// in src/org/python/compiler/Module.java
void put(Code c) throws IOException { module.classfile.addField(name, ci(PyUnicode.class), access); c.ldc(value); c.invokestatic(p(PyUnicode.class), "fromInterned", sig(PyUnicode.class, String.class)); c.putstatic(module.classfile.name, name, ci(PyUnicode.class)); }
// in src/org/python/compiler/Module.java
void get(Code c) throws IOException { c.getstatic(module.classfile.name, name, ci(PyLong.class)); }
// in src/org/python/compiler/Module.java
void put(Code c) throws IOException { module.classfile.addField(name, ci(PyLong.class), access); c.ldc(value); c.invokestatic(p(Py.class), "newLong", sig(PyLong.class, String.class)); c.putstatic(module.classfile.name, name, ci(PyLong.class)); }
// in src/org/python/compiler/Module.java
void get(Code c) throws IOException { c.getstatic(module.classfile.name, name, ci(PyCode.class)); }
// in src/org/python/compiler/Module.java
void put(Code c) throws IOException { module.classfile.addField(name, ci(PyCode.class), access); c.iconst(argcount); //Make all names int nameArray; if (names != null) { nameArray = CodeCompiler.makeStrings(c, names); } else { // classdef nameArray = CodeCompiler.makeStrings(c, null); } c.aload(nameArray); c.freeLocal(nameArray); c.aload(1); c.ldc(co_name); c.iconst(co_firstlineno); c.iconst(arglist ? 1 : 0); c.iconst(keywordlist ? 1 : 0); c.getstatic(module.classfile.name, "self", "L" + module.classfile.name + ";"); c.iconst(id); if (cellvars != null) { int strArray = CodeCompiler.makeStrings(c, cellvars); c.aload(strArray); c.freeLocal(strArray); } else { c.aconst_null(); } if (freevars != null) { int strArray = CodeCompiler.makeStrings(c, freevars); c.aload(strArray); c.freeLocal(strArray); } else { c.aconst_null(); } c.iconst(jy_npurecell); c.iconst(moreflags); c.invokestatic(p(Py.class), "newCode", sig(PyCode.class, Integer.TYPE, String[].class, String.class, String.class, Integer.TYPE, Boolean.TYPE, Boolean.TYPE, PyFunctionTable.class, Integer.TYPE, String[].class, String[].class, Integer.TYPE, Integer.TYPE)); c.putstatic(module.classfile.name, name, ci(PyCode.class)); }
// in src/org/python/compiler/Module.java
public void addInit() throws IOException { Code c = classfile.addMethod("<init>", sig(Void.TYPE, String.class), ACC_PUBLIC); c.aload(0); c.invokespecial(p(PyFunctionTable.class), "<init>", sig(Void.TYPE)); addConstants(c); }
// in src/org/python/compiler/Module.java
public void addRunnable() throws IOException { Code c = classfile.addMethod("getMain", sig(PyCode.class), ACC_PUBLIC); mainCode.get(c); c.areturn(); }
// in src/org/python/compiler/Module.java
public void addMain() throws IOException { Code c = classfile.addMethod("main", sig(Void.TYPE, String[].class), ACC_PUBLIC | ACC_STATIC); c.new_(classfile.name); c.dup(); c.ldc(classfile.name); c.invokespecial(classfile.name, "<init>", sig(Void.TYPE, String.class)); c.invokevirtual(classfile.name, "getMain", sig(PyCode.class)); c.invokestatic(p(CodeLoader.class), CodeLoader.SIMPLE_FACTORY_METHOD_NAME, sig(CodeBootstrap.class, PyCode.class)); c.aload(0); c.invokestatic(p(Py.class), "runMain", sig(Void.TYPE, CodeBootstrap.class, String[].class)); c.return_(); }
// in src/org/python/compiler/Module.java
public void addBootstrap() throws IOException { Code c = classfile.addMethod(CodeLoader.GET_BOOTSTRAP_METHOD_NAME, sig(CodeBootstrap.class), ACC_PUBLIC | ACC_STATIC); c.ldc(Type.getType("L" + classfile.name + ";")); c.invokestatic(p(PyRunnableBootstrap.class), PyRunnableBootstrap.REFLECTION_METHOD_NAME, sig(CodeBootstrap.class, Class.class)); c.areturn(); }
// in src/org/python/compiler/Module.java
void addConstants(Code c) throws IOException { classfile.addField("self", "L" + classfile.name + ";", ACC_STATIC); c.aload(0); c.putstatic(classfile.name, "self", "L" + classfile.name + ";"); Enumeration e = constants.elements(); while (e.hasMoreElements()) { Constant constant = (Constant) e.nextElement(); constant.put(c); } for (int i = 0; i < codes.size(); i++) { PyCodeConstant pyc = codes.get(i); pyc.put(c); } c.return_(); }
// in src/org/python/compiler/Module.java
public void addFunctions() throws IOException { Code code = classfile.addMethod("call_function", sig(PyObject.class, Integer.TYPE, PyFrame.class, ThreadState.class), ACC_PUBLIC); code.aload(0); // this code.aload(2); // frame code.aload(3); // thread state Label def = new Label(); Label[] labels = new Label[codes.size()]; int i; for (i = 0; i < labels.length; i++) { labels[i] = new Label(); } //Get index for function to call code.iload(1); code.tableswitch(0, labels.length - 1, def, labels); for (i = 0; i < labels.length; i++) { code.label(labels[i]); code.invokevirtual(classfile.name, (codes.get(i)).fname, sig(PyObject.class, PyFrame.class, ThreadState.class)); code.areturn(); } code.label(def); //Should probably throw internal exception here code.aconst_null(); code.areturn(); }
// in src/org/python/compiler/Module.java
public void write(OutputStream stream) throws IOException { addInit(); addRunnable(); addMain(); addBootstrap(); addFunctions(); classfile.addInterface(p(PyRunnable.class)); if (sfilename != null) { classfile.setSource(sfilename); } classfile.write(stream); }
// in src/org/python/compiler/LineNumberTable.java
public void write(DataOutputStream stream) throws IOException { stream.writeShort(attName); int n = lines.size(); stream.writeInt(n * 2 + 2); stream.writeShort(n / 2); for (int i = 0; i < n; i += 2) { Short startpc = lines.elementAt(i); Short lineno = lines.elementAt(i+1); stream.writeShort(startpc.shortValue()); stream.writeShort(lineno.shortValue()); } }
// in src/org/python/antlr/NoCloseReaderStream.java
public void load(Reader r, int size, int readChunkSize) throws IOException { if ( r==null ) { return; } if ( size<=0 ) { size = INITIAL_BUFFER_SIZE; } if ( readChunkSize<=0 ) { readChunkSize = READ_BUFFER_SIZE; } data = new char[size]; // read all the data in chunks of readChunkSize int numRead=0; int p = 0; do { if ( p+readChunkSize > data.length ) { // overflow? char[] newdata = new char[data.length*2]; // resize System.arraycopy(data, 0, newdata, 0, data.length); data = newdata; } numRead = r.read(data, p, readChunkSize); p += numRead; } while (numRead!=-1); // while not EOF // set the actual size of the data available; // EOF subtracted one above in p+=numRead; add one back super.n = p+1; }
// in src/org/python/modules/ucnhash.java
private static short[] readShortTable(DataInputStream in) throws IOException { if (in.read() != 't') throw new IOException("UnicodeNameMap file corrupt, shorttable"); int n = in.readUnsignedShort() / 2; short[] table = new short[n]; for (int i = 0; i < n; i++) { table[i] = in.readShort(); } return table; }
// in src/org/python/modules/ucnhash.java
private static char[] readCharTable(DataInputStream in) throws IOException { if (in.read() != 't') throw new IOException("UnicodeNameMap file corrupt, chartable"); int n = in.readUnsignedShort() / 2; char[] table = new char[n]; for (int i = 0; i < n; i++) { table[i] = in.readChar(); } return table; }
// in src/org/python/modules/ucnhash.java
private static byte[] readByteTable(DataInputStream in) throws IOException { if (in.read() != 't') throw new IOException("UnicodeNameMap file corrupt, byte table"); int n = in.readUnsignedShort(); byte[] table = new byte[n]; in.readFully(table); return table; }
// in src/org/python/core/FilelikeInputStream.java
public int read() throws IOException { byte[] oneB = new byte[1]; int numread = read(oneB, 0, 1); if(numread == -1) { return -1; } return oneB[0]; }
// in src/org/python/core/FilelikeInputStream.java
public int read(byte b[], int off, int len) throws IOException { if(b == null) { throw new NullPointerException(); } else if((off < 0) || (off > b.length) || (len < 0) || ((off + len) > b.length) || ((off + len) < 0)) { throw new IndexOutOfBoundsException(); } else if(len == 0) { return 0; } String result = ((PyString) filelike.__getattr__("read") .__call__(new PyInteger(len))).getString(); if(result.length() == 0) { return -1; } System.arraycopy(StringUtil.toBytes(result), 0, b, off, result.length()); return result.length(); }
// in src/org/python/core/FilelikeInputStream.java
public void close() throws IOException { filelike.__getattr__("close").__call__(); }
// in src/org/python/core/PyInstance.java
private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException { in.defaultReadObject(); String module = in.readUTF(); String name = in.readUTF(); /* Check for types and missing members here */ //System.out.println("module: "+module+", "+name); PyObject mod = imp.importName(module.intern(), false); PyClass pyc = (PyClass)mod.__getattr__(name.intern()); instclass = pyc; }
// in src/org/python/core/PyInstance.java
private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException { //System.out.println("writing: "+getClass().getName()); out.defaultWriteObject(); PyObject name = instclass.__findattr__("__module__"); if (!(name instanceof PyString) || name == Py.None) { throw Py.ValueError("Can't find module for class: "+ instclass.__name__); } out.writeUTF(name.toString()); name = instclass.__findattr__("__name__"); if (!(name instanceof PyString) || name == Py.None) { throw Py.ValueError("Can't find module for class with no name"); } out.writeUTF(name.toString()); }
// in src/org/python/core/io/StreamIO.java
private static FileDescriptor getInputFileDescriptor(InputStream stream) throws IOException { if (stream == null) { return null; } if (stream instanceof FileInputStream) { return ((FileInputStream)stream).getFD(); } if (stream instanceof FilterInputStream) { Field inField = null; try { inField = FilterInputStream.class.getDeclaredField("in"); inField.setAccessible(true); return getInputFileDescriptor((InputStream)inField.get(stream)); } catch (Exception e) { // XXX: masking other exceptions } finally { if (inField != null && inField.isAccessible()) { inField.setAccessible(false); } } } return null; }
// in src/org/python/core/io/StreamIO.java
private static FileDescriptor getOutputFileDescriptor(OutputStream stream) throws IOException { if (stream == null) { return null; } if (stream instanceof FileOutputStream) { return ((FileOutputStream)stream).getFD(); } if (stream instanceof FilterOutputStream) { Field outField = null; try { outField = FilterOutputStream.class.getDeclaredField("out"); outField.setAccessible(true); return getOutputFileDescriptor((OutputStream)outField.get(stream)); } catch (Exception e) { // XXX: masking other exceptions } finally { if (outField != null && outField.isAccessible()) { outField.setAccessible(false); } } } return null; }
// in src/org/python/core/io/FileIO.java
private long writeAppend(ByteBuffer[] bufs) throws IOException { long count = 0; int bufCount; for (ByteBuffer buf : bufs) { if (!buf.hasRemaining()) { continue; } if ((bufCount = fileChannel.write(buf, fileChannel.position())) == 0) { break; } count += bufCount; } return count; }
// in src/org/python/core/io/TextIOInputStream.java
Override public int read() throws IOException { String result = textIO.read(1); if (result.length() == 0) { return -1; } return (int)result.charAt(0); }
// in src/org/python/core/io/TextIOInputStream.java
Override public int read(byte[] b, int off, int len) throws IOException { if (b == null) { throw new NullPointerException(); } else if ((off < 0) || (off > b.length) || (len < 0) || ((off + len) > b.length) || ((off + len) < 0)) { throw new IndexOutOfBoundsException(); } else if (len == 0) { return 0; } String result = textIO.read(len); len = result.length(); for (int i = 0; i < len; i++) { b[off + i] = (byte)result.charAt(i); } return len == 0 ? -1 : len; }
// in src/org/python/core/io/TextIOInputStream.java
Override public void close() throws IOException { textIO.close(); }
// in src/org/python/core/io/TextIOInputStream.java
Override public long skip(long n) throws IOException { return textIO.seek(n, 1); }
// in src/org/python/core/PyArray.java
private int fromStream(InputStream is) throws IOException, EOFException { return fromStream(is, is.available() / getStorageSize()); }
// in src/org/python/core/PyArray.java
private int fromStream(InputStream is, int count) throws IOException, EOFException { DataInputStream dis = new DataInputStream(is); // current number of items present int origsize = delegate.getSize(); // position to start inserting into int index = origsize; // create capacity for 'count' items delegate.ensureCapacity(index + count); if (type.isPrimitive()) { switch (typecode.charAt(0)) { case 'z': for (int i = 0; i < count; i++, index++) { Array.setBoolean(data, index, dis.readBoolean()); delegate.size++; } break; case 'b': for (int i = 0; i < count; i++, index++) { Array.setByte(data, index, dis.readByte()); delegate.size++; } break; case 'B': for (int i = 0; i < count; i++, index++) { Array.setShort(data, index, unsignedByte(dis.readByte())); delegate.size++; } break; case 'u': // use 32-bit integers since we want UCS-4 storage for (int i = 0; i < count; i++, index++) { Array.setInt(data, index, dis.readInt()); delegate.size++; } break; case 'c': for (int i = 0; i < count; i++, index++) { Array.setChar(data, index, (char) (dis.readByte() & 0xff)); delegate.size++; } break; case 'h': for (int i = 0; i < count; i++, index++) { Array.setShort(data, index, dis.readShort()); delegate.size++; } break; case 'H': for (int i = 0; i < count; i++, index++) { Array.setInt(data, index, unsignedShort(dis.readShort())); delegate.size++; } break; case 'i': for (int i = 0; i < count; i++, index++) { Array.setInt(data, index, dis.readInt()); delegate.size++; } break; case 'I': for (int i = 0; i < count; i++, index++) { Array.setLong(data, index, unsignedInt(dis.readInt())); delegate.size++; } break; case 'l': for (int i = 0; i < count; i++, index++) { Array.setLong(data, index, dis.readLong()); delegate.size++; } break; case 'L': // faking it for (int i = 0; i < count; i++, index++) { Array.setLong(data, index, dis.readLong()); delegate.size++; } break; case 'f': for (int i = 0; i < count; i++, index++) { Array.setFloat(data, index, dis.readFloat()); delegate.size++; } break; case 'd': for (int i = 0; i < count; i++, index++) { Array.setDouble(data, index, dis.readDouble()); delegate.size++; } break; } } dis.close(); return (index - origsize); }
// in src/org/python/core/PyArray.java
private int toStream(OutputStream os) throws IOException { DataOutputStream dos = new DataOutputStream(os); switch (typecode.charAt(0)) { case 'z': for(int i = 0; i < delegate.getSize(); i++) dos.writeBoolean(Array.getBoolean(data, i)); break; case 'b': for(int i = 0; i < delegate.getSize(); i++) dos.writeByte(Array.getByte(data, i)); break; case 'B': for(int i = 0; i < delegate.getSize(); i++) dos.writeByte(signedByte(Array.getShort(data, i))); break; case 'u': // use 32-bit integers since we want UCS-4 storage for(int i = 0; i < delegate.getSize(); i++) dos.writeInt(Array.getInt(data, i)); break; case 'c': for(int i = 0; i < delegate.getSize(); i++) dos.writeByte((byte)Array.getChar(data, i)); break; case 'h': for(int i = 0; i < delegate.getSize(); i++) dos.writeShort(Array.getShort(data, i)); break; case 'H': for(int i = 0; i < delegate.getSize(); i++) dos.writeShort(signedShort(Array.getInt(data, i))); break; case 'i': for(int i = 0; i < delegate.getSize(); i++) dos.writeInt(Array.getInt(data, i)); break; case 'I': for(int i = 0; i < delegate.getSize(); i++) dos.writeInt(signedInt(Array.getLong(data, i))); break; case 'l': for(int i = 0; i < delegate.getSize(); i++) dos.writeLong(Array.getLong(data, i)); break; case 'L': // faking it for(int i = 0; i < delegate.getSize(); i++) dos.writeLong(Array.getLong(data, i)); break; case 'f': for(int i = 0; i < delegate.getSize(); i++) dos.writeFloat(Array.getFloat(data, i)); break; case 'd': for(int i = 0; i < delegate.getSize(); i++) dos.writeDouble(Array.getDouble(data, i)); break; } return dos.size(); }
// in src/org/python/core/PyJavaType.java
private static <T> T cloneX(T x) throws IOException, ClassNotFoundException { ByteArrayOutputStream bout = new ByteArrayOutputStream(); CloneOutput cout = new CloneOutput(bout); cout.writeObject(x); byte[] bytes = bout.toByteArray(); ByteArrayInputStream bin = new ByteArrayInputStream(bytes); CloneInput cin = new CloneInput(bin, cout); @SuppressWarnings("unchecked") // thanks to Bas de Bakker for the tip! T clone = (T) cin.readObject(); return clone; }
// in src/org/python/core/PyJavaType.java
Override protected Class<?> resolveClass(ObjectStreamClass osc) throws IOException, ClassNotFoundException { Class<?> c = output.classQueue.poll(); String expected = osc.getName(); String found = (c == null) ? null : c.getName(); if (!expected.equals(found)) { throw new InvalidClassException("Classes desynchronized: " + "found " + found + " when expecting " + expected); } return c; }
// in src/org/python/core/PyJavaType.java
Override protected Class<?> resolveProxyClass(String[] interfaceNames) throws IOException, ClassNotFoundException { return output.classQueue.poll(); }
// in src/org/python/core/ParserFacade.java
private static ExpectedEncodingBufferedReader prepBufReader(Reader reader, CompilerFlags cflags, String filename) throws IOException { cflags.source_is_utf8 = true; cflags.encoding = "utf-8"; BufferedReader bufferedReader = new BufferedReader(reader); bufferedReader.mark(MARK_LIMIT); if (findEncoding(bufferedReader) != null) throw new ParseException("encoding declaration in Unicode string"); bufferedReader.reset(); return new ExpectedEncodingBufferedReader(bufferedReader, null); }
// in src/org/python/core/ParserFacade.java
private static ExpectedEncodingBufferedReader prepBufReader(InputStream input, CompilerFlags cflags, String filename, boolean fromString) throws IOException { return prepBufReader(input, cflags, filename, fromString, true); }
// in src/org/python/core/ParserFacade.java
private static ExpectedEncodingBufferedReader prepBufReader(InputStream input, CompilerFlags cflags, String filename, boolean fromString, boolean universalNewlines) throws IOException { input = new BufferedInputStream(input); boolean bom = adjustForBOM(input); String encoding = readEncoding(input); if (encoding == null) { if (bom) { encoding = "utf-8"; } else if (cflags != null && cflags.encoding != null) { encoding = cflags.encoding; } } if (cflags.source_is_utf8) { if (encoding != null) { throw new ParseException("encoding declaration in Unicode string"); } encoding = "utf-8"; } cflags.encoding = encoding; if (universalNewlines) { // Enable universal newlines mode on the input StreamIO rawIO = new StreamIO(input, true); org.python.core.io.BufferedReader bufferedIO = new org.python.core.io.BufferedReader(rawIO, 0); UniversalIOWrapper textIO = new UniversalIOWrapper(bufferedIO); input = new TextIOInputStream(textIO); } Charset cs; try { // Use ascii for the raw bytes when no encoding was specified if (encoding == null) { if (fromString) { cs = Charset.forName("ISO-8859-1"); } else { cs = Charset.forName("ascii"); } } else { cs = Charset.forName(encoding); } } catch (UnsupportedCharsetException exc) { throw new PySyntaxError("Unknown encoding: " + encoding, 1, 0, "", filename); } CharsetDecoder dec = cs.newDecoder(); dec.onMalformedInput(CodingErrorAction.REPORT); dec.onUnmappableCharacter(CodingErrorAction.REPORT); return new ExpectedEncodingBufferedReader(new InputStreamReader(input, dec), encoding); }
// in src/org/python/core/ParserFacade.java
private static ExpectedEncodingBufferedReader prepBufReader(String string, CompilerFlags cflags, String filename) throws IOException { if (cflags.source_is_utf8) return prepBufReader(new StringReader(string), cflags, filename); byte[] stringBytes = StringUtil.toBytes(string); return prepBufReader(new ByteArrayInputStream(stringBytes), cflags, filename, true, false); }
// in src/org/python/core/ParserFacade.java
private static boolean adjustForBOM(InputStream stream) throws IOException { stream.mark(3); int ch = stream.read(); if (ch == 0xEF) { if (stream.read() != 0xBB) { throw new ParseException("Incomplete BOM at beginning of file"); } if (stream.read() != 0xBF) { throw new ParseException("Incomplete BOM at beginning of file"); } return true; } stream.reset(); return false; }
// in src/org/python/core/ParserFacade.java
private static String readEncoding(InputStream stream) throws IOException { stream.mark(MARK_LIMIT); String encoding = null; BufferedReader br = new BufferedReader(new InputStreamReader(stream, "ISO-8859-1"), 512); encoding = findEncoding(br); // XXX: reset() can still raise an IOException if a line exceeds our large mark // limit stream.reset(); return encodingMap(encoding); }
// in src/org/python/core/ParserFacade.java
private static String findEncoding(BufferedReader br) throws IOException { String encoding = null; for (int i = 0; i < 2; i++) { String strLine = br.readLine(); if (strLine == null) { break; } String result = matchEncoding(strLine); if (result != null) { encoding = result; break; } } return encoding; }
// in src/org/python/core/SyspathArchive.java
InputStream getInputStream(ZipEntry entry) throws IOException { InputStream istream = this.zipFile.getInputStream(entry); // Some jdk1.1 VMs have problems with detecting the end of a zip // stream correctly. If you read beyond the end, you get a // EOFException("Unexpected end of ZLIB input stream"), not a // -1 return value. // XXX: Since 1.1 is no longer supported, we should review the usefulness // of this workaround. // As a workaround we read the file fully here, but only getSize() // bytes. int len = (int) entry.getSize(); byte[] buffer = new byte[len]; int off = 0; while (len > 0) { int l = istream.read(buffer, off, buffer.length - off); if (l < 0) return null; off += l; len -= l; } istream.close(); return new ByteArrayInputStream(buffer); }
// in src/org/python/core/imp.java
public static byte[] readCode(String name, InputStream fp, boolean testing) throws IOException { return readCode(name, fp, testing, NO_MTIME); }
// in src/org/python/core/imp.java
public static byte[] readCode(String name, InputStream fp, boolean testing, long mtime) throws IOException { byte[] data = readBytes(fp); int api; AnnotationReader ar = new AnnotationReader(data); api = ar.getVersion(); if (api != APIVersion) { if (testing) { return null; } else { throw Py.ImportError("invalid api version(" + api + " != " + APIVersion + ") in: " + name); } } if (testing && mtime != NO_MTIME) { long time = ar.getMTime(); if (mtime != time) { return null; } } return data; }
// in src/org/python/core/util/FileUtil.java
public static byte[] readBytes(InputStream in) throws IOException { final int bufsize = 8192; // nice buffer size used in JDK byte[] buf = new byte[bufsize]; ByteArrayOutputStream out = new ByteArrayOutputStream(bufsize); int count; while (true) { count = in.read(buf, 0, bufsize); if (count < 0) { break; } out.write(buf, 0, count); } return out.toByteArray(); }
// in src/org/python/core/packagecache/PackageManager.java
static protected int checkAccess(java.io.InputStream cstream) throws java.io.IOException { java.io.DataInputStream istream = new java.io.DataInputStream(cstream); try { int magic = istream.readInt(); if (magic != 0xcafebabe) { return -1; } } catch (EOFException eof) { //Empty or 1 byte file. return -1; } //int minor = istream.readShort(); //int major = istream.readShort(); // Check versions??? // System.out.println("magic: "+magic+", "+major+", "+minor); int nconstants = istream.readShort(); for (int i = 1; i < nconstants; i++) { int cid = istream.readByte(); // System.out.println(""+i+" : "+cid); switch (cid) { case 7: istream.skipBytes(2); break; case 9: case 10: case 11: istream.skipBytes(4); break; case 8: istream.skipBytes(2); break; case 3: case 4: istream.skipBytes(4); break; case 5: case 6: istream.skipBytes(8); i++; break; case 12: istream.skipBytes(4); break; case 1: // System.out.println("utf: "+istream.readUTF()+";"); int slength = istream.readUnsignedShort(); istream.skipBytes(slength); break; default: // System.err.println("unexpected cid: "+cid+", "+i+", "+ // nconstants); // for (int j=0; j<10; j++) // System.err.print(", "+istream.readByte()); // System.err.println(); return -1; } } return istream.readShort(); }
// in src/org/python/core/packagecache/CachedJarsPackageManager.java
private void addZipEntry(Map<String, List<String>[]> zipPackages, ZipEntry entry, ZipInputStream zip) throws IOException { String name = entry.getName(); // System.err.println("entry: "+name); if (!name.endsWith(".class")) { return; } char sep = '/'; int breakPoint = name.lastIndexOf(sep); if (breakPoint == -1) { breakPoint = name.lastIndexOf('\\'); sep = '\\'; } String packageName; if (breakPoint == -1) { packageName = ""; } else { packageName = name.substring(0, breakPoint).replace(sep, '.'); } String className = name.substring(breakPoint + 1, name.length() - 6); if (filterByName(className, false)) { return; } List<String>[] vec = zipPackages.get(packageName); if (vec == null) { vec = createGenericStringListArray(); zipPackages.put(packageName, vec); } int access = checkAccess(zip); if ((access != -1) && !filterByAccess(name, access)) { vec[0].add(className); } else { vec[1].add(className); } }
// in src/org/python/core/packagecache/CachedJarsPackageManager.java
private Map<String, String> getZipPackages(InputStream jarin) throws IOException { Map<String, List<String>[]> zipPackages = Generic.map(); ZipInputStream zip = new ZipInputStream(jarin); ZipEntry entry; while ((entry = zip.getNextEntry()) != null) { addZipEntry(zipPackages, entry, zip); zip.closeEntry(); } // Turn each vector into a comma-separated String Map<String, String> transformed = Generic.map(); for (Entry<String,List<String>[]> kv : zipPackages.entrySet()) { List<String>[] vec = kv.getValue(); String classes = listToString(vec[0]); if (vec[1].size() > 0) { classes += '@' + listToString(vec[1]); } transformed.put(kv.getKey(), classes); } return transformed; }
// in src/org/python/core/packagecache/CachedJarsPackageManager.java
protected DataInputStream inOpenIndex() throws IOException { File indexFile = new File(this.cachedir, "packages.idx"); if (!indexFile.exists()) { return null; } DataInputStream istream = new DataInputStream(new BufferedInputStream( new FileInputStream(indexFile))); return istream; }
// in src/org/python/core/packagecache/CachedJarsPackageManager.java
protected DataOutputStream outOpenIndex() throws IOException { File indexFile = new File(this.cachedir, "packages.idx"); return new DataOutputStream(new BufferedOutputStream( new FileOutputStream(indexFile))); }
// in src/org/python/core/packagecache/CachedJarsPackageManager.java
protected DataInputStream inOpenCacheFile(String cachefile) throws IOException { return new DataInputStream(new BufferedInputStream(new FileInputStream( cachefile))); }
// in src/org/python/core/packagecache/CachedJarsPackageManager.java
protected DataOutputStream outCreateCacheFile(JarXEntry entry, boolean create) throws IOException { File cachefile = null; if (create) { int index = 1; String suffix = ""; String jarname = entry.cachefile; while (true) { cachefile = new File(this.cachedir, jarname + suffix + ".pkc"); // System.err.println("try cachefile: "+cachefile); if (!cachefile.exists()) { break; } suffix = "$" + index; index += 1; } entry.cachefile = cachefile.getCanonicalPath(); } else cachefile = new File(entry.cachefile); return new DataOutputStream(new BufferedOutputStream( new FileOutputStream(cachefile))); }
// in src/org/python/util/PyFilter.java
public void doFilter(ServletRequest request, ServletResponse response, FilterChain chain) throws IOException, ServletException { request.setAttribute("pyfilter", this); getFilter().doFilter(request, response, chain); }
// in src/org/python/util/PyFilter.java
private Filter getFilter() throws ServletException, IOException { if (cached == null || source.lastModified() > loadedMtime) { return loadFilter(); } return cached; }
// in src/org/python/util/PyFilter.java
private Filter loadFilter() throws ServletException, IOException { loadedMtime = source.lastModified(); cached = PyServlet.createInstance(interp, source, Filter.class); try { cached.init(config); } catch (PyException e) { throw new ServletException(e); } return cached; }
// in src/org/python/util/PythonObjectInputStream.java
protected Class<?> resolveClass(ObjectStreamClass v) throws IOException, ClassNotFoundException { String clsName = v.getName(); if (clsName.startsWith("org.python.proxies")) { int idx = clsName.lastIndexOf('$'); if (idx > 19) { clsName = clsName.substring(19, idx); } idx = clsName.indexOf('$'); if (idx >= 0) { String mod = clsName.substring(0, idx); clsName = clsName.substring(idx + 1); PyObject module = importModule(mod); PyType pycls = (PyType)module.__getattr__(clsName.intern()); return pycls.getProxyType(); } } try { return super.resolveClass(v); } catch (ClassNotFoundException exc) { PyObject m = importModule(clsName); Object cls = m.__tojava__(Class.class); if (cls != null && cls != Py.NoConversion) { return (Class<?>)cls; } throw exc; } }
// in src/org/python/util/PyServlet.java
Override public void service(ServletRequest req, ServletResponse res) throws ServletException, IOException { req.setAttribute("pyservlet", this); String spath = (String) req.getAttribute("javax.servlet.include.servlet_path"); if (spath == null) { spath = ((HttpServletRequest)req).getServletPath(); if (spath == null || spath.length() == 0) { // Servlet 2.1 puts the path of an extension-matched servlet in PathInfo. spath = ((HttpServletRequest)req).getPathInfo(); } } String rpath = getServletContext().getRealPath(spath); getServlet(rpath).service(req, res); }
// in src/org/python/util/PyServlet.java
private synchronized HttpServlet getServlet(String path) throws ServletException, IOException { CacheEntry entry = cache.get(path); if (entry == null || new File(path).lastModified() > entry.date) { return loadServlet(path); } return entry.servlet; }
// in src/org/python/util/PyServlet.java
private HttpServlet loadServlet(String path) throws ServletException, IOException { File file = new File(path); HttpServlet servlet = createInstance(interp, file, HttpServlet.class); try { servlet.init(getServletConfig()); } catch (PyException e) { throw new ServletException(e); } cache.put(path, new CacheEntry(servlet, file.lastModified())); return servlet; }
// in src/org/python/util/Generic.java
private void readObject(ObjectInputStream in) throws IOException, ClassNotFoundException { in.defaultReadObject(); keySet = map.keySet(); }
(Lib) IllegalStateException 8
              
// in src/org/python/indexer/Util.java
public static String moduleNameFor(String path) { File f = new File(path); if (f.isDirectory()) { throw new IllegalStateException("failed assertion: " + path); } String fname = f.getName(); if (fname.equals("__init__.py")) { return f.getParentFile().getName(); } return fname.substring(0, fname.lastIndexOf('.')); }
// in src/org/python/indexer/Scope.java
public String extendPathForParam(String name) { if (path.equals("")) { throw new IllegalStateException("Not inside a function"); } return path + "@" + name; }
// in src/org/python/expose/generate/Exposer.java
public void pushArgs() { if(types.length > 0) { throw new IllegalStateException("If the constuctor takes types as indicated by " + "passing their types to Instantiator, pushArgs must be overriden to put " + "those args on the stack before the call"); } }
// in src/org/python/antlr/PythonTokenSource.java
protected void push(int i) { if (sp >= MAX_INDENTS) { throw new IllegalStateException("stack overflow"); } sp++; indentStack[sp] = i; }
// in src/org/python/antlr/PythonTokenSource.java
protected int pop() { if (sp<0) { throw new IllegalStateException("stack underflow"); } int top = indentStack[sp]; sp--; return top; }
// in src/org/python/modules/sre/SRE_STATE.java
final int SRE_MATCH(int[] pattern, int pidx, int level) { /* check if string matches the given pattern. returns <0 for error, 0 for failure, and 1 for success */ int end = this.end; int ptr = this.ptr; int i, count; int chr; int lastmark, lastindex, mark_stack_base = 0; TRACE(pidx, ptr, "ENTER " + level); if (level > USE_RECURSION_LIMIT) return SRE_ERROR_RECURSION_LIMIT; if (pattern[pidx] == SRE_OP_INFO) { /* optimization info block */ /* args: <1=skip> <2=flags> <3=min> ... */ if (pattern[pidx+3] != 0 && (end - ptr) < pattern[pidx+3]) { return 0; } pidx += pattern[pidx+1] + 1; } for (;;) { switch (pattern[pidx++]) { case SRE_OP_MARK: /* set mark */ /* <MARK> <gid> */ TRACE(pidx, ptr, "MARK " + pattern[pidx]); i = pattern[pidx]; if ((i & 1) != 0) this.lastindex = i / 2 + 1; if (i > this.lastmark) this.lastmark = i; mark[i] = ptr; pidx++; break; case SRE_OP_LITERAL: /* match literal character */ /* <LITERAL> <code> */ TRACE(pidx, ptr, "LITERAL " + pattern[pidx]); if (ptr >= end || str[ptr] != pattern[pidx]) return 0; pidx++; ptr++; break; case SRE_OP_NOT_LITERAL: /* match anything that is not literal character */ /* args: <code> */ TRACE(pidx, ptr, "NOT_LITERAL " + pattern[pidx]); if (ptr >= end || str[ptr] == pattern[pidx]) return 0; pidx++; ptr++; break; case SRE_OP_SUCCESS: /* end of pattern */ TRACE(pidx, ptr, "SUCCESS"); this.ptr = ptr; return 1; case SRE_OP_AT: /* match at given position */ /* <AT> <code> */ TRACE(pidx, ptr, "AT " + pattern[pidx]); if (!SRE_AT(ptr, pattern[pidx])) return 0; pidx++; break; case SRE_OP_CATEGORY: /* match at given category */ /* <CATEGORY> <code> */ TRACE(pidx, ptr, "CATEGORY " + pattern[pidx]); if (ptr >= end || !sre_category(pattern[pidx], str[ptr])) return 0; pidx++; ptr++; break; case SRE_OP_ANY: /* match anything */ TRACE(pidx, ptr, "ANY"); if (ptr >= end || SRE_IS_LINEBREAK(str[ptr])) return 0; ptr++; break; case SRE_OP_ANY_ALL: /* match anything */ /* <ANY_ALL> */ TRACE(pidx, ptr, "ANY_ALL"); if (ptr >= end) return 0; ptr++; break; case SRE_OP_IN: /* match set member (or non_member) */ /* <IN> <skip> <set> */ TRACE(pidx, ptr, "IN"); if (ptr >= end || !SRE_CHARSET(pattern, pidx + 1, str[ptr])) return 0; pidx += pattern[pidx]; ptr++; break; case SRE_OP_LITERAL_IGNORE: TRACE(pidx, ptr, "LITERAL_IGNORE " + pattern[pidx]); if (ptr >= end || lower(str[ptr]) != lower(pattern[pidx])) return 0; pidx++; ptr++; break; case SRE_OP_NOT_LITERAL_IGNORE: TRACE(pidx, ptr, "NOT_LITERAL_IGNORE " + pattern[pidx]); if (ptr >= end || lower(str[ptr]) == lower(pattern[pidx])) return 0; pidx++; ptr++; break; case SRE_OP_IN_IGNORE: TRACE(pidx, ptr, "IN_IGNORE"); if (ptr >= end || !SRE_CHARSET(pattern, pidx + 1, lower(str[ptr]))) return 0; pidx += pattern[pidx]; ptr++; break; case SRE_OP_JUMP: case SRE_OP_INFO: /* jump forward */ /* <JUMP> <offset> */ TRACE(pidx, ptr, "JUMP " + pattern[pidx]); pidx += pattern[pidx]; break; case SRE_OP_BRANCH: /* try an alternate branch */ /* <BRANCH> <0=skip> code <JUMP> ... <NULL> */ // TRACE(pidx, ptr, "BRANCH"); lastmark = this.lastmark; lastindex = this.lastindex; if(this.repeat != null) { mark_stack_base = mark_save(0, lastmark); } for(; pattern[pidx] != 0; pidx += pattern[pidx]) { if(pattern[pidx + 1] == SRE_OP_LITERAL && (ptr >= end || str[ptr] != pattern[pidx + 2])) continue; if(pattern[pidx + 1] == SRE_OP_IN && (ptr >= end || !SRE_CHARSET(pattern, pidx + 3, str[ptr]))) continue; this.ptr = ptr; i = SRE_MATCH(pattern, pidx + 1, level + 1); if(i != 0) return i; if(this.repeat != null) { mark_restore(0, lastmark, mark_stack_base); } LASTMARK_RESTORE(lastmark, lastindex); } return 0; case SRE_OP_REPEAT_ONE: /* match repeated sequence (maximizing regexp) */ /* this operator only works if the repeated item is exactly one character wide, and we're not already collecting backtracking points. for other cases, use the MAX_REPEAT operator */ /* <REPEAT_ONE> <skip> <1=min> <2=max> item <SUCCESS> tail */ int mincount = pattern[pidx+1]; TRACE(pidx, ptr, "REPEAT_ONE " + mincount + " " + pattern[pidx+2]); if (ptr + mincount > end) return 0; /* cannot match */ this.ptr = ptr; count = SRE_COUNT(pattern, pidx + 3, pattern[pidx+2], level + 1); if (count < 0) return count; ptr += count; /* when we arrive here, count contains the number of matches, and ptr points to the tail of the target string. check if the rest of the pattern matches, and backtrack if not. */ if (count < mincount) return 0; if (pattern[pidx + pattern[pidx]] == SRE_OP_SUCCESS) { /* tail is empty. we're finished */ this.ptr = ptr; return 1; } lastmark = this.lastmark; lastindex = this.lastindex; if (pattern[pidx + pattern[pidx]] == SRE_OP_LITERAL) { /* tail starts with a literal. skip positions where the rest of the pattern cannot possibly match */ chr = pattern[pidx + pattern[pidx]+1]; for (;;) { while (count >= mincount && (ptr >= end || str[ptr] != chr)) { ptr--; count--; } if (count < mincount) break; this.ptr = ptr; i = SRE_MATCH(pattern, pidx + pattern[pidx], level + 1); if (i != 0) return 1; ptr--; count--; LASTMARK_RESTORE(lastmark, lastindex); } } else { /* general case */ lastmark = this.lastmark; while (count >= mincount) { this.ptr = ptr; i = SRE_MATCH(pattern, pidx + pattern[pidx], level + 1); if (i != 0) return i; ptr--; count--; LASTMARK_RESTORE(lastmark, lastindex); } } return 0; case SRE_OP_MIN_REPEAT_ONE: /* match repeated sequence (minimizing regexp) */ /* this operator only works if the repeated item is exactly one character wide, and we're not already collecting backtracking points. for other cases, use the MIN_REPEAT operator */ /* <MIN_REPEAT_ONE> <skip> <1=min> <2=max> item <SUCCESS> tail */ TRACE(pidx, ptr, "MIN_REPEAT_ONE"); if (ptr + pattern[pidx+1] > end) return 0; /* cannot match */ this.ptr = ptr; if (pattern[pidx+1] == 0) count = 0; else { count = SRE_COUNT(pattern, pidx + 3, pattern[pidx+1], level + 1); if (count < 0) return count; /* exception */ if (count < pattern[pidx+1]) return 0; /* did not match minimum number of times */ ptr += count; /* advance past minimum matches of repeat */ } if (pattern[pidx + pattern[pidx]] == SRE_OP_SUCCESS) { /* tail is empty. we're finished */ this.ptr = ptr; return 1; } else { /* general case */ boolean matchmax = (pattern[pidx + 2] == 65535); int c; lastmark = this.lastmark; lastindex = this.lastindex; while (matchmax || count <= pattern[pidx + 2]) { this.ptr = ptr; i = SRE_MATCH(pattern, pidx + pattern[pidx], level + 1); if (i != 0) return i; this.ptr = ptr; c = SRE_COUNT(pattern, pidx+3, 1, level+1); if (c < 0) return c; if (c == 0) break; if(c != 1){ throw new IllegalStateException("c should be 1!"); } ptr++; count++; LASTMARK_RESTORE(lastmark, lastindex); } } return 0; case SRE_OP_REPEAT: /* create repeat context. all the hard work is done by the UNTIL operator (MAX_UNTIL, MIN_UNTIL) */ /* <REPEAT> <skip> <1=min> <2=max> item <UNTIL> tail */ TRACE(pidx, ptr, "REPEAT " + pattern[pidx+1] + " " + pattern[pidx+2]); SRE_REPEAT rep = new SRE_REPEAT(repeat); rep.count = -1; rep.pidx = pidx; repeat = rep; this.ptr = ptr; i = SRE_MATCH(pattern, pidx + pattern[pidx], level + 1); repeat = rep.prev; return i; case SRE_OP_MAX_UNTIL: /* maximizing repeat */ /* <REPEAT> <skip> <1=min> <2=max> item <MAX_UNTIL> tail */ /* FIXME: we probably need to deal with zero-width matches in here... */ SRE_REPEAT rp = this.repeat; if (rp == null) return SRE_ERROR_STATE; this.ptr = ptr; count = rp.count + 1; TRACE(pidx, ptr, "MAX_UNTIL " + count); if (count < pattern[rp.pidx + 1]) { /* not enough matches */ rp.count = count; i = SRE_MATCH(pattern, rp.pidx + 3, level + 1); if (i != 0) return i; rp.count = count - 1; this.ptr = ptr; return 0; } if (count < pattern[rp.pidx+2] || pattern[rp.pidx+2] == 65535) { /* we may have enough matches, but if we can match another item, do so */ rp.count = count; lastmark = this.lastmark; lastindex = this.lastindex; mark_stack_base = mark_save(0, lastmark); /* RECURSIVE */ i = SRE_MATCH(pattern, rp.pidx + 3, level + 1); if (i != 0) return i; mark_restore(0, lastmark, mark_stack_base); LASTMARK_RESTORE(lastmark, lastindex); rp.count = count - 1; this.ptr = ptr; } /* cannot match more repeated items here. make sure the tail matches */ this.repeat = rp.prev; /* RECURSIVE */ i = SRE_MATCH(pattern, pidx, level + 1); if (i != 0) return i; this.repeat = rp; this.ptr = ptr; return 0; case SRE_OP_MIN_UNTIL: /* minimizing repeat */ /* <REPEAT> <skip> <1=min> <2=max> item <MIN_UNTIL> tail */ rp = this.repeat; if (rp == null) return SRE_ERROR_STATE; this.ptr = ptr; count = rp.count + 1; TRACE(pidx, ptr, "MIN_UNTIL " + count + " " + rp.pidx); if (count < pattern[rp.pidx + 1]) { /* not enough matches */ rp.count = count; /* RECURSIVE */ i = SRE_MATCH(pattern, rp.pidx + 3, level + 1); if (i != 0) return i; rp.count = count-1; this.ptr = ptr; return 0; } lastmark = this.lastmark; lastindex = this.lastindex; /* see if the tail matches */ this.repeat = rp.prev; i = SRE_MATCH(pattern, pidx, level + 1); if (i != 0) return i; this.ptr = ptr; this.repeat = rp; if (count >= pattern[rp.pidx+2] && pattern[rp.pidx+2] != 65535) return 0; LASTMARK_RESTORE(lastmark, lastindex); rp.count = count; /* RECURSIVE */ i = SRE_MATCH(pattern, rp.pidx + 3, level + 1); if (i != 0) return i; rp.count = count - 1; this.ptr = ptr; return 0; case SRE_OP_GROUPREF: /* match backreference */ i = pattern[pidx]; TRACE(pidx, ptr, "GROUPREF " + i); int p = mark[i+i]; int e = mark[i+i+1]; if (p == -1 || e == -1 || e < p) return 0; while (p < e) { if (ptr >= end || str[ptr] != str[p]) return 0; p++; ptr++; } pidx++; break; case SRE_OP_GROUPREF_IGNORE: /* match backreference */ i = pattern[pidx]; TRACE(pidx, ptr, "GROUPREF_IGNORE " + i); p = mark[i+i]; e = mark[i+i+1]; if (p == -1 || e == -1 || e < p) return 0; while (p < e) { if (ptr >= end || lower(str[ptr]) != lower(str[p])) return 0; p++; ptr++; } pidx++; break; case SRE_OP_GROUPREF_EXISTS: i = pattern[pidx]; TRACE(pidx, ptr, "GROUPREF_EXISTS " + i); p = mark[i+i]; e = mark[i+i+1]; if (p == -1 || e == -1 || e < p) { pidx += pattern[pidx + 1]; break; } pidx += 2; break; case SRE_OP_ASSERT: /* assert subpattern */ /* args: <skip> <back> <pattern> */ TRACE(pidx, ptr, "ASSERT " + pattern[pidx+1]); this.ptr = ptr - pattern[pidx + 1]; if (this.ptr < this.beginning) return 0; i = SRE_MATCH(pattern, pidx + 2, level + 1); if (i <= 0) return i; pidx += pattern[pidx]; break; case SRE_OP_ASSERT_NOT: /* assert not subpattern */ /* args: <skip> <pattern> */ TRACE(pidx, ptr, "ASSERT_NOT " + pattern[pidx]); this.ptr = ptr - pattern[pidx + 1]; if (this.ptr >= this.beginning) { i = SRE_MATCH(pattern, pidx + 2, level + 1); if (i < 0) return i; if (i != 0) return 0; } pidx += pattern[pidx]; break; case SRE_OP_FAILURE: /* immediate failure */ TRACE(pidx, ptr, "FAILURE"); return 0; default: TRACE(pidx, ptr, "UNKNOWN " + pattern[pidx-1]); return SRE_ERROR_ILLEGAL; } } /* can't end up here */ /* return SRE_ERROR_ILLEGAL; -- see python-dev discussion */ }
// in src/org/python/core/AbstractArray.java
public void remove(int index) { if (index >= 0 && index < this.size) { this.size = this.size - 1; if (index < this.size) { Object base = getArray(); System.arraycopy(base, index + 1, base, index, this.size - index); clearRangeInternal(this.size, this.size); } } else { if (this.size == 0) { throw new IllegalStateException("Cannot remove data from an empty array"); } throw new IndexOutOfBoundsException("Index must be between 0 and " + (this.size - 1) + ", but was " + index); } }
// in src/org/python/core/CodeFlag.java
public CodeFlag next() { if (hasNext()) try { return next; } finally { next = null; } throw new IllegalStateException(); }
0 0
(Domain) InvalidExposingException 6
              
// in src/org/python/expose/generate/MethodExposer.java
protected void throwInvalid(String msg) { throw new InvalidExposingException(msg + "[method=" + onType.getClassName() + "." + methodName + "]"); }
// in src/org/python/expose/generate/ExposedTypeProcessor.java
private void throwInvalid(String msg) { throw new InvalidExposingException(msg + "[class=" + onType.getClassName() + "]"); }
// in src/org/python/expose/generate/TypeExposer.java
private void throwDupe(String exposedName) { throw new InvalidExposingException("Only one item may be exposed on a type with a given name[name=" + exposedName + ", class=" + onType.getClassName() + "]"); }
// in src/org/python/expose/generate/DescriptorExposer.java
private void error(String reason) { throw new InvalidExposingException(reason + "[class=" + onType.getClassName() + ", name=" + name + "]"); }
// in src/org/python/expose/generate/NewExposer.java
private void throwInvalid(String msg) { throw new InvalidExposingException(msg + "[method=" + onType.getClassName() + "." + name + "]"); }
// in src/org/python/expose/generate/ClassMethodExposer.java
private static Type[] getArgs(Type onType, String methodName, String desc) { Type[] args = Type.getArgumentTypes(desc); boolean needsThreadState = needsThreadState(args); int offset = needsThreadState ? 1 : 0; if (args.length == offset || !args[offset].equals(PYTYPE)) { String msg = String.format("ExposedClassMethod's first argument %smust be " + "PyType[method=%s.%s]", needsThreadState ? "(following ThreadState) " : "", onType.getClassName(), methodName); throw new InvalidExposingException(msg); } // Remove PyType from the exposed __call__'s args, it'll be already bound as self Type[] filledInArgs = new Type[args.length - 1]; if (needsThreadState) { // ThreadState precedes PyType filledInArgs[0] = args[0]; System.arraycopy(args, 2, filledInArgs, 1, filledInArgs.length - 1); } else { System.arraycopy(args, 1, filledInArgs, 0, filledInArgs.length); } return filledInArgs; }
0 0
(Lib) IndexOutOfBoundsException 5
              
// in src/org/python/core/FilelikeInputStream.java
public int read(byte b[], int off, int len) throws IOException { if(b == null) { throw new NullPointerException(); } else if((off < 0) || (off > b.length) || (len < 0) || ((off + len) > b.length) || ((off + len) < 0)) { throw new IndexOutOfBoundsException(); } else if(len == 0) { return 0; } String result = ((PyString) filelike.__getattr__("read") .__call__(new PyInteger(len))).getString(); if(result.length() == 0) { return -1; } System.arraycopy(StringUtil.toBytes(result), 0, b, off, result.length()); return result.length(); }
// in src/org/python/core/PyTuple.java
public List subList(int fromIndex, int toIndex) { if (fromIndex < 0 || toIndex > size()) { throw new IndexOutOfBoundsException(); } else if (fromIndex > toIndex) { throw new IllegalArgumentException(); } PyObject elements[] = new PyObject[toIndex - fromIndex]; for (int i = 0, j = fromIndex; i < elements.length; i++, j++) { elements[i] = array[j]; } return new PyTuple(elements); }
// in src/org/python/core/AbstractArray.java
public void remove(int index) { if (index >= 0 && index < this.size) { this.size = this.size - 1; if (index < this.size) { Object base = getArray(); System.arraycopy(base, index + 1, base, index, this.size - index); clearRangeInternal(this.size, this.size); } } else { if (this.size == 0) { throw new IllegalStateException("Cannot remove data from an empty array"); } throw new IndexOutOfBoundsException("Index must be between 0 and " + (this.size - 1) + ", but was " + index); } }
// in src/org/python/core/AbstractArray.java
public void remove(int start, int stop) { if (start >= 0 && stop <= this.size && start <= stop) { Object base = getArray(); int nRemove = stop - start; if (nRemove == 0) { return; } System.arraycopy(base, stop, base, start, this.size - stop); this.size = this.size - nRemove; clearRangeInternal(this.size, this.size + nRemove); setArray(base); return; } throw new IndexOutOfBoundsException("start and stop must follow: 0 <= start <= stop <= " + this.size + ", but found start= " + start + " and stop=" + stop); }
// in src/org/python/core/io/TextIOInputStream.java
Override public int read(byte[] b, int off, int len) throws IOException { if (b == null) { throw new NullPointerException(); } else if ((off < 0) || (off > b.length) || (len < 0) || ((off + len) > b.length) || ((off + len) < 0)) { throw new IndexOutOfBoundsException(); } else if (len == 0) { return 0; } String result = textIO.read(len); len = result.length(); for (int i = 0; i < len; i++) { b[off + i] = (byte)result.charAt(i); } return len == 0 ? -1 : len; }
0 0
(Domain) ConversionException 4
              
// in src/org/python/core/PyObject.java
public String asString(int index) throws ConversionException { throw new ConversionException(index); }
// in src/org/python/core/PyObject.java
public String asName(int index) throws ConversionException { throw new ConversionException(index); }
// in src/org/python/core/PyObject.java
public int asInt(int index) throws ConversionException { throw new ConversionException(index); }
// in src/org/python/core/PyObject.java
public long asLong(int index) throws ConversionException { throw new ConversionException(index); }
0 8
              
// in src/org/python/modules/jffi/ScalarCData.java
Override public long asLong(int index) throws ConversionException { return getValue().asLong(index); }
// in src/org/python/core/PyObject.java
public String asString(int index) throws ConversionException { throw new ConversionException(index); }
// in src/org/python/core/PyObject.java
public String asStringOrNull(int index) throws ConversionException { return asString(index); }
// in src/org/python/core/PyObject.java
public String asName(int index) throws ConversionException { throw new ConversionException(index); }
// in src/org/python/core/PyObject.java
public int asInt(int index) throws ConversionException { throw new ConversionException(index); }
// in src/org/python/core/PyObject.java
public long asLong(int index) throws ConversionException { throw new ConversionException(index); }
// in src/org/python/core/PyString.java
Override public String asString(int index) throws PyObject.ConversionException { return getString(); }
// in src/org/python/core/PyString.java
Override public String asName(int index) throws PyObject.ConversionException { return internedString(); }
(Lib) ArrayIndexOutOfBoundsException 3
              
// in src/org/python/core/AbstractArray.java
protected void clearRange(int start, int stop) { if (start < stop && start >= 0 && stop <= this.size) { clearRangeInternal(start, stop); } else { if (start == stop && start >= 0 && stop <= this.size) { return; } throw new ArrayIndexOutOfBoundsException("start and stop must follow: 0 <= start <= stop <= " + (this.size) + ", but found start= " + start + " and stop=" + stop); } }
// in src/org/python/core/AbstractArray.java
protected void makeInsertSpace(int index, int length) { this.modCountIncr = 0; if (index >= 0 && index <= this.size) { int toCopy = this.size - index; this.size = this.size + length; // First increase array size if needed if (this.size > this.capacity) { ensureCapacity(this.size); } if (index < this.size - 1) { this.modCountIncr = 1; Object array = getArray(); System.arraycopy(array, index, array, index + length, toCopy); } } else { throw new ArrayIndexOutOfBoundsException("Index must be between 0 and " + this.size + ", but was " + index); } }
// in src/org/python/core/AbstractArray.java
public void replaceSubArray(int thisStart, int thisStop, Object srcArray, int srcStart, int srcStop) { this.modCountIncr = 0; if (!srcArray.getClass().isArray()) { throw new IllegalArgumentException("'array' must be an array type"); } int replacedLen = thisStop - thisStart; if (thisStart < 0 || replacedLen < 0 || thisStop > this.size) { String message = null; if (thisStart < 0) { message = "thisStart < 0 (thisStart = " + thisStart + ")"; } else if (replacedLen < 0) { message = "thisStart > thistStop (thisStart = " + thisStart + ", thisStop = " + thisStop + ")"; } else if (thisStop > this.size) { message = "thisStop > size (thisStop = " + thisStop + ", size = " + this.size + ")"; } else { throw new InternalError("Incorrect validation logic"); } throw new ArrayIndexOutOfBoundsException(message); } int srcLen = Array.getLength(srcArray); int replacementLen = srcStop - srcStart; if (srcStart < 0 || replacementLen < 0 || srcStop > srcLen) { String message = null; if (srcStart < 0) { message = "srcStart < 0 (srcStart = " + srcStart +")"; } else if (replacementLen < 0) { message = "srcStart > srcStop (srcStart = " + srcStart + ", srcStop = " + srcStop + ")"; } else if (srcStop > srcLen) { message = "srcStop > srcArray length (srcStop = " + srcStop + ", srcArray length = " +srcLen + ")"; } else { throw new InternalError("Incorrect validation logic"); } throw new IllegalArgumentException("start, stop and array must follow:\n\t" + "0 <= start <= stop <= array length\nBut found\n\t" + message); } int lengthChange = replacementLen - replacedLen; // Adjust array size if needed. if (lengthChange < 0) { remove(thisStop + lengthChange, thisStop); } else if (lengthChange > 0) { makeInsertSpace(thisStop, lengthChange); } try { this.modCountIncr = 1; System.arraycopy(srcArray, srcStart, getArray(), thisStart, replacementLen); } catch (ArrayStoreException e) { throw new IllegalArgumentException("'ofArrayType' must be compatible with existing array type of " + getArray().getClass().getName() + "\tsee java.lang.Class.getName()."); } }
0 0
(Domain) IndexingException 3
              
// in src/org/python/indexer/Indexer.java
public void handleException(String msg, Throwable cause) { // Stack overflows are still fairly common due to cyclic // types, and they take up an awful lot of log space, so we // don't log the whole trace by default. if (cause instanceof StackOverflowError) { logger.log(Level.WARNING, msg, cause); return; } if (aggressiveAssertionsEnabled()) { if (msg != null) { throw new IndexingException(msg, cause); } throw new IndexingException(cause); } if (msg == null) msg = "<null msg>"; if (cause == null) cause = new Exception(); logger.log(Level.WARNING, msg, cause); }
// in src/org/python/indexer/Indexer.java
public void reportFailedAssertion(String msg) { if (aggressiveAssertionsEnabled()) { throw new IndexingException(msg, new Exception()); // capture stack } // Need more configuration control here. // Currently getting a hillion jillion of these in large clients. if (false) { logger.log(Level.WARNING, msg); } }
0 0
(Lib) NoSuchMethodException 3
              
// in src/org/python/jsr223/PyScriptEngine.java
public Object invokeMethod(Object thiz, String name, Object... args) throws ScriptException, NoSuchMethodException { try { interp.setLocals(new PyScriptEngineScope(this, context)); if (!(thiz instanceof PyObject)) { thiz = Py.java2py(thiz); } PyObject method = ((PyObject) thiz).__findattr__(name); if (method == null) { throw new NoSuchMethodException(name); } //return method.__call__(Py.javas2pys(args)).__tojava__(Object.class); PyObject result; if(args != null) { result = method.__call__(Py.javas2pys(args)); } else { result = method.__call__(); } return result.__tojava__(Object.class); } catch (PyException pye) { throw scriptException(pye); } }
// in src/org/python/jsr223/PyScriptEngine.java
public Object invokeFunction(String name, Object... args) throws ScriptException, NoSuchMethodException { try { interp.setLocals(new PyScriptEngineScope(this, context)); PyObject function = interp.get(name); if (function == null) { throw new NoSuchMethodException(name); } return function.__call__(Py.javas2pys(args)).__tojava__(Object.class); } catch (PyException pye) { throw scriptException(pye); } }
// in src/org/python/jsr223/PyScriptEngine.java
public Object invoke(Object proxy, Method method, Object[] args) throws Throwable { try { interp.setLocals(new PyScriptEngineScope(PyScriptEngine.this, context)); PyObject pyMethod = thiz.__findattr__(method.getName()); if (pyMethod == null) throw new NoSuchMethodException(method.getName()); PyObject result = pyMethod.__call__(Py.javas2pys(args)); return result.__tojava__(Object.class); } catch (PyException pye) { throw scriptException(pye); } }
0 4
              
// in src/org/python/jsr223/PyScriptEngine.java
public Object invokeMethod(Object thiz, String name, Object... args) throws ScriptException, NoSuchMethodException { try { interp.setLocals(new PyScriptEngineScope(this, context)); if (!(thiz instanceof PyObject)) { thiz = Py.java2py(thiz); } PyObject method = ((PyObject) thiz).__findattr__(name); if (method == null) { throw new NoSuchMethodException(name); } //return method.__call__(Py.javas2pys(args)).__tojava__(Object.class); PyObject result; if(args != null) { result = method.__call__(Py.javas2pys(args)); } else { result = method.__call__(); } return result.__tojava__(Object.class); } catch (PyException pye) { throw scriptException(pye); } }
// in src/org/python/jsr223/PyScriptEngine.java
public Object invokeFunction(String name, Object... args) throws ScriptException, NoSuchMethodException { try { interp.setLocals(new PyScriptEngineScope(this, context)); PyObject function = interp.get(name); if (function == null) { throw new NoSuchMethodException(name); } return function.__call__(Py.javas2pys(args)).__tojava__(Object.class); } catch (PyException pye) { throw scriptException(pye); } }
// in src/org/python/core/CodeLoader.java
public static PyCode loadCode(Class<?> cls, String name, String filename) throws SecurityException, NoSuchMethodException, IllegalArgumentException, IllegalAccessException, InvocationTargetException { Method getBootstrap = cls.getMethod(GET_BOOTSTRAP_METHOD_NAME); CodeBootstrap bootstrap = (CodeBootstrap) getBootstrap.invoke(null); return loadCode(bootstrap, name, filename); }
// in src/org/python/core/CodeLoader.java
public static PyCode loadCode(Class<?> cls) throws SecurityException, IllegalArgumentException, NoSuchMethodException, IllegalAccessException, InvocationTargetException { return loadCode(cls, null, null); }
(Domain) QueueClosedException 3
              
// in src/com/ziclix/python/sql/util/Queue.java
public synchronized void enqueue(Object element) throws InterruptedException { if (closed) { throw new QueueClosedException(); } this.queue.addLast(element); this.notify(); /* * Block while the capacity of the queue has been breached. */ while ((this.capacity > 0) && (this.queue.size() >= this.capacity)) { this.wait(); if (closed) { throw new QueueClosedException(); } } }
// in src/com/ziclix/python/sql/util/Queue.java
public synchronized Object dequeue() throws InterruptedException { while (this.queue.size() <= 0) { this.wait(); if (closed) { throw new QueueClosedException(); } } Object object = this.queue.removeFirst(); // if space exists, notify the other threads if (this.queue.size() < this.threshold) { this.notify(); } return object; }
0 0
(Lib) ClassNotFoundException 2
              
// in src/org/python/core/SyspathJavaLoader.java
Override protected Class<?> findClass(String name) throws ClassNotFoundException { PySystemState sys = Py.getSystemState(); ClassLoader sysClassLoader = sys.getClassLoader(); if (sysClassLoader != null) { // sys.classLoader overrides this class loader! return sysClassLoader.loadClass(name); } // Search the sys.path for a .class file matching the named class. PyList path = sys.path; for (int i = 0; i < path.__len__(); i++) { byte[] buffer; PyObject entry = replacePathItem(sys, i, path); if (entry instanceof SyspathArchive) { SyspathArchive archive = (SyspathArchive)entry; buffer = getBytesFromArchive(archive, name); } else { if (!(entry instanceof PyUnicode)) { entry = entry.__str__(); } String dir = entry.toString(); buffer = getBytesFromDir(dir, name); } if (buffer != null) { definePackageForClass(name); return defineClass(name, buffer, 0, buffer.length); } } // couldn't find the .class file on sys.path throw new ClassNotFoundException(name); }
// in src/org/python/core/BytecodeLoader.java
Override protected Class<?> loadClass(String name, boolean resolve) throws ClassNotFoundException { Class<?> c = findLoadedClass(name); if (c != null) { return c; } for (ClassLoader loader : parents) { try { return loader.loadClass(name); } catch (ClassNotFoundException cnfe) {} } // couldn't find the .class file on sys.path throw new ClassNotFoundException(name); }
0 10
              
// in src/org/python/core/SyspathJavaLoader.java
Override protected Class<?> findClass(String name) throws ClassNotFoundException { PySystemState sys = Py.getSystemState(); ClassLoader sysClassLoader = sys.getClassLoader(); if (sysClassLoader != null) { // sys.classLoader overrides this class loader! return sysClassLoader.loadClass(name); } // Search the sys.path for a .class file matching the named class. PyList path = sys.path; for (int i = 0; i < path.__len__(); i++) { byte[] buffer; PyObject entry = replacePathItem(sys, i, path); if (entry instanceof SyspathArchive) { SyspathArchive archive = (SyspathArchive)entry; buffer = getBytesFromArchive(archive, name); } else { if (!(entry instanceof PyUnicode)) { entry = entry.__str__(); } String dir = entry.toString(); buffer = getBytesFromDir(dir, name); } if (buffer != null) { definePackageForClass(name); return defineClass(name, buffer, 0, buffer.length); } } // couldn't find the .class file on sys.path throw new ClassNotFoundException(name); }
// in src/org/python/core/BytecodeLoader.java
Override protected Class<?> loadClass(String name, boolean resolve) throws ClassNotFoundException { Class<?> c = findLoadedClass(name); if (c != null) { return c; } for (ClassLoader loader : parents) { try { return loader.loadClass(name); } catch (ClassNotFoundException cnfe) {} } // couldn't find the .class file on sys.path throw new ClassNotFoundException(name); }
// in src/org/python/core/PyInstance.java
private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException { in.defaultReadObject(); String module = in.readUTF(); String name = in.readUTF(); /* Check for types and missing members here */ //System.out.println("module: "+module+", "+name); PyObject mod = imp.importName(module.intern(), false); PyClass pyc = (PyClass)mod.__getattr__(name.intern()); instclass = pyc; }
// in src/org/python/core/PyJavaType.java
private static <T> T cloneX(T x) throws IOException, ClassNotFoundException { ByteArrayOutputStream bout = new ByteArrayOutputStream(); CloneOutput cout = new CloneOutput(bout); cout.writeObject(x); byte[] bytes = bout.toByteArray(); ByteArrayInputStream bin = new ByteArrayInputStream(bytes); CloneInput cin = new CloneInput(bin, cout); @SuppressWarnings("unchecked") // thanks to Bas de Bakker for the tip! T clone = (T) cin.readObject(); return clone; }
// in src/org/python/core/PyJavaType.java
Override protected Class<?> resolveClass(ObjectStreamClass osc) throws IOException, ClassNotFoundException { Class<?> c = output.classQueue.poll(); String expected = osc.getName(); String found = (c == null) ? null : c.getName(); if (!expected.equals(found)) { throw new InvalidClassException("Classes desynchronized: " + "found " + found + " when expecting " + expected); } return c; }
// in src/org/python/core/PyJavaType.java
Override protected Class<?> resolveProxyClass(String[] interfaceNames) throws IOException, ClassNotFoundException { return output.classQueue.poll(); }
// in src/org/python/core/Py.java
private static Class<?> findClassInternal(String name, String reason) throws ClassNotFoundException { ClassLoader classLoader = Py.getSystemState().getClassLoader(); if (classLoader != null) { if (reason != null) { writeDebug("import", "trying " + name + " as " + reason + " in sys.classLoader"); } return loadAndInitClass(name, classLoader); } if (!syspathJavaLoaderRestricted) { try { classLoader = imp.getSyspathJavaLoader(); if (classLoader != null && reason != null) { writeDebug("import", "trying " + name + " as " + reason + " in SysPathJavaLoader"); } } catch (SecurityException e) { syspathJavaLoaderRestricted = true; } } if (syspathJavaLoaderRestricted) { classLoader = imp.getParentClassLoader(); if (classLoader != null && reason != null) { writeDebug("import", "trying " + name + " as " + reason + " in Jython's parent class loader"); } } if (classLoader != null) { try { return loadAndInitClass(name, classLoader); } catch (ClassNotFoundException cnfe) { // let the default classloader try // XXX: by trying another classloader that may not be on a // parent/child relationship with the Jython's parent // classsloader we are risking some nasty class loading // problems (such as having two incompatible copies for // the same class that is itself a dependency of two // classes loaded from these two different class loaders) } } if (reason != null) { writeDebug("import", "trying " + name + " as " + reason + " in context class loader, for backwards compatibility"); } return loadAndInitClass(name, Thread.currentThread().getContextClassLoader()); }
// in src/org/python/core/Py.java
private static Class<?> loadAndInitClass(String name, ClassLoader loader) throws ClassNotFoundException { return Class.forName(name, true, loader); }
// in src/org/python/util/PythonObjectInputStream.java
protected Class<?> resolveClass(ObjectStreamClass v) throws IOException, ClassNotFoundException { String clsName = v.getName(); if (clsName.startsWith("org.python.proxies")) { int idx = clsName.lastIndexOf('$'); if (idx > 19) { clsName = clsName.substring(19, idx); } idx = clsName.indexOf('$'); if (idx >= 0) { String mod = clsName.substring(0, idx); clsName = clsName.substring(idx + 1); PyObject module = importModule(mod); PyType pycls = (PyType)module.__getattr__(clsName.intern()); return pycls.getProxyType(); } } try { return super.resolveClass(v); } catch (ClassNotFoundException exc) { PyObject m = importModule(clsName); Object cls = m.__tojava__(Class.class); if (cls != null && cls != Py.NoConversion) { return (Class<?>)cls; } throw exc; } }
// in src/org/python/util/Generic.java
private void readObject(ObjectInputStream in) throws IOException, ClassNotFoundException { in.defaultReadObject(); keySet = map.keySet(); }
(Lib) InternalError 2
              
// in src/org/python/core/AbstractArray.java
public void replaceSubArray(int thisStart, int thisStop, Object srcArray, int srcStart, int srcStop) { this.modCountIncr = 0; if (!srcArray.getClass().isArray()) { throw new IllegalArgumentException("'array' must be an array type"); } int replacedLen = thisStop - thisStart; if (thisStart < 0 || replacedLen < 0 || thisStop > this.size) { String message = null; if (thisStart < 0) { message = "thisStart < 0 (thisStart = " + thisStart + ")"; } else if (replacedLen < 0) { message = "thisStart > thistStop (thisStart = " + thisStart + ", thisStop = " + thisStop + ")"; } else if (thisStop > this.size) { message = "thisStop > size (thisStop = " + thisStop + ", size = " + this.size + ")"; } else { throw new InternalError("Incorrect validation logic"); } throw new ArrayIndexOutOfBoundsException(message); } int srcLen = Array.getLength(srcArray); int replacementLen = srcStop - srcStart; if (srcStart < 0 || replacementLen < 0 || srcStop > srcLen) { String message = null; if (srcStart < 0) { message = "srcStart < 0 (srcStart = " + srcStart +")"; } else if (replacementLen < 0) { message = "srcStart > srcStop (srcStart = " + srcStart + ", srcStop = " + srcStop + ")"; } else if (srcStop > srcLen) { message = "srcStop > srcArray length (srcStop = " + srcStop + ", srcArray length = " +srcLen + ")"; } else { throw new InternalError("Incorrect validation logic"); } throw new IllegalArgumentException("start, stop and array must follow:\n\t" + "0 <= start <= stop <= array length\nBut found\n\t" + message); } int lengthChange = replacementLen - replacedLen; // Adjust array size if needed. if (lengthChange < 0) { remove(thisStop + lengthChange, thisStop); } else if (lengthChange > 0) { makeInsertSpace(thisStop, lengthChange); } try { this.modCountIncr = 1; System.arraycopy(srcArray, srcStart, getArray(), thisStart, replacementLen); } catch (ArrayStoreException e) { throw new IllegalArgumentException("'ofArrayType' must be compatible with existing array type of " + getArray().getClass().getName() + "\tsee java.lang.Class.getName()."); } }
0 0
(Lib) MismatchedTokenException 2
              
// in src/org/python/antlr/FailFastHandler.java
public boolean mismatch(BaseRecognizer br, IntStream input, int ttype, BitSet follow) throws RecognitionException { throw new MismatchedTokenException(ttype, input); }
// in src/org/python/antlr/FailFastHandler.java
public Object recoverFromMismatchedToken(BaseRecognizer br, IntStream input, int ttype, BitSet follow) throws RecognitionException { throw new MismatchedTokenException(ttype, input); }
0 0
(Lib) NullPointerException 2
              
// in src/org/python/core/FilelikeInputStream.java
public int read(byte b[], int off, int len) throws IOException { if(b == null) { throw new NullPointerException(); } else if((off < 0) || (off > b.length) || (len < 0) || ((off + len) > b.length) || ((off + len) < 0)) { throw new IndexOutOfBoundsException(); } else if(len == 0) { return 0; } String result = ((PyString) filelike.__getattr__("read") .__call__(new PyInteger(len))).getString(); if(result.length() == 0) { return -1; } System.arraycopy(StringUtil.toBytes(result), 0, b, off, result.length()); return result.length(); }
// in src/org/python/core/io/TextIOInputStream.java
Override public int read(byte[] b, int off, int len) throws IOException { if (b == null) { throw new NullPointerException(); } else if ((off < 0) || (off > b.length) || (len < 0) || ((off + len) > b.length) || ((off + len) < 0)) { throw new IndexOutOfBoundsException(); } else if (len == 0) { return 0; } String result = textIO.read(len); len = result.length(); for (int i = 0; i < len; i++) { b[off + i] = (byte)result.charAt(i); } return len == 0 ? -1 : len; }
0 0
(Lib) Error 1
              
// in src/org/python/util/InteractiveInterpreter.java
private void doBreak() { throw new Error("Python interrupt"); //Thread.currentThread().interrupt(); }
0 0
(Lib) Exception 1
              
// in src/org/python/compiler/CodeCompiler.java
Override protected Object unhandled_node(PythonTree node) throws Exception { throw new Exception("Unhandled node " + node); }
0 498
              
// in src/org/python/indexer/AstConverter.java
private List<NExceptHandler> convertListExceptHandler(List<excepthandler> in) throws Exception { List<NExceptHandler> out = new ArrayList<NExceptHandler>(in == null ? 0 : in.size()); if (in != null) { for (excepthandler e : in) { @SuppressWarnings("unchecked") NExceptHandler nxh = (NExceptHandler)e.accept(this); if (nxh != null) { out.add(nxh); } } } return out; }
// in src/org/python/indexer/AstConverter.java
private List<NNode> convertListExpr(List<expr> in) throws Exception { List<NNode> out = new ArrayList<NNode>(in == null ? 0 : in.size()); if (in != null) { for (expr e : in) { @SuppressWarnings("unchecked") NNode nx = (NNode)e.accept(this); if (nx != null) { out.add(nx); } } } return out; }
// in src/org/python/indexer/AstConverter.java
private List<NName> convertListName(List<Name> in) throws Exception { List<NName> out = new ArrayList<NName>(in == null ? 0 : in.size()); if (in != null) { for (expr e : in) { @SuppressWarnings("unchecked") NName nn = (NName)e.accept(this); if (nn != null) { out.add(nn); } } } return out; }
// in src/org/python/indexer/AstConverter.java
private NQname convertQname(List<Name> in) throws Exception { if (in == null) { return null; } // This would be less ugly if we generated Qname nodes in the antlr ast. NQname out = null; int end = -1; for (int i = in.size() - 1; i >= 0; i--) { Name n = in.get(i); if (end == -1) { end = n.getCharStopIndex(); } @SuppressWarnings("unchecked") NName nn = (NName)n.accept(this); out = new NQname(out, nn, n.getCharStartIndex(), end); } return out; }
// in src/org/python/indexer/AstConverter.java
private List<NKeyword> convertListKeyword(List<keyword> in) throws Exception { List<NKeyword> out = new ArrayList<NKeyword>(in == null ? 0 : in.size()); if (in != null) { for (keyword e : in) { NKeyword nkw = new NKeyword(e.getInternalArg(), convExpr(e.getInternalValue())); if (nkw != null) { out.add(nkw); } } } return out; }
// in src/org/python/indexer/AstConverter.java
private NBlock convertListStmt(List<stmt> in) throws Exception { List<NNode> out = new ArrayList<NNode>(in == null ? 0 : in.size()); if (in != null) { for (stmt e : in) { @SuppressWarnings("unchecked") NNode nx = (NNode)e.accept(this); if (nx != null) { out.add(nx); } } } return new NBlock(out, 0, 0); }
// in src/org/python/indexer/AstConverter.java
private NNode convExpr(PythonTree e) throws Exception { if (e == null) { return null; } @SuppressWarnings("unchecked") Object o = e.accept(this); if (o instanceof NNode) { return (NNode)o; } return null; }
// in src/org/python/indexer/AstConverter.java
Override public Object visitAssert(Assert n) throws Exception { return new NAssert(convExpr(n.getInternalTest()), convExpr(n.getInternalMsg()), start(n), stop(n)); }
// in src/org/python/indexer/AstConverter.java
Override public Object visitAssign(Assign n) throws Exception { return new NAssign(convertListExpr(n.getInternalTargets()), convExpr(n.getInternalValue()), start(n), stop(n)); }
// in src/org/python/indexer/AstConverter.java
Override public Object visitAttribute(Attribute n) throws Exception { return new NAttribute(convExpr(n.getInternalValue()), (NName)convExpr(n.getInternalAttrName()), start(n), stop(n)); }
// in src/org/python/indexer/AstConverter.java
Override public Object visitAugAssign(AugAssign n) throws Exception { return new NAugAssign(convExpr(n.getInternalTarget()), convExpr(n.getInternalValue()), convOp(n.getInternalOp()), start(n), stop(n)); }
// in src/org/python/indexer/AstConverter.java
Override public Object visitBinOp(BinOp n) throws Exception { return new NBinOp(convExpr(n.getInternalLeft()), convExpr(n.getInternalRight()), convOp(n.getInternalOp()), start(n), stop(n)); }
// in src/org/python/indexer/AstConverter.java
Override public Object visitBoolOp(BoolOp n) throws Exception { NBoolOp.OpType op; switch (n.getInternalOp()) { case And: op = NBoolOp.OpType.AND; break; case Or: op = NBoolOp.OpType.OR; break; default: op = NBoolOp.OpType.UNDEFINED; break; } return new NBoolOp(op, convertListExpr(n.getInternalValues()), start(n), stop(n)); }
// in src/org/python/indexer/AstConverter.java
Override public Object visitBreak(Break n) throws Exception { return new NBreak(start(n), stop(n)); }
// in src/org/python/indexer/AstConverter.java
Override public Object visitCall(Call n) throws Exception { return new NCall(convExpr(n.getInternalFunc()), convertListExpr(n.getInternalArgs()), convertListKeyword(n.getInternalKeywords()), convExpr(n.getInternalKwargs()), convExpr(n.getInternalStarargs()), start(n), stop(n)); }
// in src/org/python/indexer/AstConverter.java
Override public Object visitClassDef(ClassDef n) throws Exception { return new NClassDef((NName)convExpr(n.getInternalNameNode()), convertListExpr(n.getInternalBases()), convertListStmt(n.getInternalBody()), start(n), stop(n)); }
// in src/org/python/indexer/AstConverter.java
Override public Object visitCompare(Compare n) throws Exception { return new NCompare(convExpr(n.getInternalLeft()), null, // XXX: why null? convertListExpr(n.getInternalComparators()), start(n), stop(n)); }
// in src/org/python/indexer/AstConverter.java
Override public Object visitContinue(Continue n) throws Exception { return new NContinue(start(n), stop(n)); }
// in src/org/python/indexer/AstConverter.java
Override public Object visitDelete(Delete n) throws Exception { return new NDelete(convertListExpr(n.getInternalTargets()), start(n), stop(n)); }
// in src/org/python/indexer/AstConverter.java
Override public Object visitDict(Dict n) throws Exception { return new NDict(convertListExpr(n.getInternalKeys()), convertListExpr(n.getInternalValues()), start(n), stop(n)); }
// in src/org/python/indexer/AstConverter.java
Override public Object visitEllipsis(Ellipsis n) throws Exception { return new NEllipsis(start(n), stop(n)); }
// in src/org/python/indexer/AstConverter.java
Override public Object visitExceptHandler(ExceptHandler n) throws Exception { return new NExceptHandler(convExpr(n.getInternalName()), convExpr(n.getInternalType()), convertListStmt(n.getInternalBody()), start(n), stop(n)); }
// in src/org/python/indexer/AstConverter.java
Override public Object visitExec(Exec n) throws Exception { return new NExec(convExpr(n.getInternalBody()), convExpr(n.getInternalGlobals()), convExpr(n.getInternalLocals()), start(n), stop(n)); }
// in src/org/python/indexer/AstConverter.java
Override public Object visitExpr(Expr n) throws Exception { return new NExprStmt(convExpr(n.getInternalValue()), start(n), stop(n)); }
// in src/org/python/indexer/AstConverter.java
Override public Object visitFor(For n) throws Exception { return new NFor(convExpr(n.getInternalTarget()), convExpr(n.getInternalIter()), convertListStmt(n.getInternalBody()), convertListStmt(n.getInternalOrelse()), start(n), stop(n)); }
// in src/org/python/indexer/AstConverter.java
Override public Object visitFunctionDef(FunctionDef n) throws Exception { arguments args = n.getInternalArgs(); NFunctionDef fn = new NFunctionDef((NName)convExpr(n.getInternalNameNode()), convertListExpr(args.getInternalArgs()), convertListStmt(n.getInternalBody()), convertListExpr(args.getInternalDefaults()), (NName)convExpr(args.getInternalVarargName()), (NName)convExpr(args.getInternalKwargName()), start(n), stop(n)); fn.setDecoratorList(convertListExpr(n.getInternalDecorator_list())); return fn; }
// in src/org/python/indexer/AstConverter.java
Override public Object visitGeneratorExp(GeneratorExp n) throws Exception { List<NComprehension> generators = new ArrayList<NComprehension>(n.getInternalGenerators().size()); for (comprehension c : n.getInternalGenerators()) { generators.add(new NComprehension(convExpr(c.getInternalTarget()), convExpr(c.getInternalIter()), convertListExpr(c.getInternalIfs()), start(c), stop(c))); } return new NGeneratorExp(convExpr(n.getInternalElt()), generators, start(n), stop(n)); }
// in src/org/python/indexer/AstConverter.java
Override public Object visitGlobal(Global n) throws Exception { return new NGlobal(convertListName(n.getInternalNameNodes()), start(n), stop(n)); }
// in src/org/python/indexer/AstConverter.java
Override public Object visitIf(If n) throws Exception { return new NIf(convExpr(n.getInternalTest()), convertListStmt(n.getInternalBody()), convertListStmt(n.getInternalOrelse()), start(n), stop(n)); }
// in src/org/python/indexer/AstConverter.java
Override public Object visitIfExp(IfExp n) throws Exception { return new NIfExp(convExpr(n.getInternalTest()), convExpr(n.getInternalBody()), convExpr(n.getInternalOrelse()), start(n), stop(n)); }
// in src/org/python/indexer/AstConverter.java
Override public Object visitImport(Import n) throws Exception { List<NAlias> aliases = new ArrayList<NAlias>(n.getInternalNames().size()); for (alias e : n.getInternalNames()) { aliases.add(new NAlias(e.getInternalName(), convertQname(e.getInternalNameNodes()), (NName)convExpr(e.getInternalAsnameNode()), start(e), stop(e))); } return new NImport(aliases, start(n), stop(n)); }
// in src/org/python/indexer/AstConverter.java
Override public Object visitImportFrom(ImportFrom n) throws Exception { List<NAlias> aliases = new ArrayList<NAlias>(n.getInternalNames().size()); for (alias e : n.getInternalNames()) { aliases.add(new NAlias(e.getInternalName(), convertQname(e.getInternalNameNodes()), (NName)convExpr(e.getInternalAsnameNode()), start(e), stop(e))); } return new NImportFrom(n.getInternalModule(), convertQname(n.getInternalModuleNames()), aliases, start(n), stop(n)); }
// in src/org/python/indexer/AstConverter.java
Override public Object visitIndex(Index n) throws Exception { return new NIndex(convExpr(n.getInternalValue()), start(n), stop(n)); }
// in src/org/python/indexer/AstConverter.java
Override public Object visitLambda(Lambda n) throws Exception { arguments args = n.getInternalArgs(); return new NLambda(convertListExpr(args.getInternalArgs()), convExpr(n.getInternalBody()), convertListExpr(args.getInternalDefaults()), (NName)convExpr(args.getInternalVarargName()), (NName)convExpr(args.getInternalKwargName()), start(n), stop(n)); }
// in src/org/python/indexer/AstConverter.java
Override public Object visitList(org.python.antlr.ast.List n) throws Exception { return new NList(convertListExpr(n.getInternalElts()), start(n), stop(n)); }
// in src/org/python/indexer/AstConverter.java
Override public Object visitListComp(ListComp n) throws Exception { List<NComprehension> generators = new ArrayList<NComprehension>(n.getInternalGenerators().size()); for (comprehension c : n.getInternalGenerators()) { generators.add(new NComprehension(convExpr(c.getInternalTarget()), convExpr(c.getInternalIter()), convertListExpr(c.getInternalIfs()), start(c), stop(c))); } return new NListComp(convExpr(n.getInternalElt()), generators, start(n), stop(n)); }
// in src/org/python/indexer/AstConverter.java
Override public Object visitModule(Module n) throws Exception { return new NModule(convertListStmt(n.getInternalBody()), start(n), stop(n)); }
// in src/org/python/indexer/AstConverter.java
Override public Object visitName(Name n) throws Exception { return new NName(n.getInternalId(), start(n), stop(n)); }
// in src/org/python/indexer/AstConverter.java
Override public Object visitNum(Num n) throws Exception { return new NNum(n.getInternalN(), start(n), stop(n)); }
// in src/org/python/indexer/AstConverter.java
Override public Object visitPass(Pass n) throws Exception { return new NPass(start(n), stop(n)); }
// in src/org/python/indexer/AstConverter.java
Override public Object visitPrint(Print n) throws Exception { return new NPrint(convExpr(n.getInternalDest()), convertListExpr(n.getInternalValues()), start(n), stop(n)); }
// in src/org/python/indexer/AstConverter.java
Override public Object visitRaise(Raise n) throws Exception { return new NRaise(convExpr(n.getInternalType()), convExpr(n.getInternalInst()), convExpr(n.getInternalTback()), start(n), stop(n)); }
// in src/org/python/indexer/AstConverter.java
Override public Object visitRepr(Repr n) throws Exception { return new NRepr(convExpr(n.getInternalValue()), start(n), stop(n)); }
// in src/org/python/indexer/AstConverter.java
Override public Object visitReturn(Return n) throws Exception { return new NReturn(convExpr(n.getInternalValue()), start(n), stop(n)); }
// in src/org/python/indexer/AstConverter.java
Override public Object visitSlice(Slice n) throws Exception { return new NSlice(convExpr(n.getInternalLower()), convExpr(n.getInternalStep()), convExpr(n.getInternalUpper()), start(n), stop(n)); }
// in src/org/python/indexer/AstConverter.java
Override public Object visitStr(Str n) throws Exception { return new NStr(n.getInternalS(), start(n), stop(n)); }
// in src/org/python/indexer/AstConverter.java
Override public Object visitSubscript(Subscript n) throws Exception { return new NSubscript(convExpr(n.getInternalValue()), convExpr(n.getInternalSlice()), start(n), stop(n)); }
// in src/org/python/indexer/AstConverter.java
Override public Object visitTryExcept(TryExcept n) throws Exception { return new NTryExcept(convertListExceptHandler(n.getInternalHandlers()), convertListStmt(n.getInternalBody()), convertListStmt(n.getInternalOrelse()), start(n), stop(n)); }
// in src/org/python/indexer/AstConverter.java
Override public Object visitTryFinally(TryFinally n) throws Exception { return new NTryFinally(convertListStmt(n.getInternalBody()), convertListStmt(n.getInternalFinalbody()), start(n), stop(n)); }
// in src/org/python/indexer/AstConverter.java
Override public Object visitTuple(Tuple n) throws Exception { return new NTuple(convertListExpr(n.getInternalElts()), start(n), stop(n)); }
// in src/org/python/indexer/AstConverter.java
Override public Object visitUnaryOp(UnaryOp n) throws Exception { return new NUnaryOp(null, // XXX: why null for operator? convExpr(n.getInternalOperand()), start(n), stop(n)); }
// in src/org/python/indexer/AstConverter.java
Override public Object visitWhile(While n) throws Exception { return new NWhile(convExpr(n.getInternalTest()), convertListStmt(n.getInternalBody()), convertListStmt(n.getInternalOrelse()), start(n), stop(n)); }
// in src/org/python/indexer/AstConverter.java
Override public Object visitWith(With n) throws Exception { return new NWith(convExpr(n.getInternalOptional_vars()), convExpr(n.getInternalContext_expr()), convertListStmt(n.getInternalBody()), start(n), stop(n)); }
// in src/org/python/indexer/AstConverter.java
Override public Object visitYield(Yield n) throws Exception { return new NYield(convExpr(n.getInternalValue()), start(n), stop(n)); }
// in src/org/python/indexer/Indexer.java
public NModuleType getModuleForFile(String file) throws Exception { if (failedModules.contains(file)) { return null; } NModuleType m = getCachedModule(file); if (m != null) { return m; } return loadFile(file); }
// in src/org/python/indexer/Indexer.java
public List<Outliner.Entry> generateOutline(String file) throws Exception { return new Outliner().generate(this, file); }
// in src/org/python/indexer/Indexer.java
public NModuleType loadFile(String path) throws Exception { return loadFile(path, false); }
// in src/org/python/indexer/Indexer.java
public NModuleType loadString(String path, String contents) throws Exception { NModuleType module = getCachedModule(path); if (module != null) { finer("\nusing cached module " + path + " [succeeded]"); return module; } return parseAndResolve(path, contents); }
// in src/org/python/indexer/Indexer.java
public NModuleType loadFile(String path, boolean skipChain) throws Exception { File f = new File(path); if (f.isDirectory()) { finer("\n loading init file from directory: " + path); f = Util.joinPath(path, "__init__.py"); path = f.getAbsolutePath(); } if (!f.canRead()) { finer("\nfile not not found or cannot be read: " + path); return null; } NModuleType module = getCachedModule(path); if (module != null) { finer("\nusing cached module " + path + " [succeeded]"); return module; } if (!skipChain) { loadParentPackage(path); } try { return parseAndResolve(path); } catch (StackOverflowError soe) { handleException("Error loading " + path, soe); return null; } }
// in src/org/python/indexer/Indexer.java
private void loadParentPackage(String file) throws Exception { File f = new File(file); File parent = f.getParentFile(); if (parent == null || isInLoadPath(parent)) { return; } // the parent package of an __init__.py file is the grandparent dir if (parent != null && f.isFile() && "__init__.py".equals(f.getName())) { parent = parent.getParentFile(); } if (parent == null || isInLoadPath(parent)) { return; } File initpy = Util.joinPath(parent, "__init__.py"); if (!(initpy.isFile() && initpy.canRead())) { return; } loadFile(initpy.getPath()); }
// in src/org/python/indexer/Indexer.java
private NModuleType parseAndResolve(String file) throws Exception { return parseAndResolve(file, null); }
// in src/org/python/indexer/Indexer.java
private AstCache getAstCache() throws Exception { if (astCache == null) { astCache = AstCache.get(); } return astCache; }
// in src/org/python/indexer/Indexer.java
public NModule getAstForFile(String file) throws Exception { return getAstCache().getAST(file); }
// in src/org/python/indexer/Indexer.java
public NModule getAstForFile(String file, String contents) throws Exception { return getAstCache().getAST(file, contents); }
// in src/org/python/indexer/Indexer.java
public NModuleType getBuiltinModule(String qname) throws Exception { return builtins.get(qname); }
// in src/org/python/indexer/Indexer.java
public NModuleType loadModule(String modname) throws Exception { if (failedModules.contains(modname)) { return null; } NModuleType cached = getCachedModule(modname); // builtin file-less modules if (cached != null) { finer("\nusing cached module " + modname); return cached; } NModuleType mt = getBuiltinModule(modname); if (mt != null) { return mt; } finer("looking for module " + modname); if (modname.endsWith(".py")) { modname = modname.substring(0, modname.length() - 3); } String modpath = modname.replace('.', '/'); // A nasty hack to avoid e.g. python2.5 becoming python2/5. // Should generalize this for directory components containing '.'. modpath = modpath.replaceFirst("(/python[23])/([0-9]/)", "$1.$2"); List<String> loadPath = getLoadPath(); for (String p : loadPath) { String dirname = p + modpath; String pyname = dirname + ".py"; String initname = Util.joinPath(dirname, "__init__.py").getAbsolutePath(); String name; // foo/bar has priority over foo/bar.py // http://www.python.org/doc/essays/packages.html if (Util.isReadableFile(initname)) { name = initname; } else if (Util.isReadableFile(pyname)) { name = pyname; } else { continue; } name = Util.canonicalize(name); NModuleType m = loadFile(name); if (m != null) { finer("load of module " + modname + "[succeeded]"); return m; } } finer("failed to find module " + modname + " in load path"); failedModules.add(modname); return null; }
// in src/org/python/indexer/Indexer.java
public void loadFileRecursive(String fullname) throws Exception { File file_or_dir = new File(fullname); if (file_or_dir.isDirectory()) { for (File file : file_or_dir.listFiles()) { loadFileRecursive(file.getAbsolutePath()); } } else { if (file_or_dir.getAbsolutePath().endsWith(".py")) { loadFile(file_or_dir.getAbsolutePath()); } } }
// in src/org/python/indexer/Outliner.java
public List<Entry> generate(Indexer idx, String abspath) throws Exception { NModuleType mt = idx.getModuleForFile(abspath); if (mt == null) { return new ArrayList<Entry>(); } return generate(mt.getTable(), abspath); }
// in src/org/python/indexer/ast/NSubscript.java
Override public NType resolve(Scope s) throws Exception { NType vt = resolveExpr(value, s); NType st = resolveExpr(slice, s); // slicing if (vt.isUnknownType()) { if (st.isListType()) { return setType(vt); } return setType(new NUnknownType()); } if (st.isListType()) { NType getslice_type = vt.getTable().lookupTypeAttr("__getslice__"); if (getslice_type == null) { addError("The type can't be sliced: " + vt); return setType(new NUnknownType()); } if (!getslice_type.isFuncType()) { addError("The type's __getslice__ method is not a function: " + getslice_type); return setType(new NUnknownType()); } return setType(getslice_type.asFuncType().getReturnType().follow()); } // subscription if (slice instanceof NIndex) { if (vt.isListType()) { warnUnlessNumIndex(st); return setType(vt.asListType().getElementType()); } if (vt.isTupleType()) { warnUnlessNumIndex(st); return setType(vt.asTupleType().toListType().getElementType()); } if (vt.isStrType()) { warnUnlessNumIndex(st); return setType(Indexer.idx.builtins.BaseStr); } // XXX: unicode, buffer, xrange if (vt.isDictType()) { if (!st.follow().equals(vt.asDictType().getKeyType())) { addWarning("Possible KeyError (wrong type for subscript)"); } return setType(vt.asDictType().getValueType()); // infer it regardless } // else fall through } // subscription via delegation if (vt.isUnionType()) { for (NType u : vt.asUnionType().getTypes()) { NType gt = vt.getTable().lookupTypeAttr("__getitem__"); if (gt != null) { return setType(get__getitem__type(gt, gt)); } } } NType gt = vt.getTable().lookupTypeAttr("__getitem__"); return setType(get__getitem__type(gt, vt)); }
// in src/org/python/indexer/ast/NWhile.java
Override public NType resolve(Scope s) throws Exception { resolveExpr(test, s); if (body != null) { setType(resolveExpr(body, s)); } if (orelse != null) { addType(resolveExpr(orelse, s)); } return getType(); }
// in src/org/python/indexer/ast/NAugAssign.java
Override public NType resolve(Scope s) throws Exception { resolveExpr(target, s); return setType(resolveExpr(value, s)); }
// in src/org/python/indexer/ast/NNum.java
Override public NType resolve(Scope s) throws Exception { return setType(Indexer.idx.builtins.BaseNum); }
// in src/org/python/indexer/ast/NameBinder.java
public void bind(Scope s, NNode target, NType rvalue) throws Exception { if (target instanceof NName) { bindName(s, (NName)target, rvalue); return; } if (target instanceof NTuple) { bind(s, ((NTuple)target).elts, rvalue); return; } if (target instanceof NList) { bind(s, ((NList)target).elts, rvalue); return; } if (target instanceof NAttribute) { // This causes various problems if we let it happen during the // name-binding pass. I believe the only name-binding context // in which an NAttribute can be an lvalue is in an assignment. // Assignments are statements, so they can only appear in blocks. // Hence the scope for the top-level name is unambiguous; we can // safely leave binding it until the resolve pass. if (!s.isNameBindingPhase()) { ((NAttribute)target).setAttr(s, rvalue); } return; } if (target instanceof NSubscript) { // Ditto. No resolving is allowed during the name-binding phase. if (!s.isNameBindingPhase()) { target.resolveExpr(target, s); } return; } Indexer.idx.putProblem(target, "invalid location for assignment"); }
// in src/org/python/indexer/ast/NameBinder.java
public void bind(Scope s, List<NNode> xs, NType rvalue) throws Exception { if (rvalue.isTupleType()) { List<NType> vs = rvalue.asTupleType().getElementTypes(); if (xs.size() != vs.size()) { reportUnpackMismatch(xs, vs.size()); } else { for (int i = 0; i < xs.size(); i++) { bind(s, xs.get(i), vs.get(i)); } } return; } if (rvalue.isListType()) { bind(s, xs, rvalue.asListType().toTupleType(xs.size())); return; } if (rvalue.isDictType()) { bind(s, xs, rvalue.asDictType().toTupleType(xs.size())); return; } if (!rvalue.isUnknownType()) { Indexer.idx.putProblem(xs.get(0).getFile(), xs.get(0).start(), xs.get(xs.size()-1).end(), "unpacking non-iterable: " + rvalue); } for (int i = 0; i < xs.size(); i++) { bind(s, xs.get(i), new NUnknownType()); } }
// in src/org/python/indexer/ast/NameBinder.java
public NBinding bindName(Scope s, NName name, NType rvalue) throws Exception { NBinding b; if (s.isGlobalName(name.id)) { b = s.getGlobalTable().put(name.id, name, rvalue, kindOr(SCOPE)); Indexer.idx.putLocation(name, b); } else { Scope bindingScope = s.getScopeSymtab(); b = bindingScope.put(name.id, name, rvalue, kindOr(bindingScope.isFunctionScope() ? VARIABLE : SCOPE)); } name.setType(b.followType()); // XXX: this seems like a bit of a hack; should at least figure out // and document what use cases require it. NType nameType = name.getType(); if (!(nameType.isModuleType() || nameType.isClassType())) { nameType.getTable().setPath(b.getQname()); } return b; }
// in src/org/python/indexer/ast/NameBinder.java
public void bindIter(Scope s, NNode target, NNode iter) throws Exception { NType iterType = NNode.resolveExpr(iter, s); if (iterType.isListType()) { bind(s, target, iterType.asListType().getElementType()); } else if (iterType.isTupleType()) { bind(s, target, iterType.asTupleType().toListType().getElementType()); } else { NBinding ent = iterType.getTable().lookupAttr("__iter__"); if (ent == null || !ent.getType().isFuncType()) { if (!iterType.isUnknownType()) { iter.addWarning("not an iterable type: " + iterType); } bind(s, target, new NUnknownType()); } else { bind(s, target, ent.getType().asFuncType().getReturnType()); } } }
// in src/org/python/indexer/ast/NExprStmt.java
Override public NType resolve(Scope s) throws Exception { resolveExpr(value, s); return getType(); }
// in src/org/python/indexer/ast/NTryExcept.java
Override public NType resolve(Scope s) throws Exception { resolveList(handlers, s); if (body != null) { setType(resolveExpr(body, s)); } if (orelse != null) { addType(resolveExpr(orelse, s)); } return getType(); }
// in src/org/python/indexer/ast/NAttribute.java
public void setAttr(Scope s, NType v) throws Exception { setType(new NUnknownType()); NType targetType = resolveExpr(target, s); if (targetType.isUnionType()) { targetType = targetType.asUnionType().firstKnownNonNullAlternate(); if (targetType == null) { return; } } targetType = targetType.follow(); if (targetType == Indexer.idx.builtins.None) { return; } NBinding b = targetType.getTable().putAttr(attr.id, attr, v, ATTRIBUTE); if (b != null) { setType(attr.setType(b.followType())); } }
// in src/org/python/indexer/ast/NAttribute.java
Override public NType resolve(Scope s) throws Exception { setType(new NUnknownType()); NType targetType = resolveExpr(target, s); if (targetType.isUnionType()) { NType ret = new NUnknownType(); for (NType tp : targetType.asUnionType().getTypes()) { resolveAttributeOnType(tp); ret = NUnionType.union(ret, getType()); } setType(attr.setType(ret.follow())); } else { resolveAttributeOnType(targetType); } return getType(); }
// in src/org/python/indexer/ast/NIf.java
Override public NType resolve(Scope s) throws Exception { resolveExpr(test, s); if (body != null) { setType(resolveExpr(body, s)); } if (orelse != null) { addType(resolveExpr(orelse, s)); } return getType(); }
// in src/org/python/indexer/ast/NExec.java
Override public NType resolve(Scope s) throws Exception { resolveExpr(body, s); resolveExpr(globals, s); resolveExpr(locals, s); return getType(); }
// in src/org/python/indexer/ast/NWith.java
Override public NType resolve(Scope s) throws Exception { NType val = resolveExpr(context_expr, s); NameBinder.make().bind(s, optional_vars, val); return setType(resolveExpr(body, s)); }
// in src/org/python/indexer/ast/NCall.java
Override public NType resolve(Scope s) throws Exception { NType ft = resolveExpr(func, s); List<NType> argTypes = new ArrayList<NType>(); for (NNode a : args) { argTypes.add(resolveExpr(a, s)); } resolveList(keywords, s); resolveExpr(starargs, s); resolveExpr(kwargs, s); if (ft.isClassType()) { return setType(ft); // XXX: was new NInstanceType(ft) } if (ft.isFuncType()) { return setType(ft.asFuncType().getReturnType().follow()); } if (ft.isUnknownType()) { NUnknownType to = new NUnknownType(); NFuncType at = new NFuncType(to); NUnionType.union(ft, at); return setType(to); } addWarning("calling non-function " + ft); return setType(new NUnknownType()); }
// in src/org/python/indexer/ast/NIfExp.java
Override public NType resolve(Scope s) throws Exception { resolveExpr(test, s); if (body != null) { setType(resolveExpr(body, s)); } if (orelse != null) { addType(resolveExpr(orelse, s)); } return getType(); }
// in src/org/python/indexer/ast/NPrint.java
Override public NType resolve(Scope s) throws Exception { resolveExpr(dest, s); resolveList(values, s); return getType(); }
// in src/org/python/indexer/ast/NExceptHandler.java
Override protected void bindNames(Scope s) throws Exception { if (name != null) { NameBinder.make().bind(s, name, new NUnknownType()); } }
// in src/org/python/indexer/ast/NExceptHandler.java
Override public NType resolve(Scope s) throws Exception { NType typeval = new NUnknownType(); if (exceptionType != null) { typeval = resolveExpr(exceptionType, s); } if (name != null) { NameBinder.make().bind(s, name, typeval); } if (body != null) { return setType(resolveExpr(body, s)); } else { return setType(new NUnknownType()); } }
// in src/org/python/indexer/ast/NComprehension.java
Override protected void bindNames(Scope s) throws Exception { bindNames(s, target, NameBinder.make()); }
// in src/org/python/indexer/ast/NComprehension.java
private void bindNames(Scope s, NNode target, NameBinder binder) throws Exception { if (target instanceof NName) { binder.bind(s, (NName)target, new NUnknownType()); return; } if (target instanceof NSequence) { for (NNode n : ((NSequence)target).getElements()) { bindNames(s, n, binder); } } }
// in src/org/python/indexer/ast/NComprehension.java
Override public NType resolve(Scope s) throws Exception { NameBinder.make().bindIter(s, target, iter); resolveList(ifs, s); return setType(target.getType()); }
// in src/org/python/indexer/ast/NImport.java
Override protected void bindNames(Scope s) throws Exception { bindAliases(s, aliases); }
// in src/org/python/indexer/ast/NImport.java
static void bindAliases(Scope s, List<NAlias> aliases) throws Exception { NameBinder binder = NameBinder.make(); for (NAlias a : aliases) { if (a.aname != null) { binder.bind(s, a.aname, new NUnknownType()); } } }
// in src/org/python/indexer/ast/NImport.java
Override public NType resolve(Scope s) throws Exception { Scope scope = s.getScopeSymtab(); for (NAlias a : aliases) { NType modtype = resolveExpr(a, s); if (modtype.isModuleType()) { importName(scope, a, modtype.asModuleType()); } } return getType(); }
// in src/org/python/indexer/ast/NImport.java
private void importName(Scope s, NAlias a, NModuleType mt) throws Exception { if (a.aname != null) { if (mt.getFile() != null) { NameBinder.make().bind(s, a.aname, mt); } else { // XXX: seems like the url should be set in loadModule, not here. // Can't the moduleTable store url-keyed modules too? s.update(a.aname.id, new NUrl(Builtins.LIBRARY_URL + mt.getTable().getPath() + ".html"), mt, NBinding.Kind.SCOPE); } } addReferences(s, a.qname, true/*put top name in scope*/); }
// in src/org/python/indexer/ast/NList.java
Override public NType resolve(Scope s) throws Exception { if (elts.size() == 0) { return setType(new NListType()); // list<unknown> } NListType listType = null; for (NNode elt : elts) { if (listType == null) { listType = new NListType(resolveExpr(elt, s)); } else { listType.add(resolveExpr(elt, s)); } } if (listType != null) { setType(listType); } return getType(); }
// in src/org/python/indexer/ast/NBlock.java
Override public NType resolve(Scope scope) throws Exception { for (NNode n : seq) { // XXX: This works for inferring lambda return types, but needs // to be fixed for functions (should be union of return stmt types). NType returnType = resolveExpr(n, scope); if (returnType != Indexer.idx.builtins.None) { setType(returnType); } } return getType(); }
// in src/org/python/indexer/ast/NGeneratorExp.java
Override public NType resolve(Scope s) throws Exception { resolveList(generators, s); return setType(new NListType(resolveExpr(elt, s))); }
// in src/org/python/indexer/ast/NAssign.java
Override protected void bindNames(Scope s) throws Exception { NameBinder binder = NameBinder.make(); for (NNode target : targets) { binder.bind(s, target, new NUnknownType()); } }
// in src/org/python/indexer/ast/NAssign.java
Override public NType resolve(Scope s) throws Exception { NType valueType = resolveExpr(rvalue, s); switch (targets.size()) { case 0: break; case 1: NameBinder.make().bind(s, targets.get(0), valueType); break; default: NameBinder.make().bind(s, targets, valueType); break; } return setType(valueType); }
// in src/org/python/indexer/ast/NSlice.java
Override public NType resolve(Scope s) throws Exception { resolveExpr(lower, s); resolveExpr(step, s); resolveExpr(upper, s); return setType(new NListType()); }
// in src/org/python/indexer/ast/NReturn.java
Override public NType resolve(Scope s) throws Exception { return setType(resolveExpr(value, s)); }
// in src/org/python/indexer/ast/NDelete.java
Override public NType resolve(Scope s) throws Exception { for (NNode n : targets) { resolveExpr(n, s); if (n instanceof NName) { s.remove(((NName)n).id); } } return getType(); }
// in src/org/python/indexer/ast/NFunctionDef.java
Override protected void bindNames(Scope s) throws Exception { Scope owner = s.getScopeSymtab(); // enclosing class, function or module setType(new NFuncType()); Scope funcTable = new Scope(s.getEnclosingLexicalScope(), Scope.Type.FUNCTION); getType().setTable(funcTable); funcTable.setPath(owner.extendPath(getBindingName(owner))); // If we already defined this function in this scope, don't try it again. NType existing = owner.lookupType(getBindingName(owner), true /* local scope */); if (existing != null && existing.isFuncType()) { return; } bindFunctionName(owner); bindFunctionParams(funcTable); bindFunctionDefaults(s); bindMethodAttrs(owner); }
// in src/org/python/indexer/ast/NFunctionDef.java
protected void bindFunctionName(Scope owner) throws Exception { NBinding.Kind funkind = FUNCTION; if (owner.getScopeType() == Scope.Type.CLASS) { if ("__init__".equals(name.id)) { funkind = CONSTRUCTOR; } else { funkind = METHOD; } } NameBinder.make(funkind).bindName(owner, name, getType()); }
// in src/org/python/indexer/ast/NFunctionDef.java
protected void bindFunctionParams(Scope funcTable) throws Exception { NameBinder param = NameBinder.make(PARAMETER); for (NNode a : args) { param.bind(funcTable, a, new NUnknownType()); } if (varargs != null) { param.bind(funcTable, varargs, new NListType()); } if (kwargs != null) { param.bind(funcTable, kwargs, new NDictType()); } }
// in src/org/python/indexer/ast/NFunctionDef.java
protected void bindFunctionDefaults(Scope s) throws Exception { for (NNode n : defaults) { if (n.bindsName()) { n.bindNames(s); } } }
// in src/org/python/indexer/ast/NFunctionDef.java
protected void bindMethodAttrs(Scope owner) throws Exception { NType cls = Indexer.idx.lookupQnameType(owner.getPath()); if (cls == null || !cls.isClassType()) { return; } // We don't currently differentiate between classes and instances. addReadOnlyAttr("im_class", cls, CLASS); addReadOnlyAttr("__class__", cls, CLASS); addReadOnlyAttr("im_self", cls, ATTRIBUTE); addReadOnlyAttr("__self__", cls, ATTRIBUTE); }
// in src/org/python/indexer/ast/NFunctionDef.java
Override public NType resolve(Scope outer) throws Exception { resolveList(defaults, outer); resolveList(decoratorList, outer); Scope funcTable = getTable(); NBinding selfBinding = funcTable.lookup("__self__"); if (selfBinding != null && !selfBinding.getType().isClassType()) { selfBinding = null; } if (selfBinding != null) { if (args.size() < 1) { addWarning(name, "method should have at least one argument (self)"); } else if (!(args.get(0) instanceof NName)) { addError(name, "self parameter must be an identifier"); } } NTupleType fromType = new NTupleType(); bindParamsToDefaults(selfBinding, fromType); if (varargs != null) { NBinding b = funcTable.lookupLocal(varargs.id); if (b != null) { fromType.add(b.getType()); } } if (kwargs != null) { NBinding b = funcTable.lookupLocal(kwargs.id); if (b != null) { fromType.add(b.getType()); } } NType toType = resolveExpr(body, funcTable); getType().asFuncType().setReturnType(toType); return getType(); }
// in src/org/python/indexer/ast/NFunctionDef.java
private void bindParamsToDefaults(NBinding selfBinding, NTupleType fromType) throws Exception { NameBinder param = NameBinder.make(PARAMETER); Scope funcTable = getTable(); for (int i = 0; i < args.size(); i++) { NNode arg = args.get(i); NType argtype = ((i == 0 && selfBinding != null) ? selfBinding.getType() : getArgType(args, defaults, i)); param.bind(funcTable, arg, argtype); fromType.add(argtype); } }
// in src/org/python/indexer/ast/NRaise.java
Override public NType resolve(Scope s) throws Exception { resolveExpr(exceptionType, s); resolveExpr(inst, s); resolveExpr(traceback, s); return getType(); }
// in src/org/python/indexer/ast/NCompare.java
Override public NType resolve(Scope s) throws Exception { setType(Indexer.idx.builtins.BaseNum); resolveExpr(left, s); resolveList(comparators, s); return getType(); }
// in src/org/python/indexer/ast/NQname.java
Override public NType resolve(Scope s) throws Exception { setType(name.setType(new NUnknownType())); // Check for top-level native or standard module. if (isUnqualified()) { NModuleType mt = Indexer.idx.loadModule(name.id); if (mt != null) { return setType(name.setType(mt)); } } else { // Check for second-level builtin such as "os.path". NModuleType mt = Indexer.idx.getBuiltinModule(thisQname()); if (mt != null) { setType(name.setType(mt)); resolveExpr(next, s); return mt; } } return resolveInFilesystem(s); }
// in src/org/python/indexer/ast/NQname.java
private NType resolveInFilesystem(Scope s) throws Exception { NModuleType start = getStartModule(s); if (start == null) { reportUnresolvedModule(); return getType(); } String qname = start.getTable().getPath(); String relQname; if (isDot()) { relQname = Util.getQnameParent(qname); } else if (!isTop()) { relQname = qname + "." + name.id; } else { // top name: first look in current dir, then sys.path String dirQname = isInitPy() ? qname : Util.getQnameParent(qname); relQname = dirQname + "." + name.id; if (Indexer.idx.loadModule(relQname) == null) { relQname = name.id; } } NModuleType mod = Indexer.idx.loadModule(relQname); if (mod == null) { reportUnresolvedModule(); return getType(); } setType(name.setType(mod)); if (!isTop() && mod.getFile() != null) { Scope parentPkg = getPrevious().getTable(); NBinding mb = Indexer.idx.moduleTable.lookup(mod.getFile()); parentPkg.put(name.id, mb); } resolveExpr(next, s); return getType(); }
// in src/org/python/indexer/ast/NQname.java
private NModuleType getStartModule(Scope s) throws Exception { if (!isTop()) { return getPrevious().getType().asModuleType(); } // Start with module for current file (i.e. containing directory). NModuleType start = null; Scope mtable = s.getSymtabOfType(Scope.Type.MODULE); if (mtable != null) { start = Indexer.idx.loadModule(mtable.getPath()); if (start != null) { return start; } } String dir = new File(getFile()).getParent(); if (dir == null) { Indexer.idx.warn("Unable to find parent dir for " + getFile()); return null; } return Indexer.idx.loadModule(dir); }
// in src/org/python/indexer/ast/NModule.java
public void setFile(String file) throws Exception { this.file = file; this.name = Util.moduleNameFor(file); this.md5 = Util.getMD5(new File(file)); }
// in src/org/python/indexer/ast/NModule.java
public void setFile(File path) throws Exception { file = path.getCanonicalPath(); name = Util.moduleNameFor(file); md5 = Util.getMD5(path); }
// in src/org/python/indexer/ast/NModule.java
public void setFileAndMD5(String path, String md5) throws Exception { file = path; name = Util.moduleNameFor(file); this.md5 = md5; }
// in src/org/python/indexer/ast/NModule.java
Override public NType resolve(Scope s) throws Exception { NBinding mb = Indexer.idx.moduleTable.lookupLocal(file); if (mb == null ) { Indexer.idx.reportFailedAssertion("No module for " + name + ": " + file); setType(new NModuleType(name, file, s)); } else { setType(mb.getType()); } resolveExpr(body, getTable()); resolveExportedNames(); return getType(); }
// in src/org/python/indexer/ast/NModule.java
private void resolveExportedNames() throws Exception { NModuleType mtype = null; NType thisType = getType(); if (thisType.isModuleType()) { mtype = thisType.asModuleType(); } else if (thisType.isUnionType()) { for (NType u : thisType.asUnionType().getTypes()) { if (u.isModuleType()) { mtype = u.asModuleType(); break; } } } if (mtype == null) { Indexer.idx.reportFailedAssertion("Found non-module type for " + this + " in " + getFile() + ": " + thisType); return; } Scope table = mtype.getTable(); for (NStr nstr : getExportedNameNodes()) { String name = nstr.n.toString(); NBinding b = table.lookupLocal(name); if (b != null) { Indexer.idx.putLocation(nstr, b); } } }
// in src/org/python/indexer/ast/NModule.java
public List<String> getExportedNames() throws Exception { List<String> exports = new ArrayList<String>(); if (!getType().isModuleType()) { return exports; } for (NStr nstr : getExportedNameNodes()) { exports.add(nstr.n.toString()); } return exports; }
// in src/org/python/indexer/ast/NModule.java
public List<NStr> getExportedNameNodes() throws Exception { List<NStr> exports = new ArrayList<NStr>(); if (!getType().isModuleType()) { return exports; } NBinding all = getTable().lookupLocal("__all__"); if (all== null) { return exports; } Def def = all.getSignatureNode(); if (def == null) { return exports; } NNode __all__ = getDeepestNodeAtOffset(def.start()); if (!(__all__ instanceof NName)) { return exports; } NNode assign = __all__.getParent(); if (!(assign instanceof NAssign)) { return exports; } NNode rvalue = ((NAssign)assign).rvalue; if (!(rvalue instanceof NList)) { return exports; } for (NNode elt : ((NList)rvalue).elts) { if (elt instanceof NStr) { NStr nstr = (NStr)elt; if (nstr.n != null) { exports.add(nstr); } } } return exports; }
// in src/org/python/indexer/ast/NListComp.java
Override public NType resolve(Scope s) throws Exception { NameBinder binder = NameBinder.make(); resolveList(generators, s); return setType(new NListType(resolveExpr(elt, s))); }
// in src/org/python/indexer/ast/NImportFrom.java
Override protected void bindNames(Scope s) throws Exception { // XXX: we can support this by resolving the qname now. if (isImportStar()) { return; } NImport.bindAliases(s, aliases); }
// in src/org/python/indexer/ast/NImportFrom.java
Override public NType resolve(Scope s) throws Exception { Scope scope = s.getScopeSymtab(); resolveExpr(qname, s); NType bottomType = qname.getBottom().getType(); if (!bottomType.isModuleType()) { return setType(new NUnknownType()); } NModuleType mt = (NModuleType)bottomType; setType(mt); NImport.addReferences(s, qname, false /* don't put top name in scope */); if (isImportStar()) { importStar(s, mt); return getType(); } for (NAlias a : aliases) { resolveAlias(scope, mt, a); } return getType(); }
// in src/org/python/indexer/ast/NImportFrom.java
private void resolveAlias(Scope scope, NModuleType mt, NAlias a) throws Exception { // Possibilities 1 & 2: x/y.py or x/y/__init__.py NBinding entry = mt.getTable().lookup(a.name); if (entry == null) { // Possibility 3: try looking for x/y/foo.py String mqname = qname.toQname() + "." + a.qname.toQname(); NModuleType mt2 = Indexer.idx.loadModule(mqname); if (mt2 != null) { entry = Indexer.idx.lookupQname(mt2.getTable().getPath()); } } if (entry == null) { addError(a, "name " + a.qname.getName().id + " not found in module " + this.module); return; } String qname = a.qname.getName().id; String aname = a.aname != null ? a.aname.id : null; // Create references for both the name and the alias (if present). // Then if "foo", add "foo" to scope. If "foo as bar", add "bar". Indexer.idx.putLocation(a.qname.getName(), entry); if (aname != null) { Indexer.idx.putLocation(a.aname, entry); scope.put(aname, entry); } else { scope.put(qname, entry); } }
// in src/org/python/indexer/ast/NImportFrom.java
private void importStar(Scope s, NModuleType mt) throws Exception { if (mt == null || mt.getFile() == null) { return; } NModule mod = Indexer.idx.getAstForFile(mt.getFile()); if (mod == null) { return; } List<String> names = mod.getExportedNames(); if (!names.isEmpty()) { for (String name : names) { NBinding nb = mt.getTable().lookupLocal(name); if (nb != null) { s.put(name, nb); } } } else { // Fall back to importing all names not starting with "_". for (Entry<String, NBinding> e : mt.getTable().entrySet()) { if (!e.getKey().startsWith("_")) { s.put(e.getKey(), e.getValue()); } } } }
// in src/org/python/indexer/ast/NUrl.java
Override public NType resolve(Scope s) throws Exception { return setType(Indexer.idx.builtins.BaseStr); }
// in src/org/python/indexer/ast/NClassDef.java
Override protected void bindNames(Scope s) throws Exception { Scope container = s.getScopeSymtab(); setType(new NClassType(name.id, container)); // If we already defined this class in this scope, don't redefine it. NType existing = container.lookupType(name.id); if (existing != null && existing.isClassType()) { return; } NameBinder.make(NBinding.Kind.CLASS).bind(container, name, getType()); }
// in src/org/python/indexer/ast/NClassDef.java
Override public NType resolve(Scope s) throws Exception { NClassType thisType = getType().asClassType(); List<NType> baseTypes = new ArrayList<NType>(); for (NNode base : bases) { NType baseType = resolveExpr(base, s); if (baseType.isClassType()) { thisType.addSuper(baseType); } baseTypes.add(baseType); } Builtins builtins = Indexer.idx.builtins; addSpecialAttribute("__bases__", new NTupleType(baseTypes)); addSpecialAttribute("__name__", builtins.BaseStr); addSpecialAttribute("__module__", builtins.BaseStr); addSpecialAttribute("__doc__", builtins.BaseStr); addSpecialAttribute("__dict__", new NDictType(builtins.BaseStr, new NUnknownType())); resolveExpr(body, getTable()); return getType(); }
// in src/org/python/indexer/ast/NAlias.java
Override public NType resolve(Scope s) throws Exception { setType(resolveExpr(qname, s)); // "import a.b.c" defines 'a' (the top module) in the scope, whereas // "import a.b.c as x" defines 'x', which refers to the bottom module. if (aname != null && qname != null) { setType(qname.getBottom().getType()); aname.setType(getType()); } return getType(); }
// in src/org/python/indexer/ast/NBoolOp.java
Override public NType resolve(Scope s) throws Exception { if (op == OpType.AND) { NType last = null; for (NNode e : values) { last = resolveExpr(e, s); } return setType(last == null ? new NUnknownType() : last); } // OR return setType(resolveListAsUnion(values, s)); }
// in src/org/python/indexer/ast/NBinOp.java
Override public NType resolve(Scope s) throws Exception { NType ltype = null, rtype = null; if (left != null) { ltype = resolveExpr(left, s).follow(); } if (right != null) { rtype = resolveExpr(right, s).follow(); } // If either non-null operand is a string, assume the result is a string. if (ltype == Indexer.idx.builtins.BaseStr || rtype == Indexer.idx.builtins.BaseStr) { return setType(Indexer.idx.builtins.BaseStr); } // If either non-null operand is a number, assume the result is a number. if (ltype == Indexer.idx.builtins.BaseNum || rtype == Indexer.idx.builtins.BaseNum) { return setType(Indexer.idx.builtins.BaseNum); } if (ltype == null) { return setType(rtype == null ? new NUnknownType() : rtype); } if (rtype == null) { return setType(ltype == null ? new NUnknownType() : ltype); } return setType(NUnionType.union(ltype, rtype)); }
// in src/org/python/indexer/ast/NTuple.java
Override public NType resolve(Scope s) throws Exception { NTupleType thisType = new NTupleType(); for (NNode e : elts) { thisType.add(resolveExpr(e, s)); } return setType(thisType); }
// in src/org/python/indexer/ast/NStr.java
Override public NType resolve(Scope s) throws Exception { return setType(Indexer.idx.builtins.BaseStr); }
// in src/org/python/indexer/ast/NRepr.java
Override public NType resolve(Scope s) throws Exception { resolveExpr(value, s); return setType(Indexer.idx.builtins.BaseStr); }
// in src/org/python/indexer/ast/NYield.java
Override public NType resolve(Scope s) throws Exception { return setType(new NListType(resolveExpr(value, s))); }
// in src/org/python/indexer/ast/NUnaryOp.java
Override public NType resolve(Scope s) throws Exception { return setType(resolveExpr(operand, s)); }
// in src/org/python/indexer/ast/NNode.java
protected void bindNames(Scope s) throws Exception { throw new UnsupportedOperationException("Not a name-binding node type"); }
// in src/org/python/indexer/ast/NNode.java
public NType resolve(Scope s) throws Exception { return getType(); }
// in src/org/python/indexer/ast/NIndex.java
Override public NType resolve(Scope s) throws Exception { return setType(resolveExpr(value, s)); }
// in src/org/python/indexer/ast/NName.java
Override public NType resolve(Scope s) throws Exception { NBinding b = s.lookup(id); if (b == null) { b = makeTempBinding(s); } Indexer.idx.putLocation(this, b); return setType(b.followType()); }
// in src/org/python/indexer/ast/NGlobal.java
Override public NType resolve(Scope s) throws Exception { Scope moduleTable = s.getGlobalTable(); for (NName name : names) { if (s.isGlobalName(name.id)) { continue; // already bound by this (or another) global stmt } s.addGlobalName(name.id); NBinding b = moduleTable.lookup(name); if (b == null) { b = moduleTable.put(name.id, null, new NUnknownType(), NBinding.Kind.SCOPE); } Indexer.idx.putLocation(name, b); } return getType(); }
// in src/org/python/indexer/ast/NBody.java
Override public NType resolve(Scope scope) throws Exception { try { scope.setNameBindingPhase(true); visit(new GlobalFinder(scope)); visit(new BindingFinder(scope)); } finally { scope.setNameBindingPhase(false); } return super.resolve(scope); }
// in src/org/python/indexer/ast/NAssert.java
Override public NType resolve(Scope s) throws Exception { resolveExpr(test, s); resolveExpr(msg, s); return getType(); }
// in src/org/python/indexer/ast/NLambda.java
Override protected void bindFunctionName(Scope owner) throws Exception { NameBinder.make(NBinding.Kind.FUNCTION).bindName(owner, fname, getType()); }
// in src/org/python/indexer/ast/NLambda.java
Override protected void bindMethodAttrs(Scope owner) throws Exception { // no-op }
// in src/org/python/indexer/ast/NLambda.java
Override public NType resolve(Scope s) throws Exception { if (!getType().isFuncType()) { org.python.indexer.Indexer.idx.reportFailedAssertion( "Bad type on " + this + ": type=" + getType() + " in file " + getFile() + " at " + start()); } NTupleType fromType = new NTupleType(); NameBinder param = NameBinder.make(NBinding.Kind.PARAMETER); resolveList(defaults, s); Scope funcTable = getTable(); int argnum = 0; for (NNode a : args) { NType argtype = NFunctionDef.getArgType(args, defaults, argnum++); param.bind(funcTable, a, argtype); fromType.add(argtype); } if (varargs != null) { NType u = new NUnknownType(); param.bind(funcTable, varargs, u); fromType.add(u); } if (kwargs != null) { NType u = new NUnknownType(); param.bind(funcTable, kwargs, u); fromType.add(u); } // A lambda body is not an NBody, so it doesn't undergo the two // pre-resolve passes for finding global statements and name-binding // constructs. However, the lambda expression may itself contain // name-binding constructs (generally, other lambdas), so we need to // perform the name-binding pass on it before resolving. try { funcTable.setNameBindingPhase(true); body.visit(new BindingFinder(funcTable)); } finally { funcTable.setNameBindingPhase(false); } NType toType = resolveExpr(body, funcTable); if (getType().isFuncType()) { // else warning logged at method entry above getType().asFuncType().setReturnType(toType); } return getType(); }
// in src/org/python/indexer/ast/NFor.java
Override protected void bindNames(Scope s) throws Exception { bindNames(s, target, NameBinder.make()); }
// in src/org/python/indexer/ast/NFor.java
private void bindNames(Scope s, NNode target, NameBinder binder) throws Exception { if (target instanceof NName) { binder.bind(s, (NName)target, new NUnknownType()); return; } if (target instanceof NSequence) { for (NNode n : ((NSequence)target).getElements()) { bindNames(s, n, binder); } } }
// in src/org/python/indexer/ast/NFor.java
Override public NType resolve(Scope s) throws Exception { NameBinder.make().bindIter(s, target, iter); if (body == null) { setType(new NUnknownType()); } else { setType(resolveExpr(body, s)); } if (orelse != null) { addType(resolveExpr(orelse, s)); } return getType(); }
// in src/org/python/indexer/ast/NKeyword.java
Override public NType resolve(Scope s) throws Exception { return setType(resolveExpr(value, s)); }
// in src/org/python/indexer/ast/NDict.java
Override public NType resolve(Scope s) throws Exception { NType keyType = resolveListAsUnion(keys, s); NType valType = resolveListAsUnion(values, s); return setType(new NDictType(keyType, valType)); }
// in src/org/python/indexer/ast/NTryFinally.java
Override public NType resolve(Scope s) throws Exception { if (body != null) { setType(resolveExpr(body, s)); } if (finalbody != null) { addType(resolveExpr(finalbody, s)); } return getType(); }
// in src/org/python/indexer/Util.java
public static void writeFile(String path, String contents) throws Exception { PrintWriter out = null; try { out = new PrintWriter(new BufferedWriter(new FileWriter(path))); out.print(contents); out.flush(); } finally { if (out != null) { out.close(); } } }
// in src/org/python/indexer/Util.java
public static String readFile(String filename) throws Exception { return readFile(new File(filename)); }
// in src/org/python/indexer/Util.java
public static String readFile(File path) throws Exception { // Don't use line-oriented file read -- need to retain CRLF if present // so the style-run and link offsets are correct. return new String(getBytesFromFile(path), UTF_8); }
// in src/org/python/indexer/Util.java
public static String getMD5(File path) throws Exception { byte[] bytes = getBytesFromFile(path); return getMD5(bytes); }
// in src/org/python/indexer/Util.java
public static String getMD5(byte[] fileContents) throws Exception { MessageDigest algorithm = MessageDigest.getInstance("MD5"); algorithm.reset(); algorithm.update(fileContents); byte messageDigest[] = algorithm.digest(); StringBuilder sb = new StringBuilder(); for (int i = 0; i < messageDigest.length; i++) { sb.append(String.format("%02x", 0xFF & messageDigest[i])); } return sb.toString(); }
// in src/org/python/indexer/AstCache.java
public static AstCache get() throws Exception { if (INSTANCE == null) { INSTANCE = new AstCache(); } return INSTANCE; }
// in src/org/python/indexer/AstCache.java
public NModule getAST(String path) throws Exception { if (path == null) throw new IllegalArgumentException("null path"); return fetch(path); }
// in src/org/python/indexer/AstCache.java
public NModule getAST(String path, String contents) throws Exception { if (path == null) throw new IllegalArgumentException("null path"); if (contents == null) throw new IllegalArgumentException("null contents"); // Cache stores null value if the parse failed. if (cache.containsKey(path)) { return cache.get(path); } NModule mod = null; try { mod = parse(path, contents); if (mod != null) { mod.setFileAndMD5(path, Util.getMD5(contents.getBytes("UTF-8"))); } } finally { cache.put(path, mod); // may be null } return mod; }
// in src/org/python/indexer/AstCache.java
private NModule fetch(String path) throws Exception { // Cache stores null value if the parse failed. if (cache.containsKey(path)) { return cache.get(path); } // Might be cached on disk but not in memory. NModule mod = getSerializedModule(path); if (mod != null) { fine("reusing " + path); cache.put(path, mod); return mod; } try { mod = parse(path); } finally { cache.put(path, mod); // may be null } if (mod != null) { serialize(mod); } return mod; }
// in src/org/python/indexer/AstCache.java
private NModule parse(String path) throws Exception { fine("parsing " + path); mod ast = invokeANTLR(path); return generateAST(ast, path); }
// in src/org/python/indexer/AstCache.java
private NModule parse(String path, String contents) throws Exception { fine("parsing " + path); mod ast = invokeANTLR(path, contents); return generateAST(ast, path); }
// in src/org/python/indexer/AstCache.java
private NModule generateAST(mod ast, String path) throws Exception { if (ast == null) { Indexer.idx.reportFailedAssertion("ANTLR returned NULL for " + path); return null; } // Convert to indexer's AST. Type conversion warnings are harmless here. @SuppressWarnings("unchecked") Object obj = ast.accept(new AstConverter()); if (!(obj instanceof NModule)) { warn("\n[warning] converted AST is not a module: " + obj); return null; } NModule module = (NModule)obj; if (new File(path).canRead()) { module.setFile(path); } return module; }
// in src/org/python/indexer/AstCache.java
public String getCachePath(File sourcePath) throws Exception { return getCachePath(Util.getMD5(sourcePath), sourcePath.getName()); }
// in src/org/python/indexer/AstCache.java
void serialize(NModule ast) throws Exception { String path = getCachePath(ast.getMD5(), new File(ast.getFile()).getName()); ObjectOutputStream oos = null; FileOutputStream fos = null; try { fos = new FileOutputStream(path); oos = new ObjectOutputStream(fos); oos.writeObject(ast); } finally { if (oos != null) { oos.close(); } else if (fos != null) { fos.close(); } } }
// in src/org/python/indexer/AstCache.java
NModule deserialize(File sourcePath) throws Exception { String cachePath = getCachePath(sourcePath); FileInputStream fis = null; ObjectInputStream ois = null; try { fis = new FileInputStream(cachePath); ois = new ObjectInputStream(fis); NModule mod = (NModule)ois.readObject(); // Files in different dirs may have the same base name and contents. mod.setFile(sourcePath); return mod; } finally { if (ois != null) { ois.close(); } else if (fis != null) { fis.close(); } } }
// in src/org/python/indexer/demos/HtmlDemo.java
private void makeOutputDir() throws Exception { if (!OUTPUT_DIR.exists()) { OUTPUT_DIR.mkdirs(); info("created directory: " + OUTPUT_DIR.getAbsolutePath()); } }
// in src/org/python/indexer/demos/HtmlDemo.java
private void start(File stdlib, File fileOrDir) throws Exception { rootDir = fileOrDir.isFile() ? fileOrDir.getParentFile() : fileOrDir; rootPath = rootDir.getCanonicalPath(); indexer = new Indexer(); indexer.addPath(stdlib.getCanonicalPath()); info("building index..."); indexer.loadFileRecursive(fileOrDir.getCanonicalPath()); indexer.ready(); info(indexer.getStatusReport()); generateHtml(); }
// in src/org/python/indexer/demos/HtmlDemo.java
private void generateHtml() throws Exception { info("generating html..."); makeOutputDir(); linker = new Linker(rootPath, OUTPUT_DIR); linker.findLinks(indexer); int rootLength = rootPath.length(); for (String path : indexer.getLoadedFiles()) { if (!path.startsWith(rootPath)) { continue; } File destFile = Util.joinPath(OUTPUT_DIR, path.substring(rootLength)); destFile.getParentFile().mkdirs(); String destPath = destFile.getAbsolutePath() + ".html"; String html = markup(path); Util.writeFile(destPath, html); } info("wrote " + indexer.getLoadedFiles().size() + " files to " + OUTPUT_DIR); }
// in src/org/python/indexer/demos/HtmlDemo.java
private String markup(String path) throws Exception { String source = Util.readFile(path); List<StyleRun> styles = new Styler(indexer, linker).addStyles(path, source); styles.addAll(linker.getStyles(path)); source = new StyleApplier(path, source, styles).apply(); String outline = new HtmlOutline(indexer).generate(path); return "<html><head title=\"" + path + "\">" + "<style type='text/css'>\n" + CSS + "</style>\n" + "</head>\n<body>\n" + "<table width=100% border='1px solid gray'><tr><td valign='top'>" + outline + "</td><td>" + "<pre>" + addLineNumbers(source) + "</pre>" + "</td></tr></table></body></html>"; }
// in src/org/python/indexer/demos/HtmlDemo.java
public static void main(String[] args) throws Exception { if (args.length != 2) { usage(); } File fileOrDir = checkFile(args[1]); File stdlib = checkFile(args[0]); if (!stdlib.isDirectory()) { abort("Not a directory: " + stdlib); } new HtmlDemo().start(stdlib, fileOrDir); }
// in src/org/python/indexer/demos/HtmlOutline.java
public String generate(String path) throws Exception { buffer = new StringBuilder(1024); List<Outliner.Entry> entries = indexer.generateOutline(path); addOutline(entries); String html = buffer.toString(); buffer = null; return html; }
// in src/org/python/indexer/demos/Styler.java
public List<StyleRun> addStyles(String path, String src) throws Exception { this.path = path; source = src; NModule m = indexer.getAstForFile(path); if (m != null) { m.visit(this); highlightLexicalTokens(); } return styles; }
// in src/org/python/compiler/ProxyMaker.java
public void doConstants() throws Exception { Code code = classfile.addMethod("<clinit>", makeSig("V"), Modifier.STATIC); code.return_(); }
// in src/org/python/compiler/ProxyMaker.java
public static void doReturn(Code code, Class<?> type) throws Exception { switch (getType(type)) { case tNone: break; case tCharacter: case tBoolean: case tByte: case tShort: case tInteger: code.ireturn(); break; case tLong: code.lreturn(); break; case tFloat: code.freturn(); break; case tDouble: code.dreturn(); break; case tVoid: code.return_(); break; default: code.areturn(); break; } }
// in src/org/python/compiler/ProxyMaker.java
public static void doNullReturn(Code code, Class<?> type) throws Exception { switch (getType(type)) { case tNone: break; case tCharacter: case tBoolean: case tByte: case tShort: case tInteger: code.iconst_0(); code.ireturn(); break; case tLong: code.lconst_0(); code.lreturn(); break; case tFloat: code.fconst_0(); code.freturn(); break; case tDouble: code.dconst_0(); code.dreturn(); break; case tVoid: code.return_(); break; default: code.aconst_null(); code.areturn(); break; } }
// in src/org/python/compiler/ProxyMaker.java
public void callSuper(Code code, String name, String superclass, Class<?>[] parameters, Class<?> ret, String sig) throws Exception { code.aload(0); int local_index; int i; for (i=0, local_index=1; i<parameters.length; i++) { switch(getType(parameters[i])) { case tCharacter: case tBoolean: case tByte: case tShort: case tInteger: code.iload(local_index); local_index += 1; break; case tLong: code.lload(local_index); local_index += 2; break; case tFloat: code.fload(local_index); local_index += 1; break; case tDouble: code.dload(local_index); local_index += 2; break; default: code.aload(local_index); local_index += 1; break; } } code.invokespecial(superclass, name, sig); doReturn(code, ret); }
// in src/org/python/compiler/ProxyMaker.java
public void doJavaCall(Code code, String name, String type, String jcallName) throws Exception { code.invokevirtual("org/python/core/PyObject", jcallName, makeSig($pyObj, $objArr)); code.invokestatic("org/python/core/Py", "py2"+name, makeSig(type, $pyObj)); }
// in src/org/python/compiler/ProxyMaker.java
public void getArgs(Code code, Class<?>[] parameters) throws Exception { if (parameters.length == 0) { code.getstatic("org/python/core/Py", "EmptyObjects", $pyObjArr); } else { code.iconst(parameters.length); code.anewarray("java/lang/Object"); int array = code.getLocal("[org/python/core/PyObject"); code.astore(array); int local_index; int i; for (i=0, local_index=1; i<parameters.length; i++) { code.aload(array); code.iconst(i); switch (getType(parameters[i])) { case tBoolean: case tByte: case tShort: case tInteger: code.iload(local_index); local_index += 1; code.invokestatic("org/python/core/Py", "newInteger", "(I)" + $pyInteger); break; case tLong: code.lload(local_index); local_index += 2; code.invokestatic("org/python/core/Py", "newInteger", "(J)" + $pyObj); break; case tFloat: code.fload(local_index); local_index += 1; code.invokestatic("org/python/core/Py", "newFloat", "(F)" + $pyFloat); break; case tDouble: code.dload(local_index); local_index += 2; code.invokestatic("org/python/core/Py", "newFloat", "(D)" + $pyFloat); break; case tCharacter: code.iload(local_index); local_index += 1; code.invokestatic("org/python/core/Py", "newString", "(C)" + $pyStr); break; default: code.aload(local_index); local_index += 1; break; } code.aastore(); } code.aload(array); } }
// in src/org/python/compiler/ProxyMaker.java
public void callMethod(Code code, String name, Class<?>[] parameters, Class<?> ret, Class<?>[] exceptions) throws Exception { Label start = null; Label end = null; String jcallName = "_jcall"; int instLocal = 0; if (exceptions.length > 0) { start = new Label(); end = new Label(); jcallName = "_jcallexc"; instLocal = code.getLocal("org/python/core/PyObject"); code.astore(instLocal); code.label(start); code.aload(instLocal); } getArgs(code, parameters); switch (getType(ret)) { case tCharacter: doJavaCall(code, "char", "C", jcallName); break; case tBoolean: doJavaCall(code, "boolean", "Z", jcallName); break; case tByte: case tShort: case tInteger: doJavaCall(code, "int", "I", jcallName); break; case tLong: doJavaCall(code, "long", "J", jcallName); break; case tFloat: doJavaCall(code, "float", "F", jcallName); break; case tDouble: doJavaCall(code, "double", "D", jcallName); break; case tVoid: doJavaCall(code, "void", "V", jcallName); break; default: code.invokevirtual("org/python/core/PyObject", jcallName, makeSig($pyObj, $objArr)); code.ldc(ret.getName()); code.invokestatic("java/lang/Class","forName", makeSig($clss, $str)); code.invokestatic("org/python/core/Py", "tojava", makeSig($obj, $pyObj, $clss)); // I guess I need this checkcast to keep the verifier happy code.checkcast(mapClass(ret)); break; } if (end != null) { code.label(end); } doReturn(code, ret); if (exceptions.length > 0) { boolean throwableFound = false; Label handlerStart = null; for (Class<?> exception : exceptions) { handlerStart = new Label(); code.label(handlerStart); int excLocal = code.getLocal("java/lang/Throwable"); code.astore(excLocal); code.aload(excLocal); code.athrow(); code.visitTryCatchBlock(start, end, handlerStart, mapClass(exception)); doNullReturn(code, ret); code.freeLocal(excLocal); if (exception == Throwable.class) throwableFound = true; } if (!throwableFound) { // The final catch (Throwable) handlerStart = new Label(); code.label(handlerStart); int excLocal = code.getLocal("java/lang/Throwable"); code.astore(excLocal); code.aload(instLocal); code.aload(excLocal); code.invokevirtual("org/python/core/PyObject", "_jthrow", makeSig("V", $throwable)); code.visitTryCatchBlock(start, end, handlerStart, "java/lang/Throwable"); code.freeLocal(excLocal); doNullReturn(code, ret); } code.freeLocal(instLocal); } }
// in src/org/python/compiler/ProxyMaker.java
public void addMethod(Method method, int access) throws Exception { boolean isAbstract = false; if (Modifier.isAbstract(access)) { access = access & ~Modifier.ABSTRACT; isAbstract = true; } Class<?>[] parameters = method.getParameterTypes(); Class<?> ret = method.getReturnType(); String sig = makeSig(ret, parameters); String name = method.getName(); names.add(name); Code code = classfile.addMethod(name, sig, access); code.aload(0); code.ldc(name); if (!isAbstract) { int tmp = code.getLocal("org/python/core/PyObject"); code.invokestatic("org/python/compiler/ProxyMaker", "findPython", makeSig($pyObj, $pyProxy, $str)); code.astore(tmp); code.aload(tmp); Label callPython = new Label(); code.ifnonnull(callPython); String superClass = mapClass(method.getDeclaringClass()); callSuper(code, name, superClass, parameters, ret, sig); code.label(callPython); code.aload(tmp); callMethod(code, name, parameters, ret, method.getExceptionTypes()); addSuperMethod("super__"+name, name, superClass, parameters, ret, sig, access); } else { code.invokestatic("org/python/compiler/ProxyMaker", "findPython", makeSig($pyObj, $pyProxy, $str)); code.dup(); Label returnNull = new Label(); code.ifnull(returnNull); callMethod(code, name, parameters, ret, method.getExceptionTypes()); code.label(returnNull); code.pop(); doNullReturn(code, ret); } }
// in src/org/python/compiler/ProxyMaker.java
protected void addMethods(Class<?> c, Set<String> t) throws Exception { Method[] methods = c.getDeclaredMethods(); for (Method method : methods) { if (!t.add(methodString(method))) { continue; } int access = method.getModifiers(); if (Modifier.isStatic(access) || Modifier.isPrivate(access)) { continue; } if (Modifier.isNative(access)) { access = access & ~Modifier.NATIVE; } if (Modifier.isProtected(access)) { access = (access & ~Modifier.PROTECTED) | Modifier.PUBLIC; if (Modifier.isFinal(access)) { addSuperMethod(method, access); continue; } } else if (Modifier.isFinal(access)) { continue; } else if (!Modifier.isPublic(access)) { continue; // package protected by process of elimination; we can't override } addMethod(method, access); } Class<?> sc = c.getSuperclass(); if (sc != null) { addMethods(sc, t); } for (Class<?> iface : c.getInterfaces()) { addMethods(iface, t); } }
// in src/org/python/compiler/ProxyMaker.java
public void addConstructor(String name, Class<?>[] parameters, Class<?> ret, String sig, int access) throws Exception { Code code = classfile.addMethod("<init>", sig, access); callSuper(code, "<init>", name, parameters, Void.TYPE, sig); }
// in src/org/python/compiler/ProxyMaker.java
public void addConstructors(Class<?> c) throws Exception { Constructor<?>[] constructors = c.getDeclaredConstructors(); String name = mapClass(c); for (Constructor<?> constructor : constructors) { int access = constructor.getModifiers(); if (Modifier.isPrivate(access)) { continue; } if (Modifier.isNative(access)) { access = access & ~Modifier.NATIVE; } if (Modifier.isProtected(access)) { access = access & ~Modifier.PROTECTED | Modifier.PUBLIC; } Class<?>[] parameters = constructor.getParameterTypes(); addConstructor(name, parameters, Void.TYPE, makeSig(Void.TYPE, parameters), access); } }
// in src/org/python/compiler/ProxyMaker.java
public void addSuperMethod(Method method, int access) throws Exception { Class<?>[] parameters = method.getParameterTypes(); Class<?> ret = method.getReturnType(); String superClass = mapClass(method.getDeclaringClass()); String superName = method.getName(); String methodName = superName; if (Modifier.isFinal(access)) { methodName = "super__" + superName; access &= ~Modifier.FINAL; } addSuperMethod(methodName, superName, superClass, parameters, ret, makeSig(ret, parameters), access); }
// in src/org/python/compiler/ProxyMaker.java
public void addSuperMethod(String methodName, String superName, String declClass, Class<?>[] parameters, Class<?> ret, String sig, int access) throws Exception { if (methodName.startsWith("super__")) { /* rationale: JC java-class, P proxy-class subclassing JC in order to avoid infinite recursion P should define super__foo only if no class between P and JC in the hierarchy defines it yet; this means that the python class needing P is the first that redefines the JC method foo. */ try { superclass.getMethod(methodName, parameters); return; } catch (NoSuchMethodException e) { // OK, no one else defines it, so we need to } catch (SecurityException e) { return; } } supernames.add(methodName); Code code = classfile.addMethod(methodName, sig, access); callSuper(code, superName, declClass, parameters, ret, sig); }
// in src/org/python/compiler/ProxyMaker.java
public void addProxy() throws Exception { // implement PyProxy interface classfile.addField("__proxy", $pyObj, Modifier.PROTECTED); // setProxy methods Code code = classfile.addMethod("_setPyInstance", makeSig("V", $pyObj), Modifier.PUBLIC); code.aload(0); code.aload(1); code.putfield(classfile.name, "__proxy", $pyObj); code.return_(); // getProxy method code = classfile.addMethod("_getPyInstance", makeSig($pyObj), Modifier.PUBLIC); code.aload(0); code.getfield(classfile.name, "__proxy", $pyObj); code.areturn(); String pySys = "Lorg/python/core/PySystemState;"; // implement PyProxy interface classfile.addField("__systemState", pySys, Modifier.PROTECTED | Modifier.TRANSIENT); // setProxy method code = classfile.addMethod("_setPySystemState", makeSig("V", pySys), Modifier.PUBLIC); code.aload(0); code.aload(1); code.putfield(classfile.name, "__systemState", pySys); code.return_(); // getProxy method code = classfile.addMethod("_getPySystemState", makeSig(pySys), Modifier.PUBLIC); code.aload(0); code.getfield(classfile.name, "__systemState", pySys); code.areturn(); }
// in src/org/python/compiler/ProxyMaker.java
public void addClassDictInit() throws Exception { // classDictInit method classfile.addInterface(mapClass(org.python.core.ClassDictInit.class)); Code code = classfile.addMethod("classDictInit", makeSig("V", $pyObj), Modifier.PUBLIC | Modifier.STATIC); code.aload(0); code.ldc("__supernames__"); int strArray = CodeCompiler.makeStrings(code, supernames); code.aload(strArray); code.freeLocal(strArray); code.invokestatic("org/python/core/Py", "java2py", makeSig($pyObj, $obj)); code.invokevirtual("org/python/core/PyObject", "__setitem__", makeSig("V", $str, $pyObj)); code.return_(); }
// in src/org/python/compiler/ProxyMaker.java
public void build(OutputStream out) throws Exception { build(); classfile.write(out); }
// in src/org/python/compiler/ProxyMaker.java
public void build() throws Exception { names = Generic.set(); int access = superclass.getModifiers(); if ((access & Modifier.FINAL) != 0) { throw new InstantiationException("can't subclass final class"); } access = Modifier.PUBLIC | Modifier.SYNCHRONIZED; classfile = new ClassFile(myClass, mapClass(superclass), access); addProxy(); addConstructors(superclass); classfile.addInterface("org/python/core/PyProxy"); Set<String> seenmethods = Generic.set(); addMethods(superclass, seenmethods); for (Class<?> iface : interfaces) { if (iface.isAssignableFrom(superclass)) { Py.writeWarning("compiler", "discarding redundant interface: " + iface.getName()); continue; } classfile.addInterface(mapClass(iface)); addMethods(iface, seenmethods); } doConstants(); addClassDictInit(); }
// in src/org/python/compiler/AdapterMaker.java
Override public void build() throws Exception { names = Generic.set(); int access = Opcodes.ACC_PUBLIC | Opcodes.ACC_SYNCHRONIZED; classfile = new ClassFile(myClass, "java/lang/Object", access); classfile.addInterface(mapClass(interfaces[0])); addMethods(interfaces[0], new HashSet<String>()); addConstructors(Object.class); doConstants(); }
// in src/org/python/compiler/AdapterMaker.java
Override public void doConstants() throws Exception { for (String name : names) { classfile.addField(name, $pyObj, Opcodes.ACC_PUBLIC); } }
// in src/org/python/compiler/AdapterMaker.java
Override public void addMethod(Method method, int access) throws Exception { Class<?>[] parameters = method.getParameterTypes(); Class<?> ret = method.getReturnType(); String name = method.getName(); names.add(name); Code code = classfile.addMethod(name, makeSig(ret, parameters), Opcodes.ACC_PUBLIC); code.aload(0); code.getfield(classfile.name, name, $pyObj); code.dup(); Label returnNull = new Label(); code.ifnull(returnNull); callMethod(code, name, parameters, ret, method.getExceptionTypes()); code.label(returnNull); doNullReturn(code, ret); }
// in src/org/python/compiler/ScopeInfo.java
public void cook(ScopeInfo up, int distance, CompilationContext ctxt) throws Exception { if(up == null) return; // top level => nop this.up = up; this.distance = distance; boolean func = kind == FUNCSCOPE; Vector<String> purecells = new Vector<String>(); cell = 0; boolean some_inner_free = inner_free.size() > 0; for (Enumeration e = inner_free.keys(); e.hasMoreElements(); ) { String name = (String)e.nextElement(); SymInfo info = tbl.get(name); if (info == null) { tbl.put(name,new SymInfo(FREE)); continue; } int flags = info.flags; if (func) { // not func global and bound ? if ((flags&NGLOBAL) == 0 && (flags&BOUND) != 0) { info.flags |= CELL; if ((info.flags&PARAM) != 0) jy_paramcells.addElement(name); cellvars.addElement(name); info.env_index = cell++; if ((flags&PARAM) == 0) purecells.addElement(name); continue; } } else { info.flags |= FREE; } } boolean some_free = false; boolean nested = up.kind != TOPSCOPE; for (Map.Entry<String, SymInfo> entry : tbl.entrySet()) { String name = entry.getKey(); SymInfo info = entry.getValue(); int flags = info.flags; if (nested && (flags&FREE) != 0) up.inner_free.put(name,PRESENT); if ((flags&(GLOBAL|PARAM|CELL)) == 0) { if ((flags&BOUND) != 0) { // ?? only func // System.err.println("local: "+name); names.addElement(name); info.locals_index = local++; continue; } info.flags |= FREE; some_free = true; if (nested) up.inner_free.put(name,PRESENT); } } if ((jy_npurecell = purecells.size()) > 0) { int sz = purecells.size(); for (int i = 0; i < sz; i++) { names.addElement(purecells.elementAt(i)); } } if (some_free && nested) { up.contains_ns_free_vars = true; } // XXX - this doesn't catch all cases - may depend subtly // on how visiting NOW works with antlr compared to javacc if ((unqual_exec || from_import_star)) { if(some_inner_free) dynastuff_trouble(true, ctxt); else if(func_level > 1 && some_free) dynastuff_trouble(false, ctxt); } }
// in src/org/python/compiler/ScopeInfo.java
private void dynastuff_trouble(boolean inner_free, CompilationContext ctxt) throws Exception { StringBuilder illegal = new StringBuilder(); if (unqual_exec && from_import_star) { illegal.append("function '") .append(scope_name) .append("' uses import * and bare exec, which are illegal"); } else if (unqual_exec) { illegal.append("unqualified exec is not allowed in function '") .append(scope_name) .append("'"); } else { illegal.append("import * is not allowed in function '").append(scope_name).append("'"); } if (inner_free) { illegal.append(" because it contains a function with free variables"); } else { illegal.append(" because it contains free variables"); } ctxt.error(illegal.toString(), true, scope_node); }
// in src/org/python/compiler/Future.java
private boolean check(ImportFrom cand) throws Exception { if (!cand.getInternalModule().equals(FutureFeature.MODULE_NAME)) return false; if (cand.getInternalNames().isEmpty()) { throw new ParseException( "future statement does not support import *", cand); } try { for (alias feature : cand.getInternalNames()) { // *known* features FutureFeature.addFeature(feature.getInternalName(), features); } } catch (ParseException pe) { throw new ParseException(pe.getMessage(), cand); } return true; }
// in src/org/python/compiler/Future.java
public void preprocessFutures(mod node, org.python.core.CompilerFlags cflags) throws Exception { if (cflags != null) { if (cflags.isFlagSet(CodeFlag.CO_FUTURE_DIVISION)) FutureFeature.division.addTo(features); if (cflags.isFlagSet(CodeFlag.CO_FUTURE_WITH_STATEMENT)) FutureFeature.with_statement.addTo(features); if (cflags.isFlagSet(CodeFlag.CO_FUTURE_ABSOLUTE_IMPORT)) FutureFeature.absolute_import.addTo(features); } int beg = 0; List<stmt> suite = null; if (node instanceof Module) { suite = ((Module) node).getInternalBody(); if (suite.size() > 0 && suite.get(0) instanceof Expr && ((Expr) suite.get(0)).getInternalValue() instanceof Str) { beg++; } } else if (node instanceof Interactive) { suite = ((Interactive) node).getInternalBody(); } else { return; } for (int i = beg; i < suite.size(); i++) { stmt s = suite.get(i); if (!(s instanceof ImportFrom)) break; s.from_future_checked = true; if (!check((ImportFrom) s)) break; } if (cflags != null) { for (FutureFeature feature : featureSet) { feature.setFlag(cflags); } } }
// in src/org/python/compiler/Future.java
public static void checkFromFuture(ImportFrom node) throws Exception { if (node.from_future_checked) return; if (node.getInternalModule().equals(FutureFeature.MODULE_NAME)) { throw new ParseException("from __future__ imports must occur " + "at the beginning of the file", node); } node.from_future_checked = true; }
// in src/org/python/compiler/CodeCompiler.java
public void loadFrame() throws Exception { code.aload(1); }
// in src/org/python/compiler/CodeCompiler.java
public void loadThreadState() throws Exception { code.aload(2); }
// in src/org/python/compiler/CodeCompiler.java
public void setLastI(int idx) throws Exception { loadFrame(); code.iconst(idx); code.putfield(p(PyFrame.class), "f_lasti", "I"); }
// in src/org/python/compiler/CodeCompiler.java
private void loadf_back() throws Exception { code.getfield(p(PyFrame.class), "f_back", ci(PyFrame.class)); }
// in src/org/python/compiler/CodeCompiler.java
public int storeTop() throws Exception { int tmp = code.getLocal(p(PyObject.class)); code.astore(tmp); return tmp; }
// in src/org/python/compiler/CodeCompiler.java
public void setline(int line) throws Exception { if (module.linenumbers) { code.setline(line); loadFrame(); code.iconst(line); code.invokevirtual(p(PyFrame.class), "setline", sig(Void.TYPE, Integer.TYPE)); } }
// in src/org/python/compiler/CodeCompiler.java
public void setline(PythonTree node) throws Exception { setline(node.getLine()); }
// in src/org/python/compiler/CodeCompiler.java
public void set(PythonTree node) throws Exception { int tmp = storeTop(); set(node, tmp); code.aconst_null(); code.astore(tmp); code.freeLocal(tmp); }
// in src/org/python/compiler/CodeCompiler.java
public void set(PythonTree node, int tmp) throws Exception { temporary = tmp; visit(node); }
// in src/org/python/compiler/CodeCompiler.java
private void saveAugTmps(PythonTree node, int count) throws Exception { if (count >= 4) { augtmp4 = code.getLocal(ci(PyObject.class)); code.astore(augtmp4); } if (count >= 3) { augtmp3 = code.getLocal(ci(PyObject.class)); code.astore(augtmp3); } if (count >= 2) { augtmp2 = code.getLocal(ci(PyObject.class)); code.astore(augtmp2); } augtmp1 = code.getLocal(ci(PyObject.class)); code.astore(augtmp1); code.aload(augtmp1); if (count >= 2) { code.aload(augtmp2); } if (count >= 3) { code.aload(augtmp3); } if (count >= 4) { code.aload(augtmp4); } }
// in src/org/python/compiler/CodeCompiler.java
private void restoreAugTmps(PythonTree node, int count) throws Exception { code.aload(augtmp1); code.freeLocal(augtmp1); if (count == 1) { return; } code.aload(augtmp2); code.freeLocal(augtmp2); if (count == 2) { return; } code.aload(augtmp3); code.freeLocal(augtmp3); if (count == 3) { return; } code.aload(augtmp4); code.freeLocal(augtmp4); }
// in src/org/python/compiler/CodeCompiler.java
void parse(mod node, Code code, boolean fast_locals, String className, Str classDoc, boolean classBody, ScopeInfo scope, CompilerFlags cflags) throws Exception { this.fast_locals = fast_locals; this.className = className; this.code = code; this.cflags = cflags; this.my_scope = scope; this.tbl = scope.tbl; //BEGIN preparse if (classBody) { // Set the class's __module__ to __name__. fails when there's no __name__ loadFrame(); code.ldc("__module__"); loadFrame(); code.ldc("__name__"); code.invokevirtual(p(PyFrame.class), "getname", sig(PyObject.class, String.class)); code.invokevirtual(p(PyFrame.class), "setlocal", sig(Void.TYPE, String.class, PyObject.class)); if (classDoc != null) { loadFrame(); code.ldc("__doc__"); visit(classDoc); code.invokevirtual(p(PyFrame.class), "setlocal", sig(Void.TYPE, String.class, PyObject.class)); } } Label genswitch = new Label(); if (my_scope.generator) { code.goto_(genswitch); } Label start = new Label(); code.label(start); int nparamcell = my_scope.jy_paramcells.size(); if (nparamcell > 0) { java.util.List<String> paramcells = my_scope.jy_paramcells; for (int i = 0; i < nparamcell; i++) { code.aload(1); SymInfo syminf = tbl.get(paramcells.get(i)); code.iconst(syminf.locals_index); code.iconst(syminf.env_index); code.invokevirtual(p(PyFrame.class), "to_cell", sig(Void.TYPE, Integer.TYPE, Integer.TYPE)); } } //END preparse optimizeGlobals = checkOptimizeGlobals(fast_locals, my_scope); if (my_scope.max_with_count > 0) { // allocate for all the with-exits we will have in the frame; // this allows yield and with to happily co-exist loadFrame(); code.iconst(my_scope.max_with_count); code.anewarray(p(PyObject.class)); code.putfield(p(PyFrame.class), "f_exits", ci(PyObject[].class)); } Object exit = visit(node); if (classBody) { loadFrame(); code.invokevirtual(p(PyFrame.class), "getf_locals", sig(PyObject.class)); code.areturn(); } else { if (exit == null) { setLastI(-1); getNone(); code.areturn(); } } //BEGIN postparse // similar to visitResume code in pyasm.py if (my_scope.generator) { code.label(genswitch); code.aload(1); code.getfield(p(PyFrame.class), "f_lasti", "I"); Label[] y = new Label[yields.size() + 1]; y[0] = start; for (int i = 1; i < y.length; i++) { y[i] = yields.get(i - 1); } code.tableswitch(0, y.length - 1, start, y); } //END postparse }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitInteractive(Interactive node) throws Exception { traverse(node); return null; }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitModule(org.python.antlr.ast.Module suite) throws Exception { Str docStr = getDocStr(suite.getInternalBody()); if (docStr != null) { loadFrame(); code.ldc("__doc__"); visit(docStr); code.invokevirtual(p(PyFrame.class), "setglobal", sig(Void.TYPE, String.class, PyObject.class)); } traverse(suite); return null; }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitExpression(Expression node) throws Exception { if (my_scope.generator && node.getInternalBody() != null) { module.error("'return' with argument inside generator", true, node); } return visitReturn(new Return(node, node.getInternalBody()), true); }
// in src/org/python/compiler/CodeCompiler.java
public int makeArray(java.util.List<? extends PythonTree> nodes) throws Exception { // XXX: This should produce an array on the stack (if possible) instead of a local // the caller is responsible for freeing. int n; if (nodes == null) { n = 0; } else { n = nodes.size(); } int array = code.getLocal(ci(PyObject[].class)); if (n == 0) { code.getstatic(p(Py.class), "EmptyObjects", ci(PyObject[].class)); code.astore(array); } else { code.iconst(n); code.anewarray(p(PyObject.class)); code.astore(array); for (int i = 0; i < n; i++) { visit(nodes.get(i)); code.aload(array); code.swap(); code.iconst(i); code.swap(); code.aastore(); } } return array; }
// in src/org/python/compiler/CodeCompiler.java
public boolean makeClosure(ScopeInfo scope) throws Exception { if (scope == null || scope.freevars == null) { return false; } int n = scope.freevars.size(); if (n == 0) { return false; } int tmp = code.getLocal(ci(PyObject[].class)); code.iconst(n); code.anewarray(p(PyObject.class)); code.astore(tmp); Map<String, SymInfo> upTbl = scope.up.tbl; for (int i = 0; i < n; i++) { code.aload(tmp); code.iconst(i); loadFrame(); for (int j = 1; j < scope.distance; j++) { loadf_back(); } SymInfo symInfo = upTbl.get(scope.freevars.elementAt(i)); code.iconst(symInfo.env_index); code.invokevirtual(p(PyFrame.class), "getclosure", sig(PyObject.class, Integer.TYPE)); code.aastore(); } code.aload(tmp); code.freeLocal(tmp); return true; }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitFunctionDef(FunctionDef node) throws Exception { String name = getName(node.getInternalName()); setline(node); ScopeInfo scope = module.getScopeInfo(node); // NOTE: this is attached to the constructed PyFunction, so it cannot be nulled out // with freeArray, unlike other usages of makeArray here int defaults = makeArray(scope.ac.getDefaults()); code.new_(p(PyFunction.class)); code.dup(); loadFrame(); code.getfield(p(PyFrame.class), "f_globals", ci(PyObject.class)); code.aload(defaults); code.freeLocal(defaults); scope.setup_closure(); scope.dump(); module.codeConstant(new Suite(node, node.getInternalBody()), name, true, className, false, false, node.getLine(), scope, cflags).get(code); Str docStr = getDocStr(node.getInternalBody()); if (docStr != null) { visit(docStr); } else { code.aconst_null(); } if (!makeClosure(scope)) { code.invokespecial(p(PyFunction.class), "<init>", sig(Void.TYPE, PyObject.class, PyObject[].class, PyCode.class, PyObject.class)); } else { code.invokespecial(p(PyFunction.class), "<init>", sig(Void.TYPE, PyObject.class, PyObject[].class, PyCode.class, PyObject.class, PyObject[].class)); } applyDecorators(node.getInternalDecorator_list()); set(new Name(node, node.getInternalName(), expr_contextType.Store)); return null; }
// in src/org/python/compiler/CodeCompiler.java
private void applyDecorators(java.util.List<expr> decorators) throws Exception { if (decorators != null && !decorators.isEmpty()) { int res = storeTop(); for (expr decorator : decorators) { visit(decorator); stackProduce(); } for (int i = decorators.size(); i > 0; i--) { stackConsume(); loadThreadState(); code.aload(res); code.invokevirtual(p(PyObject.class), "__call__", sig(PyObject.class, ThreadState.class, PyObject.class)); code.astore(res); } code.aload(res); code.freeLocal(res); } }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitExpr(Expr node) throws Exception { setline(node); visit(node.getInternalValue()); if (print_results) { code.invokestatic(p(Py.class), "printResult", sig(Void.TYPE, PyObject.class)); } else { code.pop(); } return null; }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitAssign(Assign node) throws Exception { setline(node); visit(node.getInternalValue()); if (node.getInternalTargets().size() == 1) { set(node.getInternalTargets().get(0)); } else { int tmp = storeTop(); for (expr target : node.getInternalTargets()) { set(target, tmp); } code.freeLocal(tmp); } return null; }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitPrint(Print node) throws Exception { setline(node); int tmp = -1; if (node.getInternalDest() != null) { visit(node.getInternalDest()); tmp = storeTop(); } if (node.getInternalValues() == null || node.getInternalValues().size() == 0) { if (node.getInternalDest() != null) { code.aload(tmp); code.invokestatic(p(Py.class), "printlnv", sig(Void.TYPE, PyObject.class)); } else { code.invokestatic(p(Py.class), "println", sig(Void.TYPE)); } } else { for (int i = 0; i < node.getInternalValues().size(); i++) { if (node.getInternalDest() != null) { code.aload(tmp); visit(node.getInternalValues().get(i)); if (node.getInternalNl() && i == node.getInternalValues().size() - 1) { code.invokestatic(p(Py.class), "println", sig(Void.TYPE, PyObject.class, PyObject.class)); } else { code.invokestatic(p(Py.class), "printComma", sig(Void.TYPE, PyObject.class, PyObject.class)); } } else { visit(node.getInternalValues().get(i)); if (node.getInternalNl() && i == node.getInternalValues().size() - 1) { code.invokestatic(p(Py.class), "println", sig(Void.TYPE, PyObject.class)); } else { code.invokestatic(p(Py.class), "printComma", sig(Void.TYPE, PyObject.class)); } } } } if (node.getInternalDest() != null) { code.freeLocal(tmp); } return null; }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitDelete(Delete node) throws Exception { setline(node); traverse(node); return null; }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitPass(Pass node) throws Exception { setline(node); return null; }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitBreak(Break node) throws Exception { //setline(node); Not needed here... if (breakLabels.empty()) { throw new ParseException("'break' outside loop", node); } doFinallysDownTo(bcfLevel); code.goto_(breakLabels.peek()); return null; }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitContinue(Continue node) throws Exception { //setline(node); Not needed here... if (continueLabels.empty()) { throw new ParseException("'continue' not properly in loop", node); } doFinallysDownTo(bcfLevel); code.goto_(continueLabels.peek()); return Exit; }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitYield(Yield node) throws Exception { setline(node); if (!fast_locals) { throw new ParseException("'yield' outside function", node); } int stackState = saveStack(); if (node.getInternalValue() != null) { visit(node.getInternalValue()); } else { getNone(); } setLastI(++yield_count); saveLocals(); code.areturn(); Label restart = new Label(); yields.addElement(restart); code.label(restart); restoreLocals(); restoreStack(stackState); loadFrame(); code.invokevirtual(p(PyFrame.class), "getGeneratorInput", sig(Object.class)); code.dup(); code.instanceof_(p(PyException.class)); Label done2 = new Label(); code.ifeq(done2); code.checkcast(p(Throwable.class)); code.athrow(); code.label(done2); code.checkcast(p(PyObject.class)); return null; }
// in src/org/python/compiler/CodeCompiler.java
private int saveStack() throws Exception { if (stack.size() > 0) { int array = code.getLocal(ci(Object[].class)); code.iconst(stack.size()); code.anewarray(p(Object.class)); code.astore(array); ListIterator<String> content = stack.listIterator(stack.size()); for (int i = 0; content.hasPrevious(); i++) { String signature = content.previous(); if (p(ThreadState.class).equals(signature)) { // Stack: ... threadstate code.pop(); // Stack: ... } else { code.aload(array); // Stack: |- ... value array code.swap(); code.iconst(i++); code.swap(); // Stack: |- ... array index value code.aastore(); // Stack: |- ... } } return array; } else { return -1; } }
// in src/org/python/compiler/CodeCompiler.java
private void restoreStack(int array) throws Exception { if (stack.size() > 0) { int i = stack.size() - 1; for (String signature : stack) { if (p(ThreadState.class).equals(signature)) { loadThreadState(); } else { code.aload(array); // Stack: |- ... array code.iconst(i--); code.aaload(); // Stack: |- ... value code.checkcast(signature); } } code.freeLocal(array); } }
// in src/org/python/compiler/CodeCompiler.java
private void restoreLocals() throws Exception { endExceptionHandlers(); Vector<String> v = code.getActiveLocals(); loadFrame(); code.getfield(p(PyFrame.class), "f_savedlocals", ci(Object[].class)); int locals = code.getLocal(ci(Object[].class)); code.astore(locals); for (int i = 0; i < v.size(); i++) { String type = v.elementAt(i); if (type == null) { continue; } code.aload(locals); code.iconst(i); code.aaload(); code.checkcast(type); code.astore(i); } code.freeLocal(locals); restartExceptionHandlers(); }
// in src/org/python/compiler/CodeCompiler.java
private void saveLocals() throws Exception { Vector<String> v = code.getActiveLocals(); code.iconst(v.size()); code.anewarray(p(Object.class)); int locals = code.getLocal(ci(Object[].class)); code.astore(locals); for (int i = 0; i < v.size(); i++) { String type = v.elementAt(i); if (type == null) { continue; } code.aload(locals); code.iconst(i); //code.checkcast(code.pool.Class(p(Object.class))); if (i == 2222) { code.aconst_null(); } else { code.aload(i); } code.aastore(); } loadFrame(); code.aload(locals); code.putfield(p(PyFrame.class), "f_savedlocals", ci(Object[].class)); code.freeLocal(locals); }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitReturn(Return node) throws Exception { return visitReturn(node, false); }
// in src/org/python/compiler/CodeCompiler.java
public Object visitReturn(Return node, boolean inEval) throws Exception { setline(node); if (!inEval && !fast_locals) { throw new ParseException("'return' outside function", node); } int tmp = 0; if (node.getInternalValue() != null) { if (my_scope.generator) { throw new ParseException("'return' with argument " + "inside generator", node); } visit(node.getInternalValue()); tmp = code.getReturnLocal(); code.astore(tmp); } doFinallysDownTo(0); setLastI(-1); if (node.getInternalValue() != null) { code.aload(tmp); } else { getNone(); } code.areturn(); return Exit; }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitRaise(Raise node) throws Exception { setline(node); if (node.getInternalType() != null) { visit(node.getInternalType()); stackProduce(); } if (node.getInternalInst() != null) { visit(node.getInternalInst()); stackProduce(); } if (node.getInternalTback() != null) { visit(node.getInternalTback()); stackProduce(); } if (node.getInternalType() == null) { code.invokestatic(p(Py.class), "makeException", sig(PyException.class)); } else if (node.getInternalInst() == null) { stackConsume(); code.invokestatic(p(Py.class), "makeException", sig(PyException.class, PyObject.class)); } else if (node.getInternalTback() == null) { stackConsume(2); code.invokestatic(p(Py.class), "makeException", sig(PyException.class, PyObject.class, PyObject.class)); } else { stackConsume(3); code.invokestatic(p(Py.class), "makeException", sig(PyException.class, PyObject.class, PyObject.class, PyObject.class)); } code.athrow(); return Exit; }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitImport(Import node) throws Exception { setline(node); for (alias a : node.getInternalNames()) { String asname = null; if (a.getInternalAsname() != null) { String name = a.getInternalName(); asname = a.getInternalAsname(); code.ldc(name); loadFrame(); defaultImportLevel(); code.invokestatic(p(imp.class), "importOneAs", sig(PyObject.class, String.class, PyFrame.class, Integer.TYPE)); } else { String name = a.getInternalName(); asname = name; if (asname.indexOf('.') > 0) { asname = asname.substring(0, asname.indexOf('.')); } code.ldc(name); loadFrame(); defaultImportLevel(); code.invokestatic(p(imp.class), "importOne", sig(PyObject.class, String.class, PyFrame.class, Integer.TYPE)); } set(new Name(a, asname, expr_contextType.Store)); } return null; }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitImportFrom(ImportFrom node) throws Exception { Future.checkFromFuture(node); // future stmt support setline(node); code.ldc(node.getInternalModule()); java.util.List<alias> aliases = node.getInternalNames(); if (aliases == null || aliases.size() == 0) { throw new ParseException("Internel parser error", node); } else if (aliases.size() == 1 && aliases.get(0).getInternalName().equals("*")) { if (node.getInternalLevel() > 0) { throw new ParseException("'import *' not allowed with 'from .'", node); } if (my_scope.func_level > 0) { module.error("import * only allowed at module level", false, node); if (my_scope.contains_ns_free_vars) { module.error("import * is not allowed in function '" + my_scope.scope_name + "' because it contains a nested function with free variables", true, node); } } if (my_scope.func_level > 1) { module.error("import * is not allowed in function '" + my_scope.scope_name + "' because it is a nested function", true, node); } loadFrame(); defaultImportLevel(); code.invokestatic(p(imp.class), "importAll", sig(Void.TYPE, String.class, PyFrame.class, Integer.TYPE)); } else { java.util.List<String> fromNames = new ArrayList<String>();//[names.size()]; java.util.List<String> asnames = new ArrayList<String>();//[names.size()]; for (int i = 0; i < aliases.size(); i++) { fromNames.add(aliases.get(i).getInternalName()); asnames.add(aliases.get(i).getInternalAsname()); if (asnames.get(i) == null) { asnames.set(i, fromNames.get(i)); } } int strArray = makeStrings(code, fromNames); code.aload(strArray); code.freeLocal(strArray); loadFrame(); if (node.getInternalLevel() == 0) { defaultImportLevel(); } else { code.iconst(node.getInternalLevel()); } code.invokestatic(p(imp.class), "importFrom", sig(PyObject[].class, String.class, String[].class, PyFrame.class, Integer.TYPE)); int tmp = storeTop(); for (int i = 0; i < aliases.size(); i++) { code.aload(tmp); code.iconst(i); code.aaload(); set(new Name(aliases.get(i), asnames.get(i), expr_contextType.Store)); } code.freeLocal(tmp); } return null; }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitGlobal(Global node) throws Exception { return null; }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitExec(Exec node) throws Exception { setline(node); visit(node.getInternalBody()); stackProduce(); if (node.getInternalGlobals() != null) { visit(node.getInternalGlobals()); } else { code.aconst_null(); } stackProduce(); if (node.getInternalLocals() != null) { visit(node.getInternalLocals()); } else { code.aconst_null(); } stackProduce(); //do the real work here stackConsume(3); code.invokestatic(p(Py.class), "exec", sig(Void.TYPE, PyObject.class, PyObject.class, PyObject.class)); return null; }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitAssert(Assert node) throws Exception { setline(node); Label end_of_assert = new Label(); /* First do an if __debug__: */ loadFrame(); emitGetGlobal("__debug__"); code.invokevirtual(p(PyObject.class), "__nonzero__", sig(Boolean.TYPE)); code.ifeq(end_of_assert); /* Now do the body of the assert. If PyObject.__nonzero__ is true, then the assertion succeeded, the message portion should not be processed. Otherwise, the message will be processed. */ visit(node.getInternalTest()); code.invokevirtual(p(PyObject.class), "__nonzero__", sig(Boolean.TYPE)); /* If evaluation is false, then branch to end of method */ code.ifne(end_of_assert); /* Visit the message part of the assertion, or pass Py.None */ if (node.getInternalMsg() != null) { visit(node.getInternalMsg()); } else { getNone(); } /* Push exception type onto stack(AssertionError) */ loadFrame(); emitGetGlobal("AssertionError"); code.swap(); // The type is the first argument, but the message could be a yield code.invokestatic(p(Py.class), "makeException", sig(PyException.class, PyObject.class, PyObject.class)); /* Raise assertion error. Only executes this logic if assertion failed */ code.athrow(); /* And finally set the label for the end of it all */ code.label(end_of_assert); return null; }
// in src/org/python/compiler/CodeCompiler.java
public Object doTest(Label end_of_if, If node, int index) throws Exception { Label end_of_suite = new Label(); setline(node.getInternalTest()); visit(node.getInternalTest()); code.invokevirtual(p(PyObject.class), "__nonzero__", sig(Boolean.TYPE)); code.ifeq(end_of_suite); Object exit = suite(node.getInternalBody()); if (end_of_if != null && exit == null) { code.goto_(end_of_if); } code.label(end_of_suite); if (node.getInternalOrelse() != null) { return suite(node.getInternalOrelse()) != null ? exit : null; } else { return null; } }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitIf(If node) throws Exception { Label end_of_if = null; if (node.getInternalOrelse() != null) { end_of_if = new Label(); } Object exit = doTest(end_of_if, node, 0); if (end_of_if != null) { code.label(end_of_if); } return exit; }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitIfExp(IfExp node) throws Exception { setline(node.getInternalTest()); Label end = new Label(); Label end_of_else = new Label(); visit(node.getInternalTest()); code.invokevirtual(p(PyObject.class), "__nonzero__", sig(Boolean.TYPE)); code.ifeq(end_of_else); visit(node.getInternalBody()); code.goto_(end); code.label(end_of_else); visit(node.getInternalOrelse()); code.label(end); return null; }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitWhile(While node) throws Exception { int savebcf = beginLoop(); Label continue_loop = continueLabels.peek(); Label break_loop = breakLabels.peek(); Label start_loop = new Label(); code.goto_(continue_loop); code.label(start_loop); //Do suite suite(node.getInternalBody()); code.label(continue_loop); setline(node); //Do test visit(node.getInternalTest()); code.invokevirtual(p(PyObject.class), "__nonzero__", sig(Boolean.TYPE)); code.ifne(start_loop); finishLoop(savebcf); if (node.getInternalOrelse() != null) { //Do else suite(node.getInternalOrelse()); } code.label(break_loop); // Probably need to detect "guaranteed exits" return null; }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitFor(For node) throws Exception { int savebcf = beginLoop(); Label continue_loop = continueLabels.peek(); Label break_loop = breakLabels.peek(); Label start_loop = new Label(); Label next_loop = new Label(); setline(node); //parse the list visit(node.getInternalIter()); int iter_tmp = code.getLocal(p(PyObject.class)); int expr_tmp = code.getLocal(p(PyObject.class)); //set up the loop iterator code.invokevirtual(p(PyObject.class), "__iter__", sig(PyObject.class)); code.astore(iter_tmp); //do check at end of loop. Saves one opcode ;-) code.goto_(next_loop); code.label(start_loop); //set iter variable to current entry in list set(node.getInternalTarget(), expr_tmp); //evaluate for body suite(node.getInternalBody()); code.label(continue_loop); code.label(next_loop); setline(node); //get the next element from the list code.aload(iter_tmp); code.invokevirtual(p(PyObject.class), "__iternext__", sig(PyObject.class)); code.astore(expr_tmp); code.aload(expr_tmp); //if no more elements then fall through code.ifnonnull(start_loop); finishLoop(savebcf); if (node.getInternalOrelse() != null) { //Do else clause if provided suite(node.getInternalOrelse()); } code.label(break_loop); code.freeLocal(iter_tmp); code.freeLocal(expr_tmp); // Probably need to detect "guaranteed exits" return null; }
// in src/org/python/compiler/CodeCompiler.java
public void exceptionTest(int exc, Label end_of_exceptions, TryExcept node, int index) throws Exception { for (int i = 0; i < node.getInternalHandlers().size(); i++) { ExceptHandler handler = (ExceptHandler) node.getInternalHandlers().get(i); //setline(name); Label end_of_self = new Label(); if (handler.getInternalType() != null) { code.aload(exc); //get specific exception visit(handler.getInternalType()); code.invokevirtual(p(PyException.class), "match", sig(Boolean.TYPE, PyObject.class)); code.ifeq(end_of_self); } else { if (i != node.getInternalHandlers().size() - 1) { throw new ParseException( "default 'except:' must be last", handler); } } if (handler.getInternalName() != null) { code.aload(exc); code.getfield(p(PyException.class), "value", ci(PyObject.class)); set(handler.getInternalName()); } //do exception body suite(handler.getInternalBody()); code.goto_(end_of_exceptions); code.label(end_of_self); } code.aload(exc); code.athrow(); }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitTryFinally(TryFinally node) throws Exception { Label start = new Label(); Label end = new Label(); Label handlerStart = new Label(); Label finallyEnd = new Label(); Object ret; ExceptionHandler inFinally = new ExceptionHandler(node); // Do protected suite exceptionHandlers.push(inFinally); int excLocal = code.getLocal(p(Throwable.class)); code.aconst_null(); code.astore(excLocal); code.label(start); inFinally.exceptionStarts.addElement(start); ret = suite(node.getInternalBody()); code.label(end); inFinally.exceptionEnds.addElement(end); inFinally.bodyDone = true; exceptionHandlers.pop(); if (ret == NoExit) { inlineFinally(inFinally); code.goto_(finallyEnd); } // Handle any exceptions that get thrown in suite code.label(handlerStart); code.astore(excLocal); code.aload(excLocal); loadFrame(); code.invokestatic(p(Py.class), "addTraceback", sig(Void.TYPE, Throwable.class, PyFrame.class)); inlineFinally(inFinally); code.aload(excLocal); code.checkcast(p(Throwable.class)); code.athrow(); code.label(finallyEnd); code.freeLocal(excLocal); inFinally.addExceptionHandlers(handlerStart); // According to any JVM verifiers, this code block might not return return null; }
// in src/org/python/compiler/CodeCompiler.java
private void inlineFinally(ExceptionHandler handler) throws Exception { if (!handler.bodyDone) { // end the previous exception block so inlined finally code doesn't // get covered by our exception handler. Label end = new Label(); code.label(end); handler.exceptionEnds.addElement(end); // also exiting the try: portion of this particular finally } if (handler.isFinallyHandler()) { handler.finalBody(this); } }
// in src/org/python/compiler/CodeCompiler.java
private void reenterProtectedBody(ExceptionHandler handler) throws Exception { // restart exception coverage Label restart = new Label(); code.label(restart); handler.exceptionStarts.addElement(restart); }
// in src/org/python/compiler/CodeCompiler.java
private void doFinallysDownTo(int level) throws Exception { Stack<ExceptionHandler> poppedHandlers = new Stack<ExceptionHandler>(); while (exceptionHandlers.size() > level) { ExceptionHandler handler = exceptionHandlers.pop(); inlineFinally(handler); poppedHandlers.push(handler); } while (poppedHandlers.size() > 0) { ExceptionHandler handler = poppedHandlers.pop(); reenterProtectedBody(handler); exceptionHandlers.push(handler); } }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitTryExcept(TryExcept node) throws Exception { Label start = new Label(); Label end = new Label(); Label handler_start = new Label(); Label handler_end = new Label(); ExceptionHandler handler = new ExceptionHandler(); code.label(start); handler.exceptionStarts.addElement(start); exceptionHandlers.push(handler); //Do suite Object exit = suite(node.getInternalBody()); exceptionHandlers.pop(); code.label(end); handler.exceptionEnds.addElement(end); if (exit == null) { code.goto_(handler_end); } code.label(handler_start); loadFrame(); code.invokestatic(p(Py.class), "setException", sig(PyException.class, Throwable.class, PyFrame.class)); int exc = code.getFinallyLocal(p(Throwable.class)); code.astore(exc); if (node.getInternalOrelse() == null) { //No else clause to worry about exceptionTest(exc, handler_end, node, 1); code.label(handler_end); } else { //Have else clause Label else_end = new Label(); exceptionTest(exc, else_end, node, 1); code.label(handler_end); //do else clause suite(node.getInternalOrelse()); code.label(else_end); } code.freeFinallyLocal(exc); handler.addExceptionHandlers(handler_start); return null; }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitSuite(Suite node) throws Exception { return suite(node.getInternalBody()); }
// in src/org/python/compiler/CodeCompiler.java
public Object suite(java.util.List<stmt> stmts) throws Exception { for (stmt s : stmts) { Object exit = visit(s); if (exit != null) { return Exit; } } return null; }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitBoolOp(BoolOp node) throws Exception { Label end = new Label(); visit(node.getInternalValues().get(0)); for (int i = 1; i < node.getInternalValues().size(); i++) { code.dup(); code.invokevirtual(p(PyObject.class), "__nonzero__", sig(Boolean.TYPE)); switch (node.getInternalOp()) { case Or: code.ifne(end); break; case And: code.ifeq(end); break; } code.pop(); visit(node.getInternalValues().get(i)); } code.label(end); return null; }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitCompare(Compare node) throws Exception { int last = code.getLocal(p(PyObject.class)); int result = code.getLocal(p(PyObject.class)); Label end = new Label(); visit(node.getInternalLeft()); code.astore(last); int n = node.getInternalOps().size(); for (int i = 0; i < n - 1; i++) { visit(node.getInternalComparators().get(i)); code.aload(last); code.swap(); code.dup(); code.astore(last); visitCmpop(node.getInternalOps().get(i)); code.dup(); code.astore(result); code.invokevirtual(p(PyObject.class), "__nonzero__", sig(Boolean.TYPE)); code.ifeq(end); } visit(node.getInternalComparators().get(n - 1)); code.aload(last); code.swap(); visitCmpop(node.getInternalOps().get(n - 1)); if (n > 1) { code.astore(result); code.label(end); code.aload(result); } code.aconst_null(); code.astore(last); code.freeLocal(last); code.freeLocal(result); return null; }
// in src/org/python/compiler/CodeCompiler.java
public void visitCmpop(cmpopType op) throws Exception { String name = null; switch (op) { case Eq: name = "_eq"; break; case NotEq: name = "_ne"; break; case Lt: name = "_lt"; break; case LtE: name = "_le"; break; case Gt: name = "_gt"; break; case GtE: name = "_ge"; break; case Is: name = "_is"; break; case IsNot: name = "_isnot"; break; case In: name = "_in"; break; case NotIn: name = "_notin"; break; } code.invokevirtual(p(PyObject.class), name, sig(PyObject.class, PyObject.class)); }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitBinOp(BinOp node) throws Exception { visit(node.getInternalLeft()); stackProduce(); visit(node.getInternalRight()); stackConsume(); String name = null; switch (node.getInternalOp()) { case Add: name = "_add"; break; case Sub: name = "_sub"; break; case Mult: name = "_mul"; break; case Div: name = "_div"; break; case Mod: name = "_mod"; break; case Pow: name = "_pow"; break; case LShift: name = "_lshift"; break; case RShift: name = "_rshift"; break; case BitOr: name = "_or"; break; case BitXor: name = "_xor"; break; case BitAnd: name = "_and"; break; case FloorDiv: name = "_floordiv"; break; } if (node.getInternalOp() == operatorType.Div && module.getFutures().areDivisionOn()) { name = "_truediv"; } code.invokevirtual(p(PyObject.class), name, sig(PyObject.class, PyObject.class)); return null; }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitUnaryOp(UnaryOp node) throws Exception { visit(node.getInternalOperand()); String name = null; switch (node.getInternalOp()) { case Invert: name = "__invert__"; break; case Not: name = "__not__"; break; case UAdd: name = "__pos__"; break; case USub: name = "__neg__"; break; } code.invokevirtual(p(PyObject.class), name, sig(PyObject.class)); return null; }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitAugAssign(AugAssign node) throws Exception { setline(node); augmode = expr_contextType.Load; visit(node.getInternalTarget()); int target = storeTop(); visit(node.getInternalValue()); code.aload(target); code.swap(); String name = null; switch (node.getInternalOp()) { case Add: name = "_iadd"; break; case Sub: name = "_isub"; break; case Mult: name = "_imul"; break; case Div: name = "_idiv"; break; case Mod: name = "_imod"; break; case Pow: name = "_ipow"; break; case LShift: name = "_ilshift"; break; case RShift: name = "_irshift"; break; case BitOr: name = "_ior"; break; case BitXor: name = "_ixor"; break; case BitAnd: name = "_iand"; break; case FloorDiv: name = "_ifloordiv"; break; } if (node.getInternalOp() == operatorType.Div && module.getFutures().areDivisionOn()) { name = "_itruediv"; } code.invokevirtual(p(PyObject.class), name, sig(PyObject.class, PyObject.class)); code.freeLocal(target); temporary = storeTop(); augmode = expr_contextType.Store; visit(node.getInternalTarget()); code.freeLocal(temporary); return null; }
// in src/org/python/compiler/CodeCompiler.java
public Object invokeNoKeywords(Attribute node, java.util.List<expr> values) throws Exception { String name = getName(node.getInternalAttr()); visit(node.getInternalValue()); stackProduce(); code.ldc(name); code.invokevirtual(p(PyObject.class), "__getattr__", sig(PyObject.class, String.class)); loadThreadState(); stackProduce(p(ThreadState.class)); switch (values.size()) { case 0: stackConsume(2); // target + ts code.invokevirtual(p(PyObject.class), "__call__", sig(PyObject.class, ThreadState.class)); break; case 1: visit(values.get(0)); stackConsume(2); // target + ts code.invokevirtual(p(PyObject.class), "__call__", sig(PyObject.class, ThreadState.class, PyObject.class)); break; case 2: visit(values.get(0)); stackProduce(); visit(values.get(1)); stackConsume(3); // target + ts + arguments code.invokevirtual(p(PyObject.class), "__call__", sig(PyObject.class, ThreadState.class, PyObject.class, PyObject.class)); break; case 3: visit(values.get(0)); stackProduce(); visit(values.get(1)); stackProduce(); visit(values.get(2)); stackConsume(4); // target + ts + arguments code.invokevirtual(p(PyObject.class), "__call__", sig(PyObject.class, ThreadState.class, PyObject.class, PyObject.class, PyObject.class)); break; case 4: visit(values.get(0)); stackProduce(); visit(values.get(1)); stackProduce(); visit(values.get(2)); stackProduce(); visit(values.get(3)); stackConsume(5); // target + ts + arguments code.invokevirtual(p(PyObject.class), "__call__", sig(PyObject.class, ThreadState.class, PyObject.class, PyObject.class, PyObject.class, PyObject.class)); break; default: int argArray = makeArray(values); code.aload(argArray); code.freeLocal(argArray); stackConsume(2); // target + ts code.invokevirtual(p(PyObject.class), "__call__", sig(PyObject.class, ThreadState.class, PyObject[].class)); break; } return null; }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitCall(Call node) throws Exception { java.util.List<String> keys = new ArrayList<String>(); java.util.List<expr> values = new ArrayList<expr>(); for (int i = 0; i < node.getInternalArgs().size(); i++) { values.add(node.getInternalArgs().get(i)); } for (int i = 0; i < node.getInternalKeywords().size(); i++) { keys.add(node.getInternalKeywords().get(i).getInternalArg()); values.add(node.getInternalKeywords().get(i).getInternalValue()); } if ((node.getInternalKeywords() == null || node.getInternalKeywords().size() == 0) && node.getInternalStarargs() == null && node.getInternalKwargs() == null && node.getInternalFunc() instanceof Attribute) { return invokeNoKeywords((Attribute) node.getInternalFunc(), values); } visit(node.getInternalFunc()); stackProduce(); if (node.getInternalStarargs() != null || node.getInternalKwargs() != null) { int argArray = makeArray(values); int strArray = makeStrings(code, keys); if (node.getInternalStarargs() == null) { code.aconst_null(); } else { visit(node.getInternalStarargs()); } stackProduce(); if (node.getInternalKwargs() == null) { code.aconst_null(); } else { visit(node.getInternalKwargs()); } stackProduce(); code.aload(argArray); code.aload(strArray); code.freeLocal(strArray); code.dup2_x2(); code.pop2(); stackConsume(3); // target + starargs + kwargs code.invokevirtual(p(PyObject.class), "_callextra", sig(PyObject.class, PyObject[].class, String[].class, PyObject.class, PyObject.class)); freeArrayRef(argArray); } else if (keys.size() > 0) { loadThreadState(); stackProduce(p(ThreadState.class)); int argArray = makeArray(values); int strArray = makeStrings(code, keys); code.aload(argArray); code.aload(strArray); code.freeLocal(strArray); stackConsume(2); // target + ts code.invokevirtual(p(PyObject.class), "__call__", sig(PyObject.class, ThreadState.class, PyObject[].class, String[].class)); freeArrayRef(argArray); } else { loadThreadState(); stackProduce(p(ThreadState.class)); switch (values.size()) { case 0: stackConsume(2); // target + ts code.invokevirtual(p(PyObject.class), "__call__", sig(PyObject.class, ThreadState.class)); break; case 1: visit(values.get(0)); stackConsume(2); // target + ts code.invokevirtual(p(PyObject.class), "__call__", sig(PyObject.class, ThreadState.class, PyObject.class)); break; case 2: visit(values.get(0)); stackProduce(); visit(values.get(1)); stackConsume(3); // target + ts + arguments code.invokevirtual(p(PyObject.class), "__call__", sig(PyObject.class, ThreadState.class, PyObject.class, PyObject.class)); break; case 3: visit(values.get(0)); stackProduce(); visit(values.get(1)); stackProduce(); visit(values.get(2)); stackConsume(4); // target + ts + arguments code.invokevirtual(p(PyObject.class), "__call__", sig(PyObject.class, ThreadState.class, PyObject.class, PyObject.class, PyObject.class)); break; case 4: visit(values.get(0)); stackProduce(); visit(values.get(1)); stackProduce(); visit(values.get(2)); stackProduce(); visit(values.get(3)); stackConsume(5); // target + ts + arguments code.invokevirtual(p(PyObject.class), "__call__", sig(PyObject.class, ThreadState.class, PyObject.class, PyObject.class, PyObject.class, PyObject.class)); break; default: int argArray = makeArray(values); code.aload(argArray); code.freeLocal(argArray); stackConsume(2); // target + ts code.invokevirtual(p(PyObject.class), "__call__", sig(PyObject.class, ThreadState.class, PyObject[].class)); break; } } return null; }
// in src/org/python/compiler/CodeCompiler.java
public Object Slice(Subscript node, Slice slice) throws Exception { expr_contextType ctx = node.getInternalCtx(); if (ctx == expr_contextType.AugStore && augmode == expr_contextType.Store) { restoreAugTmps(node, 4); ctx = expr_contextType.Store; } else { visit(node.getInternalValue()); stackProduce(); if (slice.getInternalLower() != null) { visit(slice.getInternalLower()); } else { code.aconst_null(); } stackProduce(); if (slice.getInternalUpper() != null) { visit(slice.getInternalUpper()); } else { code.aconst_null(); } stackProduce(); if (slice.getInternalStep() != null) { visit(slice.getInternalStep()); } else { code.aconst_null(); } stackProduce(); if (node.getInternalCtx() == expr_contextType.AugStore && augmode == expr_contextType.Load) { saveAugTmps(node, 4); ctx = expr_contextType.Load; } stackConsume(4); } switch (ctx) { case Del: code.invokevirtual(p(PyObject.class), "__delslice__", sig(Void.TYPE, PyObject.class, PyObject.class, PyObject.class)); return null; case Load: code.invokevirtual(p(PyObject.class), "__getslice__", sig(PyObject.class, PyObject.class, PyObject.class, PyObject.class)); return null; case Param: case Store: code.aload(temporary); code.invokevirtual(p(PyObject.class), "__setslice__", sig(Void.TYPE, PyObject.class, PyObject.class, PyObject.class, PyObject.class)); return null; } return null; }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitSubscript(Subscript node) throws Exception { if (node.getInternalSlice() instanceof Slice) { return Slice(node, (Slice) node.getInternalSlice()); } int value = temporary; expr_contextType ctx = node.getInternalCtx(); if (node.getInternalCtx() == expr_contextType.AugStore && augmode == expr_contextType.Store) { restoreAugTmps(node, 2); ctx = expr_contextType.Store; } else { visit(node.getInternalValue()); stackProduce(); visit(node.getInternalSlice()); stackConsume(); if (node.getInternalCtx() == expr_contextType.AugStore && augmode == expr_contextType.Load) { saveAugTmps(node, 2); ctx = expr_contextType.Load; } } switch (ctx) { case Del: code.invokevirtual(p(PyObject.class), "__delitem__", sig(Void.TYPE, PyObject.class)); return null; case Load: code.invokevirtual(p(PyObject.class), "__getitem__", sig(PyObject.class, PyObject.class)); return null; case Param: case Store: code.aload(value); code.invokevirtual(p(PyObject.class), "__setitem__", sig(Void.TYPE, PyObject.class, PyObject.class)); return null; } return null; }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitIndex(Index node) throws Exception { traverse(node); return null; }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitExtSlice(ExtSlice node) throws Exception { int dims = makeArray(node.getInternalDims()); code.new_(p(PyTuple.class)); code.dup(); code.aload(dims); code.invokespecial(p(PyTuple.class), "<init>", sig(Void.TYPE, PyObject[].class)); freeArray(dims); return null; }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitAttribute(Attribute node) throws Exception { expr_contextType ctx = node.getInternalCtx(); if (node.getInternalCtx() == expr_contextType.AugStore && augmode == expr_contextType.Store) { restoreAugTmps(node, 2); ctx = expr_contextType.Store; } else { visit(node.getInternalValue()); code.ldc(getName(node.getInternalAttr())); if (node.getInternalCtx() == expr_contextType.AugStore && augmode == expr_contextType.Load) { saveAugTmps(node, 2); ctx = expr_contextType.Load; } } switch (ctx) { case Del: code.invokevirtual(p(PyObject.class), "__delattr__", sig(Void.TYPE, String.class)); return null; case Load: code.invokevirtual(p(PyObject.class), "__getattr__", sig(PyObject.class, String.class)); return null; case Param: case Store: code.aload(temporary); code.invokevirtual(p(PyObject.class), "__setattr__", sig(Void.TYPE, String.class, PyObject.class)); return null; } return null; }
// in src/org/python/compiler/CodeCompiler.java
public Object seqSet(java.util.List<expr> nodes) throws Exception { code.aload(temporary); code.iconst(nodes.size()); code.invokestatic(p(Py.class), "unpackSequence", sig(PyObject[].class, PyObject.class, Integer.TYPE)); int tmp = code.getLocal("[org/python/core/PyObject"); code.astore(tmp); for (int i = 0; i < nodes.size(); i++) { code.aload(tmp); code.iconst(i); code.aaload(); set(nodes.get(i)); } code.freeLocal(tmp); return null; }
// in src/org/python/compiler/CodeCompiler.java
public Object seqDel(java.util.List<expr> nodes) throws Exception { for (expr e : nodes) { visit(e); } return null; }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitTuple(Tuple node) throws Exception { if (node.getInternalCtx() == expr_contextType.Store) { return seqSet(node.getInternalElts()); } if (node.getInternalCtx() == expr_contextType.Del) { return seqDel(node.getInternalElts()); } int content = makeArray(node.getInternalElts()); code.new_(p(PyTuple.class)); code.dup(); code.aload(content); code.invokespecial(p(PyTuple.class), "<init>", sig(Void.TYPE, PyObject[].class)); freeArray(content); return null; }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitList(List node) throws Exception { if (node.getInternalCtx() == expr_contextType.Store) { return seqSet(node.getInternalElts()); } if (node.getInternalCtx() == expr_contextType.Del) { return seqDel(node.getInternalElts()); } int content = makeArray(node.getInternalElts()); code.new_(p(PyList.class)); code.dup(); code.aload(content); code.invokespecial(p(PyList.class), "<init>", sig(Void.TYPE, PyObject[].class)); freeArray(content); return null; }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitListComp(ListComp node) throws Exception { code.new_(p(PyList.class)); code.dup(); code.invokespecial(p(PyList.class), "<init>", sig(Void.TYPE)); code.dup(); code.ldc("append"); code.invokevirtual(p(PyObject.class), "__getattr__", sig(PyObject.class, String.class)); String tmp_append = "_[" + node.getLine() + "_" + node.getCharPositionInLine() + "]"; set(new Name(node, tmp_append, expr_contextType.Store)); java.util.List<expr> args = new ArrayList<expr>(); args.add(node.getInternalElt()); stmt n = new Expr(node, new Call(node, new Name(node, tmp_append, expr_contextType.Load), args, new ArrayList<keyword>(), null, null)); for (int i = node.getInternalGenerators().size() - 1; i >= 0; i--) { comprehension lc = node.getInternalGenerators().get(i); for (int j = lc.getInternalIfs().size() - 1; j >= 0; j--) { java.util.List<stmt> body = new ArrayList<stmt>(); body.add(n); n = new If(lc.getInternalIfs().get(j), lc.getInternalIfs().get(j), body, new ArrayList<stmt>()); } java.util.List<stmt> body = new ArrayList<stmt>(); body.add(n); n = new For(lc, lc.getInternalTarget(), lc.getInternalIter(), body, new ArrayList<stmt>()); } visit(n); java.util.List<expr> targets = new ArrayList<expr>(); targets.add(new Name(n, tmp_append, expr_contextType.Del)); visit(new Delete(n, targets)); return null; }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitDict(Dict node) throws Exception { java.util.List<PythonTree> elts = new ArrayList<PythonTree>(); for (int i = 0; i < node.getInternalKeys().size(); i++) { elts.add(node.getInternalKeys().get(i)); elts.add(node.getInternalValues().get(i)); } int content = makeArray(elts); code.new_(p(PyDictionary.class)); code.dup(); code.aload(content); code.invokespecial(p(PyDictionary.class), "<init>", sig(Void.TYPE, PyObject[].class)); freeArray(content); return null; }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitRepr(Repr node) throws Exception { visit(node.getInternalValue()); code.invokevirtual(p(PyObject.class), "__repr__", sig(PyString.class)); return null; }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitLambda(Lambda node) throws Exception { String name = "<lambda>"; //Add a return node onto the outside of suite; java.util.List<stmt> bod = new ArrayList<stmt>(); bod.add(new Return(node, node.getInternalBody())); mod retSuite = new Suite(node, bod); setline(node); ScopeInfo scope = module.getScopeInfo(node); int defaultsArray = makeArray(scope.ac.getDefaults()); code.new_(p(PyFunction.class)); code.dup(); code.aload(defaultsArray); code.freeLocal(defaultsArray); loadFrame(); code.getfield(p(PyFrame.class), "f_globals", ci(PyObject.class)); code.swap(); scope.setup_closure(); scope.dump(); module.codeConstant(retSuite, name, true, className, false, false, node.getLine(), scope, cflags).get(code); if (!makeClosure(scope)) { code.invokespecial(p(PyFunction.class), "<init>", sig(Void.TYPE, PyObject.class, PyObject[].class, PyCode.class)); } else { code.invokespecial(p(PyFunction.class), "<init>", sig(Void.TYPE, PyObject.class, PyObject[].class, PyCode.class, PyObject[].class)); } return null; }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitEllipsis(Ellipsis node) throws Exception { code.getstatic(p(Py.class), "Ellipsis", ci(PyObject.class)); return null; }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitSlice(Slice node) throws Exception { if (node.getInternalLower() == null) { getNone(); } else { visit(node.getInternalLower()); } stackProduce(); if (node.getInternalUpper() == null) { getNone(); } else { visit(node.getInternalUpper()); } stackProduce(); if (node.getInternalStep() == null) { getNone(); } else { visit(node.getInternalStep()); } int step = storeTop(); stackConsume(2); code.new_(p(PySlice.class)); code.dup(); code.dup2_x2(); code.pop2(); code.aload(step); code.freeLocal(step); code.invokespecial(p(PySlice.class), "<init>", sig(Void.TYPE, PyObject.class, PyObject.class, PyObject.class)); return null; }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitClassDef(ClassDef node) throws Exception { setline(node); int baseArray = makeArray(node.getInternalBases()); //Get class name String name = getName(node.getInternalName()); code.ldc(name); code.aload(baseArray); ScopeInfo scope = module.getScopeInfo(node); scope.setup_closure(); scope.dump(); //Make code object out of suite module.codeConstant(new Suite(node, node.getInternalBody()), name, false, name, getDocStr(node.getInternalBody()), true, false, node.getLine(), scope, cflags).get(code); //Make class out of name, bases, and code if (!makeClosure(scope)) { code.invokestatic(p(Py.class), "makeClass", sig(PyObject.class, String.class, PyObject[].class, PyCode.class)); } else { code.invokestatic(p(Py.class), "makeClass", sig(PyObject.class, String.class, PyObject[].class, PyCode.class, PyObject[].class)); } applyDecorators(node.getInternalDecorator_list()); //Assign this new class to the given name set(new Name(node, node.getInternalName(), expr_contextType.Store)); freeArray(baseArray); return null; }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitNum(Num node) throws Exception { if (node.getInternalN() instanceof PyInteger) { module.integerConstant(((PyInteger) node.getInternalN()).getValue()).get(code); } else if (node.getInternalN() instanceof PyLong) { module.longConstant(((PyObject) node.getInternalN()).__str__().toString()).get(code); } else if (node.getInternalN() instanceof PyFloat) { module.floatConstant(((PyFloat) node.getInternalN()).getValue()).get(code); } else if (node.getInternalN() instanceof PyComplex) { module.complexConstant(((PyComplex) node.getInternalN()).imag).get(code); } return null; }
// in src/org/python/compiler/CodeCompiler.java
void emitGetGlobal(String name) throws Exception { code.ldc(name); code.invokevirtual(p(PyFrame.class), "getglobal", sig(PyObject.class, String.class)); }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitName(Name node) throws Exception { String name; if (fast_locals) { name = node.getInternalId(); } else { name = getName(node.getInternalId()); } SymInfo syminf = tbl.get(name); expr_contextType ctx = node.getInternalCtx(); if (ctx == expr_contextType.AugStore) { ctx = augmode; } switch (ctx) { case Load: loadFrame(); if (syminf != null) { int flags = syminf.flags; if ((flags & ScopeInfo.GLOBAL) != 0 || optimizeGlobals && (flags & (ScopeInfo.BOUND | ScopeInfo.CELL | ScopeInfo.FREE)) == 0) { emitGetGlobal(name); return null; } if (fast_locals) { if ((flags & ScopeInfo.CELL) != 0) { code.iconst(syminf.env_index); code.invokevirtual(p(PyFrame.class), "getderef", sig(PyObject.class, Integer.TYPE)); return null; } if ((flags & ScopeInfo.BOUND) != 0) { code.iconst(syminf.locals_index); code.invokevirtual(p(PyFrame.class), "getlocal", sig(PyObject.class, Integer.TYPE)); return null; } } if ((flags & ScopeInfo.FREE) != 0 && (flags & ScopeInfo.BOUND) == 0) { code.iconst(syminf.env_index); code.invokevirtual(p(PyFrame.class), "getderef", sig(PyObject.class, Integer.TYPE)); return null; } } code.ldc(name); code.invokevirtual(p(PyFrame.class), "getname", sig(PyObject.class, String.class)); return null; case Param: case Store: loadFrame(); if (syminf != null && (syminf.flags & ScopeInfo.GLOBAL) != 0) { code.ldc(name); code.aload(temporary); code.invokevirtual(p(PyFrame.class), "setglobal", sig(Void.TYPE, String.class, PyObject.class)); } else { if (!fast_locals) { code.ldc(name); code.aload(temporary); code.invokevirtual(p(PyFrame.class), "setlocal", sig(Void.TYPE, String.class, PyObject.class)); } else { if (syminf == null) { throw new ParseException("internal compiler error", node); } if ((syminf.flags & ScopeInfo.CELL) != 0) { code.iconst(syminf.env_index); code.aload(temporary); code.invokevirtual(p(PyFrame.class), "setderef", sig(Void.TYPE, Integer.TYPE, PyObject.class)); } else { code.iconst(syminf.locals_index); code.aload(temporary); code.invokevirtual(p(PyFrame.class), "setlocal", sig(Void.TYPE, Integer.TYPE, PyObject.class)); } } } return null; case Del: { loadFrame(); if (syminf != null && (syminf.flags & ScopeInfo.GLOBAL) != 0) { code.ldc(name); code.invokevirtual(p(PyFrame.class), "delglobal", sig(Void.TYPE, String.class)); } else { if (!fast_locals) { code.ldc(name); code.invokevirtual(p(PyFrame.class), "dellocal", sig(Void.TYPE, String.class)); } else { if (syminf == null) { throw new ParseException("internal compiler error", node); } if ((syminf.flags & ScopeInfo.CELL) != 0) { module.error("can not delete variable '" + name + "' referenced in nested scope", true, node); } code.iconst(syminf.locals_index); code.invokevirtual(p(PyFrame.class), "dellocal", sig(Void.TYPE, Integer.TYPE)); } } return null; } } return null; }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitStr(Str node) throws Exception { PyString s = (PyString) node.getInternalS(); if (s instanceof PyUnicode) { module.unicodeConstant(s.asString()).get(code); } else { module.stringConstant(s.asString()).get(code); } return null; }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitGeneratorExp(GeneratorExp node) throws Exception { String bound_exp = "_(x)"; setline(node); code.new_(p(PyFunction.class)); code.dup(); loadFrame(); code.getfield(p(PyFrame.class), "f_globals", ci(PyObject.class)); ScopeInfo scope = module.getScopeInfo(node); int emptyArray = makeArray(new ArrayList<expr>()); code.aload(emptyArray); scope.setup_closure(); scope.dump(); stmt n = new Expr(node, new Yield(node, node.getInternalElt())); expr iter = null; for (int i = node.getInternalGenerators().size() - 1; i >= 0; i--) { comprehension comp = node.getInternalGenerators().get(i); for (int j = comp.getInternalIfs().size() - 1; j >= 0; j--) { java.util.List<stmt> bod = new ArrayList<stmt>(); bod.add(n); n = new If(comp.getInternalIfs().get(j), comp.getInternalIfs().get(j), bod, new ArrayList<stmt>()); } java.util.List<stmt> bod = new ArrayList<stmt>(); bod.add(n); if (i != 0) { n = new For(comp, comp.getInternalTarget(), comp.getInternalIter(), bod, new ArrayList<stmt>()); } else { n = new For(comp, comp.getInternalTarget(), new Name(node, bound_exp, expr_contextType.Load), bod, new ArrayList<stmt>()); iter = comp.getInternalIter(); } } java.util.List<stmt> bod = new ArrayList<stmt>(); bod.add(n); module.codeConstant(new Suite(node, bod), "<genexpr>", true, className, false, false, node.getLine(), scope, cflags).get(code); code.aconst_null(); if (!makeClosure(scope)) { code.invokespecial(p(PyFunction.class), "<init>", sig(Void.TYPE, PyObject.class, PyObject[].class, PyCode.class, PyObject.class)); } else { code.invokespecial(p(PyFunction.class), "<init>", sig(Void.TYPE, PyObject.class, PyObject[].class, PyCode.class, PyObject.class, PyObject[].class)); } int genExp = storeTop(); visit(iter); code.aload(genExp); code.freeLocal(genExp); code.swap(); code.invokevirtual(p(PyObject.class), "__iter__", sig(PyObject.class)); loadThreadState(); code.swap(); code.invokevirtual(p(PyObject.class), "__call__", sig(PyObject.class, ThreadState.class, PyObject.class)); freeArray(emptyArray); return null; }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitWith(With node) throws Exception { if (!module.getFutures().withStatementSupported()) { throw new ParseException("'with' will become a reserved keyword in Python 2.6", node); } final Label label_body_start = new Label(); final Label label_body_end = new Label(); final Label label_catch = new Label(); final Label label_end = new Label(); final Method contextGuard_getManager = Method.getMethod( "org.python.core.ContextManager getManager (org.python.core.PyObject)"); final Method __enter__ = Method.getMethod( "org.python.core.PyObject __enter__ (org.python.core.ThreadState)"); final Method __exit__ = Method.getMethod( "boolean __exit__ (org.python.core.ThreadState,org.python.core.PyException)"); // mgr = (EXPR) visit(node.getInternalContext_expr()); // wrap the manager with the ContextGuard (or get it directly if it // supports the ContextManager interface) code.invokestatic(Type.getType(ContextGuard.class).getInternalName(), contextGuard_getManager.getName(), contextGuard_getManager.getDescriptor()); code.dup(); final int mgr_tmp = code.getLocal(Type.getType(ContextManager.class).getInternalName()); code.astore(mgr_tmp); // value = mgr.__enter__() loadThreadState(); code.invokeinterface(Type.getType(ContextManager.class).getInternalName(), __enter__.getName(), __enter__.getDescriptor()); int value_tmp = code.getLocal(p(PyObject.class)); code.astore(value_tmp); // exc = True # not necessary, since we don't exec finally if exception // FINALLY (preparation) // ordinarily with a finally, we need to duplicate the code. that's not the case // here // # The normal and non-local-goto cases are handled here // if exc: # implicit // exit(None, None, None) ExceptionHandler normalExit = new ExceptionHandler() { @Override public boolean isFinallyHandler() { return true; } @Override public void finalBody(CodeCompiler compiler) throws Exception { compiler.code.aload(mgr_tmp); loadThreadState(); compiler.code.aconst_null(); compiler.code.invokeinterface(Type.getType(ContextManager.class).getInternalName(), __exit__.getName(), __exit__.getDescriptor()); compiler.code.pop(); } }; exceptionHandlers.push(normalExit); // try-catch block here ExceptionHandler handler = new ExceptionHandler(); exceptionHandlers.push(handler); handler.exceptionStarts.addElement(label_body_start); // VAR = value # Only if "as VAR" is present code.label(label_body_start); if (node.getInternalOptional_vars() != null) { set(node.getInternalOptional_vars(), value_tmp); } code.freeLocal(value_tmp); // BLOCK + FINALLY if non-local-goto Object blockResult = suite(node.getInternalBody()); normalExit.bodyDone = true; exceptionHandlers.pop(); exceptionHandlers.pop(); code.label(label_body_end); handler.exceptionEnds.addElement(label_body_end); // FINALLY if *not* non-local-goto if (blockResult == NoExit) { // BLOCK would have generated FINALLY for us if it exited (due to a break, // continue or return) inlineFinally(normalExit); code.goto_(label_end); } // CATCH code.label(label_catch); loadFrame(); code.invokestatic(p(Py.class), "setException", sig(PyException.class, Throwable.class, PyFrame.class)); code.aload(mgr_tmp); code.swap(); loadThreadState(); code.swap(); code.invokeinterface(Type.getType(ContextManager.class).getInternalName(), __exit__.getName(), __exit__.getDescriptor()); // # The exceptional case is handled here // exc = False # implicit // if not exit(*sys.exc_info()): code.ifne(label_end); // raise // # The exception is swallowed if exit() returns true code.invokestatic(p(Py.class), "makeException", sig(PyException.class)); code.checkcast(p(Throwable.class)); code.athrow(); code.label(label_end); code.freeLocal(mgr_tmp); handler.addExceptionHandlers(label_catch); return null; }
// in src/org/python/compiler/CodeCompiler.java
Override public void finalBody(CodeCompiler compiler) throws Exception { compiler.code.aload(mgr_tmp); loadThreadState(); compiler.code.aconst_null(); compiler.code.invokeinterface(Type.getType(ContextManager.class).getInternalName(), __exit__.getName(), __exit__.getDescriptor()); compiler.code.pop(); }
// in src/org/python/compiler/CodeCompiler.java
Override protected Object unhandled_node(PythonTree node) throws Exception { throw new Exception("Unhandled node " + node); }
// in src/org/python/compiler/CodeCompiler.java
public void addExceptionHandlers(Label handlerStart) throws Exception { for (int i = 0; i < exceptionStarts.size(); ++i) { Label start = exceptionStarts.elementAt(i); Label end = exceptionEnds.elementAt(i); //FIXME: not at all sure that getOffset() test is correct or necessary. if (start.getOffset() != end.getOffset()) { code.trycatch( exceptionStarts.elementAt(i), exceptionEnds.elementAt(i), handlerStart, p(Throwable.class)); } } }
// in src/org/python/compiler/CodeCompiler.java
public void finalBody(CodeCompiler compiler) throws Exception { if (node instanceof TryFinally) { suite(((TryFinally) node).getInternalFinalbody()); } }
// in src/org/python/compiler/JavaMaker.java
Override public void addConstructor(String name, Class<?>[] parameters, Class<?> ret, String sig, int access) throws Exception { /* Need a fancy constructor for the Java side of things */ Code code = classfile.addMethod("<init>", sig, access); callSuper(code, "<init>", name, parameters, null, sig); code.visitVarInsn(ALOAD, 0); getArgs(code, parameters); code.visitMethodInsn(INVOKEVIRTUAL, classfile.name, "__initProxy__", makeSig("V", $objArr)); code.visitInsn(RETURN); }
// in src/org/python/compiler/JavaMaker.java
Override public void addProxy() throws Exception { if (methods != null) super.addProxy(); // _initProxy method Code code = classfile.addMethod("__initProxy__", makeSig("V", $objArr), Modifier.PUBLIC); code.visitVarInsn(ALOAD, 0); code.visitLdcInsn(pythonModule); code.visitLdcInsn(pythonClass); code.visitVarInsn(ALOAD, 1); code.visitMethodInsn(INVOKESTATIC, "org/python/core/Py", "initProxy", makeSig("V", $pyProxy, $str, $str, $objArr)); code.visitInsn(RETURN); }
// in src/org/python/compiler/JavaMaker.java
Override public void addMethod(Method method, int access) throws Exception { if (Modifier.isAbstract(access)) { // Maybe throw an exception here??? super.addMethod(method, access); } else if (methods.__finditem__(method.getName().intern()) != null) { super.addMethod(method, access); } else if (Modifier.isProtected(method.getModifiers())) { addSuperMethod(method, access); } }
// in src/org/python/compiler/Module.java
PyCodeConstant codeConstant(mod tree, String name, boolean fast_locals, String className, boolean classBody, boolean printResults, int firstlineno, ScopeInfo scope, CompilerFlags cflags) throws Exception { return codeConstant(tree, name, fast_locals, className, null, classBody, printResults, firstlineno, scope, cflags); }
// in src/org/python/compiler/Module.java
PyCodeConstant codeConstant(mod tree, String name, boolean fast_locals, String className, Str classDoc, boolean classBody, boolean printResults, int firstlineno, ScopeInfo scope, CompilerFlags cflags) throws Exception { PyCodeConstant code = new PyCodeConstant(tree, name, fast_locals, className, classBody, printResults, firstlineno, scope, cflags, this); codes.add(code); CodeCompiler compiler = new CodeCompiler(this, printResults); Code c = classfile.addMethod( code.fname, sig(PyObject.class, PyFrame.class, ThreadState.class), ACC_PUBLIC); compiler.parse(tree, c, fast_locals, className, classDoc, classBody, scope, cflags); return code; }
// in src/org/python/compiler/Module.java
public void error(String msg, boolean err, PythonTree node) throws Exception { if (!err) { try { Py.warning(Py.SyntaxWarning, msg, (sfilename != null) ? sfilename : "?", node.getLine(), null, Py.None); return; } catch (PyException e) { if (!e.match(Py.SyntaxWarning)) { throw e; } } } throw new ParseException(msg, node); }
// in src/org/python/compiler/Module.java
public static void compile(mod node, OutputStream ostream, String name, String filename, boolean linenumbers, boolean printResults, CompilerFlags cflags) throws Exception { compile(node, ostream, name, filename, linenumbers, printResults, cflags, org.python.core.imp.NO_MTIME); }
// in src/org/python/compiler/Module.java
public static void compile(mod node, OutputStream ostream, String name, String filename, boolean linenumbers, boolean printResults, CompilerFlags cflags, long mtime) throws Exception { Module module = new Module(name, filename, linenumbers, mtime); if (cflags == null) { cflags = new CompilerFlags(); } module.futures.preprocessFutures(node, cflags); new ScopesCompiler(module, module.scopes).parse(node); //Add __doc__ if it exists Constant main = module.codeConstant(node, "<module>", false, null, false, printResults, 0, module.getScopeInfo(node), cflags); module.mainCode = main; module.write(ostream); }
// in src/org/python/compiler/LegacyCompiler.java
public PyCode loadCode() throws Exception { return BytecodeLoader.makeCode(name, ostream().toByteArray(), filename); }
// in src/org/python/compiler/LegacyCompiler.java
public void writeTo(OutputStream stream) throws Exception { if (this.ostream != null) { stream.write(ostream.toByteArray()); } else { Module.compile(node, stream, name, filename, linenumbers, printResults, cflags); } }
// in src/org/python/compiler/LegacyCompiler.java
public void saveCode(String directory) throws Exception { // FIXME: this is slightly broken, it should use the directory Py.saveClassFile(name, ostream()); }
// in src/org/python/compiler/LegacyCompiler.java
private ByteArrayOutputStream ostream() throws Exception { if (ostream == null) { ostream = new ByteArrayOutputStream(); Module.compile(node, ostream, name, filename, linenumbers, printResults, cflags); } return ostream; }
// in src/org/python/compiler/ArgListCompiler.java
public void visitArgs(arguments args) throws Exception { for (int i = 0; i < args.getInternalArgs().size(); i++) { String name = (String) visit(args.getInternalArgs().get(i)); names.add(name); if (args.getInternalArgs().get(i) instanceof Tuple) { List<expr> targets = new ArrayList<expr>(); targets.add(args.getInternalArgs().get(i)); Assign ass = new Assign(args.getInternalArgs().get(i), targets, new Name(args.getInternalArgs().get(i), name, expr_contextType.Load)); init_code.add(ass); } } if (args.getInternalVararg() != null) { arglist = true; names.add(args.getInternalVararg()); } if (args.getInternalKwarg() != null) { keywordlist = true; names.add(args.getInternalKwarg()); } defaults = args.getInternalDefaults(); for (int i = 0; i < defaults.size(); i++) { if (defaults.get(i) == null) throw new ParseException( "non-default argument follows default argument", args.getInternalArgs().get(args.getInternalArgs().size() - defaults.size() + i)); } }
// in src/org/python/compiler/ArgListCompiler.java
Override public Object visitName(Name node) throws Exception { //FIXME: do we need Store and Param, or just Param? if (node.getInternalCtx() != expr_contextType.Store && node.getInternalCtx() != expr_contextType.Param) { return null; } if (fpnames.contains(node.getInternalId())) { throw new ParseException("duplicate argument name found: " + node.getInternalId(), node); } fpnames.add(node.getInternalId()); return node.getInternalId(); }
// in src/org/python/compiler/ArgListCompiler.java
Override public Object visitTuple(Tuple node) throws Exception { StringBuffer name = new StringBuffer("("); int n = node.getInternalElts().size(); for (int i = 0; i < n-1; i++) { name.append(visit(node.getInternalElts().get(i))); name.append(", "); } name.append(visit(node.getInternalElts().get(n - 1))); name.append(")"); return name.toString(); }
// in src/org/python/compiler/ScopesCompiler.java
public void endScope() throws Exception { if (cur.kind == FUNCSCOPE) { func_level--; } level--; ScopeInfo up = null; if (!scopes.empty()) { up = scopes.pop(); } //Go into the stack to find a non class containing scope to use making the closure //See PEP 227 int dist = 1; ScopeInfo referenceable = up; for (int i = scopes.size() - 1; i >= 0 && referenceable.kind == CLASSSCOPE; i--, dist++) { referenceable = (scopes.get(i)); } cur.cook(referenceable, dist, code_compiler); cur.dump(); // debug cur = up; }
// in src/org/python/compiler/ScopesCompiler.java
public void parse(PythonTree node) throws Exception { try { visit(node); } catch (Throwable t) { throw ParserFacade.fixParseError(null, t, code_compiler.getFilename()); } }
// in src/org/python/compiler/ScopesCompiler.java
Override public Object visitInteractive(Interactive node) throws Exception { beginScope("<single-top>", TOPSCOPE, node, null); suite(node.getInternalBody()); endScope(); return null; }
// in src/org/python/compiler/ScopesCompiler.java
Override public Object visitModule(org.python.antlr.ast.Module node) throws Exception { beginScope("<file-top>", TOPSCOPE, node, null); suite(node.getInternalBody()); endScope(); return null; }
// in src/org/python/compiler/ScopesCompiler.java
Override public Object visitExpression(Expression node) throws Exception { beginScope("<eval-top>", TOPSCOPE, node, null); visit(new Return(node,node.getInternalBody())); endScope(); return null; }
// in src/org/python/compiler/ScopesCompiler.java
Override public Object visitFunctionDef(FunctionDef node) throws Exception { def(node.getInternalName()); ArgListCompiler ac = new ArgListCompiler(); ac.visitArgs(node.getInternalArgs()); List<expr> defaults = ac.getDefaults(); for (int i = 0; i < defaults.size(); i++) { visit(defaults.get(i)); } List<expr> decs = node.getInternalDecorator_list(); for (int i = decs.size() - 1; i >= 0; i--) { visit(decs.get(i)); } beginScope(node.getInternalName(), FUNCSCOPE, node, ac); int n = ac.names.size(); for (int i = 0; i < n; i++) { cur.addParam(ac.names.get(i)); } for (int i = 0; i < ac.init_code.size(); i++) { visit(ac.init_code.get(i)); } cur.markFromParam(); suite(node.getInternalBody()); endScope(); return null; }
// in src/org/python/compiler/ScopesCompiler.java
Override public Object visitLambda(Lambda node) throws Exception { ArgListCompiler ac = new ArgListCompiler(); ac.visitArgs(node.getInternalArgs()); List<? extends PythonTree> defaults = ac.getDefaults(); for (int i = 0; i < defaults.size(); i++) { visit(defaults.get(i)); } beginScope("<lambda>", FUNCSCOPE, node, ac); for (Object o : ac.names) { cur.addParam((String) o); } for (Object o : ac.init_code) { visit((stmt) o); } cur.markFromParam(); visit(node.getInternalBody()); endScope(); return null; }
// in src/org/python/compiler/ScopesCompiler.java
public void suite(List<stmt> stmts) throws Exception { for (int i = 0; i < stmts.size(); i++) visit(stmts.get(i)); }
// in src/org/python/compiler/ScopesCompiler.java
Override public Object visitImport(Import node) throws Exception { for (int i = 0; i < node.getInternalNames().size(); i++) { if (node.getInternalNames().get(i).getInternalAsname() != null) { cur.addBound(node.getInternalNames().get(i).getInternalAsname()); } else { String name = node.getInternalNames().get(i).getInternalName(); if (name.indexOf('.') > 0) { name = name.substring(0, name.indexOf('.')); } cur.addBound(name); } } return null; }
// in src/org/python/compiler/ScopesCompiler.java
Override public Object visitImportFrom(ImportFrom node) throws Exception { Future.checkFromFuture(node); // future stmt support int n = node.getInternalNames().size(); if (n == 0) { cur.from_import_star = true; return null; } for (int i = 0; i < n; i++) { if (node.getInternalNames().get(i).getInternalAsname() != null) { cur.addBound(node.getInternalNames().get(i).getInternalAsname()); } else { cur.addBound(node.getInternalNames().get(i).getInternalName()); } } return null; }
// in src/org/python/compiler/ScopesCompiler.java
Override public Object visitGlobal(Global node) throws Exception { int n = node.getInternalNames().size(); for (int i = 0; i < n; i++) { String name = node.getInternalNames().get(i); int prev = cur.addGlobal(name); if (prev >= 0) { if ((prev & FROM_PARAM) != 0) { code_compiler.error("name '" + name + "' is local and global", true, node); } if ((prev & GLOBAL) != 0) { continue; } String what; if ((prev & BOUND) != 0) { what = "assignment"; } else { what = "use"; } code_compiler.error("name '" + name + "' declared global after " + what, false, node); } } return null; }
// in src/org/python/compiler/ScopesCompiler.java
Override public Object visitExec(Exec node) throws Exception { cur.exec = true; if (node.getInternalGlobals() == null && node.getInternalLocals() == null) { cur.unqual_exec = true; } traverse(node); return null; }
// in src/org/python/compiler/ScopesCompiler.java
Override public Object visitClassDef(ClassDef node) throws Exception { def(node.getInternalName()); int n = node.getInternalBases().size(); for (int i = 0; i < n; i++) { visit(node.getInternalBases().get(i)); } beginScope(node.getInternalName(), CLASSSCOPE, node, null); suite(node.getInternalBody()); endScope(); return null; }
// in src/org/python/compiler/ScopesCompiler.java
Override public Object visitName(Name node) throws Exception { String name = node.getInternalId(); if (node.getInternalCtx() != expr_contextType.Load) { if (name.equals("__debug__")) { code_compiler.error("can not assign to __debug__", true, node); } cur.addBound(name); } else { cur.addUsed(name); } return null; }
// in src/org/python/compiler/ScopesCompiler.java
Override public Object visitListComp(ListComp node) throws Exception { String tmp = "_[" + node.getLine() + "_" + node.getCharPositionInLine() + "]"; cur.addBound(tmp); traverse(node); return null; }
// in src/org/python/compiler/ScopesCompiler.java
Override public Object visitYield(Yield node) throws Exception { cur.defineAsGenerator(node); cur.yield_count++; traverse(node); return null; }
// in src/org/python/compiler/ScopesCompiler.java
Override public Object visitReturn(Return node) throws Exception { if (node.getInternalValue() != null) { cur.noteReturnValue(node); } traverse(node); return null; }
// in src/org/python/compiler/ScopesCompiler.java
Override public Object visitGeneratorExp(GeneratorExp node) throws Exception { // The first iterator is evaluated in the outer scope if (node.getInternalGenerators() != null && node.getInternalGenerators().size() > 0) { visit(node.getInternalGenerators().get(0).getInternalIter()); } String bound_exp = "_(x)"; String tmp = "_(" + node.getLine() + "_" + node.getCharPositionInLine() + ")"; def(tmp); ArgListCompiler ac = new ArgListCompiler(); List<expr> args = new ArrayList<expr>(); args.add(new Name(node.getToken(), bound_exp, expr_contextType.Param)); ac.visitArgs(new arguments(node, args, null, null, new ArrayList<expr>())); beginScope(tmp, FUNCSCOPE, node, ac); cur.addParam(bound_exp); cur.markFromParam(); cur.defineAsGenerator(node); cur.yield_count++; // The reset of the iterators are evaluated in the inner scope if (node.getInternalElt() != null) { visit(node.getInternalElt()); } if (node.getInternalGenerators() != null) { for (int i = 0; i < node.getInternalGenerators().size(); i++) { if (node.getInternalGenerators().get(i) != null) { if (i == 0) { visit(node.getInternalGenerators().get(i).getInternalTarget()); if (node.getInternalGenerators().get(i).getInternalIfs() != null) { for (expr cond : node.getInternalGenerators().get(i).getInternalIfs()) { if (cond != null) { visit(cond); } } } } else { visit(node.getInternalGenerators().get(i)); } } } } endScope(); return null; }
// in src/org/python/compiler/ScopesCompiler.java
Override public Object visitWith(With node) throws Exception { cur.max_with_count++; traverse(node); return null; }
// in src/org/python/antlr/PythonTree.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { throw new RuntimeException("Unexpected node: " + this); }
// in src/org/python/antlr/PythonTree.java
public void traverse(VisitorIF<?> visitor) throws Exception { throw new RuntimeException("Cannot traverse node: " + this); }
// in src/org/python/antlr/ast/ClassDef.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { return visitor.visitClassDef(this); }
// in src/org/python/antlr/ast/ClassDef.java
public void traverse(VisitorIF<?> visitor) throws Exception { if (bases != null) { for (PythonTree t : bases) { if (t != null) t.accept(visitor); } } if (body != null) { for (PythonTree t : body) { if (t != null) t.accept(visitor); } } if (decorator_list != null) { for (PythonTree t : decorator_list) { if (t != null) t.accept(visitor); } } }
// in src/org/python/antlr/ast/Ellipsis.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { return visitor.visitEllipsis(this); }
// in src/org/python/antlr/ast/Ellipsis.java
public void traverse(VisitorIF<?> visitor) throws Exception { }
// in src/org/python/antlr/ast/ExtSlice.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { return visitor.visitExtSlice(this); }
// in src/org/python/antlr/ast/ExtSlice.java
public void traverse(VisitorIF<?> visitor) throws Exception { if (dims != null) { for (PythonTree t : dims) { if (t != null) t.accept(visitor); } } }
// in src/org/python/antlr/ast/Dict.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { return visitor.visitDict(this); }
// in src/org/python/antlr/ast/Dict.java
public void traverse(VisitorIF<?> visitor) throws Exception { if (keys != null) { for (PythonTree t : keys) { if (t != null) t.accept(visitor); } } if (values != null) { for (PythonTree t : values) { if (t != null) t.accept(visitor); } } }
// in src/org/python/antlr/ast/Assign.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { return visitor.visitAssign(this); }
// in src/org/python/antlr/ast/Assign.java
public void traverse(VisitorIF<?> visitor) throws Exception { if (targets != null) { for (PythonTree t : targets) { if (t != null) t.accept(visitor); } } if (value != null) value.accept(visitor); }
// in src/org/python/antlr/ast/Name.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { return visitor.visitName(this); }
// in src/org/python/antlr/ast/Name.java
public void traverse(VisitorIF<?> visitor) throws Exception { }
// in src/org/python/antlr/ast/UnaryOp.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { return visitor.visitUnaryOp(this); }
// in src/org/python/antlr/ast/UnaryOp.java
public void traverse(VisitorIF<?> visitor) throws Exception { if (operand != null) operand.accept(visitor); }
// in src/org/python/antlr/ast/Expr.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { return visitor.visitExpr(this); }
// in src/org/python/antlr/ast/Expr.java
public void traverse(VisitorIF<?> visitor) throws Exception { if (value != null) value.accept(visitor); }
// in src/org/python/antlr/ast/ImportFrom.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { return visitor.visitImportFrom(this); }
// in src/org/python/antlr/ast/ImportFrom.java
public void traverse(VisitorIF<?> visitor) throws Exception { if (names != null) { for (PythonTree t : names) { if (t != null) t.accept(visitor); } } }
// in src/org/python/antlr/ast/Subscript.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { return visitor.visitSubscript(this); }
// in src/org/python/antlr/ast/Subscript.java
public void traverse(VisitorIF<?> visitor) throws Exception { if (value != null) value.accept(visitor); if (slice != null) slice.accept(visitor); }
// in src/org/python/antlr/ast/FunctionDef.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { return visitor.visitFunctionDef(this); }
// in src/org/python/antlr/ast/FunctionDef.java
public void traverse(VisitorIF<?> visitor) throws Exception { if (args != null) args.accept(visitor); if (body != null) { for (PythonTree t : body) { if (t != null) t.accept(visitor); } } if (decorator_list != null) { for (PythonTree t : decorator_list) { if (t != null) t.accept(visitor); } } }
// in src/org/python/antlr/ast/Import.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { return visitor.visitImport(this); }
// in src/org/python/antlr/ast/Import.java
public void traverse(VisitorIF<?> visitor) throws Exception { if (names != null) { for (PythonTree t : names) { if (t != null) t.accept(visitor); } } }
// in src/org/python/antlr/ast/keyword.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { traverse(visitor); return null; }
// in src/org/python/antlr/ast/keyword.java
public void traverse(VisitorIF<?> visitor) throws Exception { if (value != null) value.accept(visitor); }
// in src/org/python/antlr/ast/Pass.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { return visitor.visitPass(this); }
// in src/org/python/antlr/ast/Pass.java
public void traverse(VisitorIF<?> visitor) throws Exception { }
// in src/org/python/antlr/ast/Num.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { return visitor.visitNum(this); }
// in src/org/python/antlr/ast/Num.java
public void traverse(VisitorIF<?> visitor) throws Exception { }
// in src/org/python/antlr/ast/List.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { return visitor.visitList(this); }
// in src/org/python/antlr/ast/List.java
public void traverse(VisitorIF<?> visitor) throws Exception { if (elts != null) { for (PythonTree t : elts) { if (t != null) t.accept(visitor); } } }
// in src/org/python/antlr/ast/comprehension.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { traverse(visitor); return null; }
// in src/org/python/antlr/ast/comprehension.java
public void traverse(VisitorIF<?> visitor) throws Exception { if (target != null) target.accept(visitor); if (iter != null) iter.accept(visitor); if (ifs != null) { for (PythonTree t : ifs) { if (t != null) t.accept(visitor); } } }
// in src/org/python/antlr/ast/ErrorSlice.java
public void traverse(VisitorIF visitor) throws Exception { //no op. }
// in src/org/python/antlr/ast/Break.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { return visitor.visitBreak(this); }
// in src/org/python/antlr/ast/Break.java
public void traverse(VisitorIF<?> visitor) throws Exception { }
// in src/org/python/antlr/ast/Compare.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { return visitor.visitCompare(this); }
// in src/org/python/antlr/ast/Compare.java
public void traverse(VisitorIF<?> visitor) throws Exception { if (left != null) left.accept(visitor); if (comparators != null) { for (PythonTree t : comparators) { if (t != null) t.accept(visitor); } } }
// in src/org/python/antlr/ast/Return.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { return visitor.visitReturn(this); }
// in src/org/python/antlr/ast/Return.java
public void traverse(VisitorIF<?> visitor) throws Exception { if (value != null) value.accept(visitor); }
// in src/org/python/antlr/ast/While.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { return visitor.visitWhile(this); }
// in src/org/python/antlr/ast/While.java
public void traverse(VisitorIF<?> visitor) throws Exception { if (test != null) test.accept(visitor); if (body != null) { for (PythonTree t : body) { if (t != null) t.accept(visitor); } } if (orelse != null) { for (PythonTree t : orelse) { if (t != null) t.accept(visitor); } } }
// in src/org/python/antlr/ast/ListComp.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { return visitor.visitListComp(this); }
// in src/org/python/antlr/ast/ListComp.java
public void traverse(VisitorIF<?> visitor) throws Exception { if (elt != null) elt.accept(visitor); if (generators != null) { for (PythonTree t : generators) { if (t != null) t.accept(visitor); } } }
// in src/org/python/antlr/ast/Yield.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { return visitor.visitYield(this); }
// in src/org/python/antlr/ast/Yield.java
public void traverse(VisitorIF<?> visitor) throws Exception { if (value != null) value.accept(visitor); }
// in src/org/python/antlr/ast/arguments.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { traverse(visitor); return null; }
// in src/org/python/antlr/ast/arguments.java
public void traverse(VisitorIF<?> visitor) throws Exception { if (args != null) { for (PythonTree t : args) { if (t != null) t.accept(visitor); } } if (defaults != null) { for (PythonTree t : defaults) { if (t != null) t.accept(visitor); } } }
// in src/org/python/antlr/ast/alias.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { traverse(visitor); return null; }
// in src/org/python/antlr/ast/alias.java
public void traverse(VisitorIF<?> visitor) throws Exception { }
// in src/org/python/antlr/ast/Delete.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { return visitor.visitDelete(this); }
// in src/org/python/antlr/ast/Delete.java
public void traverse(VisitorIF<?> visitor) throws Exception { if (targets != null) { for (PythonTree t : targets) { if (t != null) t.accept(visitor); } } }
// in src/org/python/antlr/ast/Interactive.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { return visitor.visitInteractive(this); }
// in src/org/python/antlr/ast/Interactive.java
public void traverse(VisitorIF<?> visitor) throws Exception { if (body != null) { for (PythonTree t : body) { if (t != null) t.accept(visitor); } } }
// in src/org/python/antlr/ast/Module.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { return visitor.visitModule(this); }
// in src/org/python/antlr/ast/Module.java
public void traverse(VisitorIF<?> visitor) throws Exception { if (body != null) { for (PythonTree t : body) { if (t != null) t.accept(visitor); } } }
// in src/org/python/antlr/ast/IfExp.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { return visitor.visitIfExp(this); }
// in src/org/python/antlr/ast/IfExp.java
public void traverse(VisitorIF<?> visitor) throws Exception { if (test != null) test.accept(visitor); if (body != null) body.accept(visitor); if (orelse != null) orelse.accept(visitor); }
// in src/org/python/antlr/ast/TryFinally.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { return visitor.visitTryFinally(this); }
// in src/org/python/antlr/ast/TryFinally.java
public void traverse(VisitorIF<?> visitor) throws Exception { if (body != null) { for (PythonTree t : body) { if (t != null) t.accept(visitor); } } if (finalbody != null) { for (PythonTree t : finalbody) { if (t != null) t.accept(visitor); } } }
// in src/org/python/antlr/ast/ErrorStmt.java
public void traverse(VisitorIF visitor) throws Exception { //no op. }
// in src/org/python/antlr/ast/If.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { return visitor.visitIf(this); }
// in src/org/python/antlr/ast/If.java
public void traverse(VisitorIF<?> visitor) throws Exception { if (test != null) test.accept(visitor); if (body != null) { for (PythonTree t : body) { if (t != null) t.accept(visitor); } } if (orelse != null) { for (PythonTree t : orelse) { if (t != null) t.accept(visitor); } } }
// in src/org/python/antlr/ast/Suite.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { return visitor.visitSuite(this); }
// in src/org/python/antlr/ast/Suite.java
public void traverse(VisitorIF<?> visitor) throws Exception { if (body != null) { for (PythonTree t : body) { if (t != null) t.accept(visitor); } } }
// in src/org/python/antlr/ast/Attribute.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { return visitor.visitAttribute(this); }
// in src/org/python/antlr/ast/Attribute.java
public void traverse(VisitorIF<?> visitor) throws Exception { if (value != null) value.accept(visitor); }
// in src/org/python/antlr/ast/ErrorExpr.java
public void traverse(VisitorIF visitor) throws Exception { //no op. }
// in src/org/python/antlr/ast/BinOp.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { return visitor.visitBinOp(this); }
// in src/org/python/antlr/ast/BinOp.java
public void traverse(VisitorIF<?> visitor) throws Exception { if (left != null) left.accept(visitor); if (right != null) right.accept(visitor); }
// in src/org/python/antlr/ast/Lambda.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { return visitor.visitLambda(this); }
// in src/org/python/antlr/ast/Lambda.java
public void traverse(VisitorIF<?> visitor) throws Exception { if (args != null) args.accept(visitor); if (body != null) body.accept(visitor); }
// in src/org/python/antlr/ast/Call.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { return visitor.visitCall(this); }
// in src/org/python/antlr/ast/Call.java
public void traverse(VisitorIF<?> visitor) throws Exception { if (func != null) func.accept(visitor); if (args != null) { for (PythonTree t : args) { if (t != null) t.accept(visitor); } } if (keywords != null) { for (PythonTree t : keywords) { if (t != null) t.accept(visitor); } } if (starargs != null) starargs.accept(visitor); if (kwargs != null) kwargs.accept(visitor); }
// in src/org/python/antlr/ast/VisitorBase.java
public R visitModule(Module node) throws Exception { R ret = unhandled_node(node); traverse(node); return ret; }
// in src/org/python/antlr/ast/VisitorBase.java
public R visitInteractive(Interactive node) throws Exception { R ret = unhandled_node(node); traverse(node); return ret; }
// in src/org/python/antlr/ast/VisitorBase.java
public R visitExpression(Expression node) throws Exception { R ret = unhandled_node(node); traverse(node); return ret; }
// in src/org/python/antlr/ast/VisitorBase.java
public R visitSuite(Suite node) throws Exception { R ret = unhandled_node(node); traverse(node); return ret; }
// in src/org/python/antlr/ast/VisitorBase.java
public R visitFunctionDef(FunctionDef node) throws Exception { R ret = unhandled_node(node); traverse(node); return ret; }
// in src/org/python/antlr/ast/VisitorBase.java
public R visitClassDef(ClassDef node) throws Exception { R ret = unhandled_node(node); traverse(node); return ret; }
// in src/org/python/antlr/ast/VisitorBase.java
public R visitReturn(Return node) throws Exception { R ret = unhandled_node(node); traverse(node); return ret; }
// in src/org/python/antlr/ast/VisitorBase.java
public R visitDelete(Delete node) throws Exception { R ret = unhandled_node(node); traverse(node); return ret; }
// in src/org/python/antlr/ast/VisitorBase.java
public R visitAssign(Assign node) throws Exception { R ret = unhandled_node(node); traverse(node); return ret; }
// in src/org/python/antlr/ast/VisitorBase.java
public R visitAugAssign(AugAssign node) throws Exception { R ret = unhandled_node(node); traverse(node); return ret; }
// in src/org/python/antlr/ast/VisitorBase.java
public R visitPrint(Print node) throws Exception { R ret = unhandled_node(node); traverse(node); return ret; }
// in src/org/python/antlr/ast/VisitorBase.java
public R visitFor(For node) throws Exception { R ret = unhandled_node(node); traverse(node); return ret; }
// in src/org/python/antlr/ast/VisitorBase.java
public R visitWhile(While node) throws Exception { R ret = unhandled_node(node); traverse(node); return ret; }
// in src/org/python/antlr/ast/VisitorBase.java
public R visitIf(If node) throws Exception { R ret = unhandled_node(node); traverse(node); return ret; }
// in src/org/python/antlr/ast/VisitorBase.java
public R visitWith(With node) throws Exception { R ret = unhandled_node(node); traverse(node); return ret; }
// in src/org/python/antlr/ast/VisitorBase.java
public R visitRaise(Raise node) throws Exception { R ret = unhandled_node(node); traverse(node); return ret; }
// in src/org/python/antlr/ast/VisitorBase.java
public R visitTryExcept(TryExcept node) throws Exception { R ret = unhandled_node(node); traverse(node); return ret; }
// in src/org/python/antlr/ast/VisitorBase.java
public R visitTryFinally(TryFinally node) throws Exception { R ret = unhandled_node(node); traverse(node); return ret; }
// in src/org/python/antlr/ast/VisitorBase.java
public R visitAssert(Assert node) throws Exception { R ret = unhandled_node(node); traverse(node); return ret; }
// in src/org/python/antlr/ast/VisitorBase.java
public R visitImport(Import node) throws Exception { R ret = unhandled_node(node); traverse(node); return ret; }
// in src/org/python/antlr/ast/VisitorBase.java
public R visitImportFrom(ImportFrom node) throws Exception { R ret = unhandled_node(node); traverse(node); return ret; }
// in src/org/python/antlr/ast/VisitorBase.java
public R visitExec(Exec node) throws Exception { R ret = unhandled_node(node); traverse(node); return ret; }
// in src/org/python/antlr/ast/VisitorBase.java
public R visitGlobal(Global node) throws Exception { R ret = unhandled_node(node); traverse(node); return ret; }
// in src/org/python/antlr/ast/VisitorBase.java
public R visitExpr(Expr node) throws Exception { R ret = unhandled_node(node); traverse(node); return ret; }
// in src/org/python/antlr/ast/VisitorBase.java
public R visitPass(Pass node) throws Exception { R ret = unhandled_node(node); traverse(node); return ret; }
// in src/org/python/antlr/ast/VisitorBase.java
public R visitBreak(Break node) throws Exception { R ret = unhandled_node(node); traverse(node); return ret; }
// in src/org/python/antlr/ast/VisitorBase.java
public R visitContinue(Continue node) throws Exception { R ret = unhandled_node(node); traverse(node); return ret; }
// in src/org/python/antlr/ast/VisitorBase.java
public R visitBoolOp(BoolOp node) throws Exception { R ret = unhandled_node(node); traverse(node); return ret; }
// in src/org/python/antlr/ast/VisitorBase.java
public R visitBinOp(BinOp node) throws Exception { R ret = unhandled_node(node); traverse(node); return ret; }
// in src/org/python/antlr/ast/VisitorBase.java
public R visitUnaryOp(UnaryOp node) throws Exception { R ret = unhandled_node(node); traverse(node); return ret; }
// in src/org/python/antlr/ast/VisitorBase.java
public R visitLambda(Lambda node) throws Exception { R ret = unhandled_node(node); traverse(node); return ret; }
// in src/org/python/antlr/ast/VisitorBase.java
public R visitIfExp(IfExp node) throws Exception { R ret = unhandled_node(node); traverse(node); return ret; }
// in src/org/python/antlr/ast/VisitorBase.java
public R visitDict(Dict node) throws Exception { R ret = unhandled_node(node); traverse(node); return ret; }
// in src/org/python/antlr/ast/VisitorBase.java
public R visitListComp(ListComp node) throws Exception { R ret = unhandled_node(node); traverse(node); return ret; }
// in src/org/python/antlr/ast/VisitorBase.java
public R visitGeneratorExp(GeneratorExp node) throws Exception { R ret = unhandled_node(node); traverse(node); return ret; }
// in src/org/python/antlr/ast/VisitorBase.java
public R visitYield(Yield node) throws Exception { R ret = unhandled_node(node); traverse(node); return ret; }
// in src/org/python/antlr/ast/VisitorBase.java
public R visitCompare(Compare node) throws Exception { R ret = unhandled_node(node); traverse(node); return ret; }
// in src/org/python/antlr/ast/VisitorBase.java
public R visitCall(Call node) throws Exception { R ret = unhandled_node(node); traverse(node); return ret; }
// in src/org/python/antlr/ast/VisitorBase.java
public R visitRepr(Repr node) throws Exception { R ret = unhandled_node(node); traverse(node); return ret; }
// in src/org/python/antlr/ast/VisitorBase.java
public R visitNum(Num node) throws Exception { R ret = unhandled_node(node); traverse(node); return ret; }
// in src/org/python/antlr/ast/VisitorBase.java
public R visitStr(Str node) throws Exception { R ret = unhandled_node(node); traverse(node); return ret; }
// in src/org/python/antlr/ast/VisitorBase.java
public R visitAttribute(Attribute node) throws Exception { R ret = unhandled_node(node); traverse(node); return ret; }
// in src/org/python/antlr/ast/VisitorBase.java
public R visitSubscript(Subscript node) throws Exception { R ret = unhandled_node(node); traverse(node); return ret; }
// in src/org/python/antlr/ast/VisitorBase.java
public R visitName(Name node) throws Exception { R ret = unhandled_node(node); traverse(node); return ret; }
// in src/org/python/antlr/ast/VisitorBase.java
public R visitList(List node) throws Exception { R ret = unhandled_node(node); traverse(node); return ret; }
// in src/org/python/antlr/ast/VisitorBase.java
public R visitTuple(Tuple node) throws Exception { R ret = unhandled_node(node); traverse(node); return ret; }
// in src/org/python/antlr/ast/VisitorBase.java
public R visitEllipsis(Ellipsis node) throws Exception { R ret = unhandled_node(node); traverse(node); return ret; }
// in src/org/python/antlr/ast/VisitorBase.java
public R visitSlice(Slice node) throws Exception { R ret = unhandled_node(node); traverse(node); return ret; }
// in src/org/python/antlr/ast/VisitorBase.java
public R visitExtSlice(ExtSlice node) throws Exception { R ret = unhandled_node(node); traverse(node); return ret; }
// in src/org/python/antlr/ast/VisitorBase.java
public R visitIndex(Index node) throws Exception { R ret = unhandled_node(node); traverse(node); return ret; }
// in src/org/python/antlr/ast/VisitorBase.java
public R visitExceptHandler(ExceptHandler node) throws Exception { R ret = unhandled_node(node); traverse(node); return ret; }
// in src/org/python/antlr/ast/Global.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { return visitor.visitGlobal(this); }
// in src/org/python/antlr/ast/Global.java
public void traverse(VisitorIF<?> visitor) throws Exception { }
// in src/org/python/antlr/ast/Tuple.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { return visitor.visitTuple(this); }
// in src/org/python/antlr/ast/Tuple.java
public void traverse(VisitorIF<?> visitor) throws Exception { if (elts != null) { for (PythonTree t : elts) { if (t != null) t.accept(visitor); } } }
// in src/org/python/antlr/ast/ExceptHandler.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { return visitor.visitExceptHandler(this); }
// in src/org/python/antlr/ast/ExceptHandler.java
public void traverse(VisitorIF<?> visitor) throws Exception { if (type != null) type.accept(visitor); if (name != null) name.accept(visitor); if (body != null) { for (PythonTree t : body) { if (t != null) t.accept(visitor); } } }
// in src/org/python/antlr/ast/With.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { return visitor.visitWith(this); }
// in src/org/python/antlr/ast/With.java
public void traverse(VisitorIF<?> visitor) throws Exception { if (context_expr != null) context_expr.accept(visitor); if (optional_vars != null) optional_vars.accept(visitor); if (body != null) { for (PythonTree t : body) { if (t != null) t.accept(visitor); } } }
// in src/org/python/antlr/ast/Repr.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { return visitor.visitRepr(this); }
// in src/org/python/antlr/ast/Repr.java
public void traverse(VisitorIF<?> visitor) throws Exception { if (value != null) value.accept(visitor); }
// in src/org/python/antlr/ast/Slice.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { return visitor.visitSlice(this); }
// in src/org/python/antlr/ast/Slice.java
public void traverse(VisitorIF<?> visitor) throws Exception { if (lower != null) lower.accept(visitor); if (upper != null) upper.accept(visitor); if (step != null) step.accept(visitor); }
// in src/org/python/antlr/ast/TryExcept.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { return visitor.visitTryExcept(this); }
// in src/org/python/antlr/ast/TryExcept.java
public void traverse(VisitorIF<?> visitor) throws Exception { if (body != null) { for (PythonTree t : body) { if (t != null) t.accept(visitor); } } if (handlers != null) { for (PythonTree t : handlers) { if (t != null) t.accept(visitor); } } if (orelse != null) { for (PythonTree t : orelse) { if (t != null) t.accept(visitor); } } }
// in src/org/python/antlr/ast/Str.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { return visitor.visitStr(this); }
// in src/org/python/antlr/ast/Str.java
public void traverse(VisitorIF<?> visitor) throws Exception { }
// in src/org/python/antlr/ast/Exec.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { return visitor.visitExec(this); }
// in src/org/python/antlr/ast/Exec.java
public void traverse(VisitorIF<?> visitor) throws Exception { if (body != null) body.accept(visitor); if (globals != null) globals.accept(visitor); if (locals != null) locals.accept(visitor); }
// in src/org/python/antlr/ast/Raise.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { return visitor.visitRaise(this); }
// in src/org/python/antlr/ast/Raise.java
public void traverse(VisitorIF<?> visitor) throws Exception { if (type != null) type.accept(visitor); if (inst != null) inst.accept(visitor); if (tback != null) tback.accept(visitor); }
// in src/org/python/antlr/ast/Continue.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { return visitor.visitContinue(this); }
// in src/org/python/antlr/ast/Continue.java
public void traverse(VisitorIF<?> visitor) throws Exception { }
// in src/org/python/antlr/ast/BoolOp.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { return visitor.visitBoolOp(this); }
// in src/org/python/antlr/ast/BoolOp.java
public void traverse(VisitorIF<?> visitor) throws Exception { if (values != null) { for (PythonTree t : values) { if (t != null) t.accept(visitor); } } }
// in src/org/python/antlr/ast/GeneratorExp.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { return visitor.visitGeneratorExp(this); }
// in src/org/python/antlr/ast/GeneratorExp.java
public void traverse(VisitorIF<?> visitor) throws Exception { if (elt != null) elt.accept(visitor); if (generators != null) { for (PythonTree t : generators) { if (t != null) t.accept(visitor); } } }
// in src/org/python/antlr/ast/AugAssign.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { return visitor.visitAugAssign(this); }
// in src/org/python/antlr/ast/AugAssign.java
public void traverse(VisitorIF<?> visitor) throws Exception { if (target != null) target.accept(visitor); if (value != null) value.accept(visitor); }
// in src/org/python/antlr/ast/ErrorMod.java
public void traverse(VisitorIF visitor) throws Exception { //no op. }
// in src/org/python/antlr/ast/Assert.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { return visitor.visitAssert(this); }
// in src/org/python/antlr/ast/Assert.java
public void traverse(VisitorIF<?> visitor) throws Exception { if (test != null) test.accept(visitor); if (msg != null) msg.accept(visitor); }
// in src/org/python/antlr/ast/Print.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { return visitor.visitPrint(this); }
// in src/org/python/antlr/ast/Print.java
public void traverse(VisitorIF<?> visitor) throws Exception { if (dest != null) dest.accept(visitor); if (values != null) { for (PythonTree t : values) { if (t != null) t.accept(visitor); } } }
// in src/org/python/antlr/ast/For.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { return visitor.visitFor(this); }
// in src/org/python/antlr/ast/For.java
public void traverse(VisitorIF<?> visitor) throws Exception { if (target != null) target.accept(visitor); if (iter != null) iter.accept(visitor); if (body != null) { for (PythonTree t : body) { if (t != null) t.accept(visitor); } } if (orelse != null) { for (PythonTree t : orelse) { if (t != null) t.accept(visitor); } } }
// in src/org/python/antlr/ast/Expression.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { return visitor.visitExpression(this); }
// in src/org/python/antlr/ast/Expression.java
public void traverse(VisitorIF<?> visitor) throws Exception { if (body != null) body.accept(visitor); }
// in src/org/python/antlr/ast/Index.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { return visitor.visitIndex(this); }
// in src/org/python/antlr/ast/Index.java
public void traverse(VisitorIF<?> visitor) throws Exception { if (value != null) value.accept(visitor); }
// in src/org/python/antlr/Visitor.java
public void traverse(PythonTree node) throws Exception { node.traverse(this); }
// in src/org/python/antlr/Visitor.java
public void visit(PythonTree[] nodes) throws Exception { for (int i = 0; i < nodes.length; i++) { visit(nodes[i]); } }
// in src/org/python/antlr/Visitor.java
public Object visit(PythonTree node) throws Exception { Object ret = node.accept(this); return ret; }
// in src/org/python/antlr/Visitor.java
protected Object unhandled_node(PythonTree node) throws Exception { return this; }
// in src/org/python/modules/ucnhash.java
public static void loadTables() throws Exception { InputStream instream = ucnhash.class. getResourceAsStream("ucnhash.dat"); if (instream == null) throw new IOException("Unicode name database not found: " + "ucnhash.dat"); DataInputStream in = new DataInputStream( new BufferedInputStream(instream)); n = in.readShort(); m = in.readShort(); minchar= in.readShort(); maxchar = in.readShort(); alphasz = in.readShort(); maxlen = in.readShort(); maxidx = maxlen*alphasz-minchar; G = readShortTable(in); if (in.readShort() != 3) throw new IOException("UnicodeNameMap file corrupt, " + "unknown dimension"); T0 = readShortTable(in); T1 = readShortTable(in); T2 = readShortTable(in); wordoffs = readShortTable(in); worddata = readByteTable(in); wordstart = in.readShort(); wordcutoff = in.readShort(); maxklen = in.readShort(); rawdata = readByteTable(in); rawindex = readCharTable(in); codepoint = readCharTable(in); }
// in src/org/python/modules/ucnhash.java
public static void main(String[] args) throws Exception { loadTables(); debug = true; /* System.out.println(getWord(hash("ARABIC"))); System.out.println(getWord(hash("SMALL"))); System.out.println(getWord(hash("YI"))); System.out.println(getWord(hash("SYLLABLE"))); System.out.println(getWord(hash("WITH"))); System.out.println(getWord(hash("LETTER"))); System.out.println(lookup("NULL")); System.out.println(lookup("LATIN CAPITAL LETTER AFRICAN D")); System.out.println(lookup("GURMUKHI TIPPI")); System.out.println(lookup("TIBETAN MARK GTER YIG MGO -UM " + "RNAM BCAD MA")); System.out.println(lookup("HANGUL CHOSEONG PIEUP")); System.out.println(lookup("SINGLE LOW-9 QUOTATION MARK")); */ System.out.println(lookup("BACKSPACE")); // System.out.println(lookup("ACTIVATE SYMMETRIC SWAPPING")); /* System.out.println(lookup("LATIN CAPITAL LETTER A")); System.out.println(lookup("GREATER-THAN SIGN")); System.out.println(lookup("EURO-CURRENCY SIGN")); */ }
// in src/org/python/core/Py.java
public static void runMain(PyRunnable main, String[] args) throws Exception { runMain(new PyRunnableBootstrap(main), args); }
// in src/org/python/core/Py.java
public static void runMain(CodeBootstrap main, String[] args) throws Exception { PySystemState.initialize(null, null, args, main.getClass().getClassLoader()); try { imp.createFromCode("__main__", CodeLoader.loadCode(main)); } catch (PyException e) { Py.getSystemState().callExitFunc(); if (e.match(Py.SystemExit)) { return; } throw e; } Py.getSystemState().callExitFunc(); }
(Lib) FileNotFoundException 1
              
// in src/org/python/core/io/FileIO.java
private void fromRandomAccessFile(File absPath) throws FileNotFoundException { String rafMode = "r" + (writing ? "w" : ""); if (plus && reading && !absPath.isFile()) { // suppress "permission denied" writing = false; throw new FileNotFoundException(""); } file = new RandomAccessFile(absPath, rafMode); fileChannel = file.getChannel(); }
0 2
              
// in src/org/python/core/io/FileIO.java
private void fromRandomAccessFile(File absPath) throws FileNotFoundException { String rafMode = "r" + (writing ? "w" : ""); if (plus && reading && !absPath.isFile()) { // suppress "permission denied" writing = false; throw new FileNotFoundException(""); } file = new RandomAccessFile(absPath, rafMode); fileChannel = file.getChannel(); }
// in src/org/python/core/io/FileIO.java
private void fromFileOutputStream(File absPath) throws FileNotFoundException { fileOutputStream = new FileOutputStream(absPath, true); fileChannel = fileOutputStream.getChannel(); }
(Lib) InstantiationException 1
              
// in src/org/python/compiler/ProxyMaker.java
public void build() throws Exception { names = Generic.set(); int access = superclass.getModifiers(); if ((access & Modifier.FINAL) != 0) { throw new InstantiationException("can't subclass final class"); } access = Modifier.PUBLIC | Modifier.SYNCHRONIZED; classfile = new ClassFile(myClass, mapClass(superclass), access); addProxy(); addConstructors(superclass); classfile.addInterface("org/python/core/PyProxy"); Set<String> seenmethods = Generic.set(); addMethods(superclass, seenmethods); for (Class<?> iface : interfaces) { if (iface.isAssignableFrom(superclass)) { Py.writeWarning("compiler", "discarding redundant interface: " + iface.getName()); continue; } classfile.addInterface(mapClass(iface)); addMethods(iface, seenmethods); } doConstants(); addClassDictInit(); }
0 0
(Lib) InvalidClassException 1
              
// in src/org/python/core/PyJavaType.java
Override protected Class<?> resolveClass(ObjectStreamClass osc) throws IOException, ClassNotFoundException { Class<?> c = output.classQueue.poll(); String expected = osc.getName(); String found = (c == null) ? null : c.getName(); if (!expected.equals(found)) { throw new InvalidClassException("Classes desynchronized: " + "found " + found + " when expecting " + expected); } return c; }
0 0
(Lib) NoSuchElementException 1
              
// in src/org/python/core/WrappedIterIterator.java
public PyObject getNext() { if (!hasNext()) { throw new NoSuchElementException("End of the line, bub"); } PyObject toReturn = next; checkedForNext = false; next = null; return toReturn; }
0 0
(Lib) NumberFormatException 1
              
// in src/org/python/core/PyString.java
public double atof() { StringBuilder s = null; int n = getString().length(); for (int i = 0; i < n; i++) { char ch = getString().charAt(i); if (ch == '\u0000') { throw Py.ValueError("null byte in argument for float()"); } if (Character.isDigit(ch)) { if (s == null) s = new StringBuilder(getString()); int val = Character.digit(ch, 10); s.setCharAt(i, Character.forDigit(val, 10)); } } String sval = getString(); if (s != null) sval = s.toString(); try { // Double.valueOf allows format specifier ("d" or "f") at the end String lowSval = sval.toLowerCase(); if (lowSval.equals("nan")) return Double.NaN; else if (lowSval.equals("inf")) return Double.POSITIVE_INFINITY; else if (lowSval.equals("-inf")) return Double.NEGATIVE_INFINITY; if (lowSval.endsWith("d") || lowSval.endsWith("f")) { throw new NumberFormatException("format specifiers not allowed"); } return Double.valueOf(sval).doubleValue(); } catch (NumberFormatException exc) { throw Py.ValueError("invalid literal for __float__: "+getString()); } }
0 0
(Domain) PySyntaxError 1
              
// in src/org/python/core/ParserFacade.java
private static ExpectedEncodingBufferedReader prepBufReader(InputStream input, CompilerFlags cflags, String filename, boolean fromString, boolean universalNewlines) throws IOException { input = new BufferedInputStream(input); boolean bom = adjustForBOM(input); String encoding = readEncoding(input); if (encoding == null) { if (bom) { encoding = "utf-8"; } else if (cflags != null && cflags.encoding != null) { encoding = cflags.encoding; } } if (cflags.source_is_utf8) { if (encoding != null) { throw new ParseException("encoding declaration in Unicode string"); } encoding = "utf-8"; } cflags.encoding = encoding; if (universalNewlines) { // Enable universal newlines mode on the input StreamIO rawIO = new StreamIO(input, true); org.python.core.io.BufferedReader bufferedIO = new org.python.core.io.BufferedReader(rawIO, 0); UniversalIOWrapper textIO = new UniversalIOWrapper(bufferedIO); input = new TextIOInputStream(textIO); } Charset cs; try { // Use ascii for the raw bytes when no encoding was specified if (encoding == null) { if (fromString) { cs = Charset.forName("ISO-8859-1"); } else { cs = Charset.forName("ascii"); } } else { cs = Charset.forName(encoding); } } catch (UnsupportedCharsetException exc) { throw new PySyntaxError("Unknown encoding: " + encoding, 1, 0, "", filename); } CharsetDecoder dec = cs.newDecoder(); dec.onMalformedInput(CodingErrorAction.REPORT); dec.onUnmappableCharacter(CodingErrorAction.REPORT); return new ExpectedEncodingBufferedReader(new InputStreamReader(input, dec), encoding); }
1
              
// in src/org/python/core/ParserFacade.java
catch (UnsupportedCharsetException exc) { throw new PySyntaxError("Unknown encoding: " + encoding, 1, 0, "", filename); }
0
(Lib) StreamCorruptedException 1
              
// in src/org/python/core/Py.java
private Object readResolve() throws ObjectStreamException { if (which.equals("None")) { return Py.None; } else if (which.equals("Ellipsis")) { return Py.Ellipsis; } else if (which.equals("NotImplemented")) { return Py.NotImplemented; } throw new StreamCorruptedException("unknown singleton: " + which); }
0 0
(Domain) StopIterationException 1
              
// in src/org/python/indexer/ast/NNode.java
public boolean dispatch(NNode node) { // This node ends before the offset, so don't look inside it. if (offset > node.end) { return false; // don't traverse children, but do keep going } if (offset >= node.start && offset <= node.end) { deepest = node; return true; // visit kids } // this node starts after the offset, so we're done throw new NNodeVisitor.StopIterationException(); }
0 0
Explicit thrown (throw new...): 306/4163
Explicit thrown ratio: 7.4%
Builder thrown ratio: 81.7%
Variable thrown ratio: 11%
Checked Runtime Total
Domain 4 108 112
Lib 9 133 142
Total 13 241

Caught Exceptions Summary

A (Domain) exception is defined in the application. A (Lib) exception is defined in the JDK or in a library. An exception can be caught, and it happens that the catch block contains a throw (e.g. for wrapping a low-level exception). Hovering over a number triggers showing code snippets from the application code.

Type Exception Caught
(directly)
Caught
with Thrown
(Domain) PyException 483
            
// in src/com/ziclix/python/sql/Fetch.java
catch (PyException e) { throw e; }
// in src/com/ziclix/python/sql/Fetch.java
catch (PyException e) { throw e; }
// in src/com/ziclix/python/sql/Fetch.java
catch (PyException e) { throw e; }
// in src/com/ziclix/python/sql/Fetch.java
catch (PyException e) { throw e; }
// in src/com/ziclix/python/sql/PyStatement.java
catch (PyException e) { throw zxJDBC.makeException(zxJDBC.ProgrammingError, zxJDBC.getString("bindingValue")); }
// in src/com/ziclix/python/sql/PyCursor.java
catch (PyException e) { throw e; }
// in src/com/ziclix/python/sql/PyCursor.java
catch (PyException e) { throw e; }
// in src/com/xhaus/modjy/ModjyJServlet.java
catch (PyException ix) { throw new ServletException("Unable to import '" + MODJY_PYTHON_CLASSNAME + "': maybe you need to set the '" + PYTHON_HOME_PARAM + "' parameter?", ix); }
// in src/com/xhaus/modjy/ModjyJServlet.java
catch (PyException pyx) { throw new ServletException("Exception creating modjy servlet: " + pyx.toString(), pyx); }
// in src/org/python/compiler/Module.java
catch (PyException e) { if (!e.match(Py.SyntaxWarning)) { throw e; } }
// in src/org/python/antlr/ast/aliasDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/aliasDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/aliasDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/AttributeDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/AttributeDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/AttributeDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/UnaryOpDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/UnaryOpDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/UnaryOpDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/BreakDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/BreakDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/BreakDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/BoolOpDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/BoolOpDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/BoolOpDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ListCompDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/ListCompDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ListCompDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ContinueDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/ContinueDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ContinueDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/TupleDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/TupleDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/TupleDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/InteractiveDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/InteractiveDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/InteractiveDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/DeleteDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/DeleteDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/DeleteDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/IndexDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/IndexDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/IndexDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ModuleDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/ModuleDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ModuleDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/CallDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/CallDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/CallDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ReturnDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/ReturnDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ReturnDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ForDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/ForDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ForDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ExceptHandlerDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/ExceptHandlerDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ExceptHandlerDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/SubscriptDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/SubscriptDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/SubscriptDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/DictDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/DictDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/DictDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/LambdaDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/LambdaDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/LambdaDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/GlobalDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/GlobalDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/GlobalDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ListDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/ListDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ListDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/BinOpDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/BinOpDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/BinOpDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ClassDefDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/ClassDefDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ClassDefDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ExpressionDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/ExpressionDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ExpressionDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/SliceDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/SliceDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/SliceDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/NumDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/NumDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/NumDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ExprDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/ExprDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ExprDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/NameDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/NameDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/NameDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/TryFinallyDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/TryFinallyDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/TryFinallyDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/IfExpDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/IfExpDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/IfExpDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/AugAssignDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/AugAssignDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/AugAssignDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ImportDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/ImportDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ImportDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/IfDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/IfDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/IfDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/PassDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/PassDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/PassDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/FunctionDefDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/FunctionDefDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/FunctionDefDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/argumentsDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/argumentsDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/argumentsDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/WithDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/WithDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/WithDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ImportFromDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/ImportFromDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ImportFromDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/CompareDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/CompareDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/CompareDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ReprDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/ReprDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ReprDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/StrDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/StrDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/StrDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/YieldDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/YieldDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/YieldDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/EllipsisDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/EllipsisDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/EllipsisDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/RaiseDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/RaiseDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/RaiseDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/AssignDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/AssignDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/AssignDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/GeneratorExpDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/GeneratorExpDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/GeneratorExpDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/SuiteDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/SuiteDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/SuiteDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/AssertDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/AssertDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/AssertDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/TryExceptDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/TryExceptDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/TryExceptDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ExecDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/ExecDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ExecDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/WhileDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/WhileDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/WhileDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/keywordDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/keywordDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/keywordDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/comprehensionDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/comprehensionDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/comprehensionDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ExtSliceDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/ExtSliceDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ExtSliceDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/PrintDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/PrintDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/PrintDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/PowDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/PowDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/PowDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/LtEDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/LtEDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/LtEDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/ParamDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/ParamDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/ParamDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/EqDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/EqDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/EqDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/GtDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/GtDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/GtDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/IsDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/IsDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/IsDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/GtEDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/GtEDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/GtEDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/StoreDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/StoreDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/StoreDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/BitOrDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/BitOrDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/BitOrDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/RShiftDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/RShiftDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/RShiftDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/BitAndDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/BitAndDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/BitAndDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/NotInDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/NotInDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/NotInDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/LtDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/LtDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/LtDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/FloorDivDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/FloorDivDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/FloorDivDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/USubDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/USubDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/USubDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/InvertDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/InvertDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/InvertDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/AugLoadDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/AugLoadDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/AugLoadDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/AugStoreDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/AugStoreDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/AugStoreDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/LoadDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/LoadDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/LoadDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/IsNotDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/IsNotDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/IsNotDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/BitXorDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/BitXorDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/BitXorDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/NotEqDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/NotEqDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/NotEqDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/NotDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/NotDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/NotDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/AndDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/AndDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/AndDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/ModDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/ModDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/ModDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/AddDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/AddDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/AddDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/DelDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/DelDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/DelDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/DivDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/DivDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/DivDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/LShiftDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/LShiftDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/LShiftDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/InDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/InDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/InDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/MultDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/MultDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/MultDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/UAddDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/UAddDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/UAddDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/OrDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/OrDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/OrDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/SubDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/SubDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/SubDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/jsr223/PyScriptEngine.java
catch (PyException pye) { throw scriptException(pye); }
// in src/org/python/jsr223/PyScriptEngine.java
catch (PyException pye) { throw scriptException(pye); }
// in src/org/python/jsr223/PyScriptEngine.java
catch (PyException pye) { throw scriptException(pye); }
// in src/org/python/jsr223/PyScriptEngine.java
catch (PyException pye) { throw scriptException(pye); }
// in src/org/python/jsr223/PyScriptEngine.java
catch (PyException pye) { throw scriptException(pye); }
// in src/org/python/jsr223/PyScriptEngine.java
catch (PyException pye) { throw scriptException(pye); }
// in src/org/python/modules/zipimport/zipimporterDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/modules/zipimport/zipimporterDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/modules/zipimport/zipimporterDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/modules/zipimport/zipimporter.java
catch (PyException pye) { if (!pye.match(Py.TypeError)) { throw pye; } time = -1; date = -1; }
// in src/org/python/modules/struct.java
catch (PyException ex) { throw StructError("required argument is not an integer"); }
// in src/org/python/modules/binascii.java
catch (PyException e) { if (e.match(Py.AttributeError) || e.match(Py.ValueError)) throw Py.TypeError(errMsg); throw e; }
// in src/org/python/modules/_weakref/ReferenceTypeDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/modules/_weakref/ReferenceTypeDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/modules/_weakref/ReferenceTypeDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/modules/posix/PosixModule.java
catch (PyException pye) { if (!pye.match(Py.OSError)) { throw pye; } // ENOENT result = false; }
// in src/org/python/modules/posix/PosixModule.java
catch (PyException pye) { throw badFD(); }
// in src/org/python/modules/posix/PosixModule.java
catch (PyException pye) { if (!pye.match(Py.IOError)) { throw pye; } throw Py.OSError(Errno.EINVAL); }
// in src/org/python/modules/posix/PosixModule.java
catch (PyException pye) { throw Py.IOError(Errno.EBADF); }
// in src/org/python/modules/posix/PosixModule.java
catch (PyException pye) { throw badFD(); }
// in src/org/python/modules/posix/PosixModule.java
catch (PyException pye) { throw badFD(); }
// in src/org/python/modules/posix/PosixModule.java
catch (PyException pye) { throw badFD(); }
// in src/org/python/modules/posix/PosixModule.java
catch (PyException pye) { if (!pye.match(Py.KeyError)) { throw pye; } }
// in src/org/python/modules/thread/PyLocalDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/modules/thread/PyLocalDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/modules/thread/PyLocalDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/modules/_csv/PyWriter.java
catch (PyException ex) { quoted = true; }
// in src/org/python/modules/_csv/PyDialectDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/modules/_csv/PyDialectDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/modules/_csv/PyDialectDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/modules/random/PyRandomDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/modules/random/PyRandomDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/modules/random/PyRandomDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/modules/_collections/PyDequeDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/modules/_collections/PyDequeDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/modules/_collections/PyDequeDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/modules/_collections/PyDefaultDictDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/modules/_collections/PyDefaultDictDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/modules/_collections/PyDefaultDictDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/modules/_collections/PyDeque.java
catch (PyException pe) { if (pe.match(Py.KeyError)) { return null; } throw pe; }
// in src/org/python/modules/itertools.java
catch (PyException pyEx) { if (pyEx.match(Py.StopIteration)) { // store exception - will be used by PyIterator.next() stopException = pyEx; } else { throw pyEx; } }
// in src/org/python/modules/itertools.java
catch (PyException pyEx) { if (pyEx.match(Py.TypeError)) { throw Py.ValueError(msg); } else { throw pyEx; } }
// in src/org/python/modules/_functools/PyPartialDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/modules/_functools/PyPartialDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/modules/_functools/PyPartialDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/modules/time/Time.java
catch (PyException e) { // CPython's mktime raises OverflowErrors... yuck! e.type = Py.OverflowError; throw e; }
// in src/org/python/modules/PyTeeIterator.java
catch (PyException pyEx) { if (pyEx.match(Py.StopIteration)) { // store exception - will be used by PyIterator.next() stopException = pyEx; } else { throw pyEx; } }
// in src/org/python/core/PyFinalizableInstance.java
catch (PyException exc) { // Try to get the right method description. PyObject method = instclass.__del__; try { method = __findattr__("__del__"); } catch (PyException e) { // nothing we can do } Py.writeUnraisable(exc, method); }
// in src/org/python/core/PyFinalizableInstance.java
catch (PyException e) { // nothing we can do }
// in src/org/python/core/PyObject.java
catch (PyException pye) { if (!pye.match(Py.AttributeError)) { throw pye; } }
// in src/org/python/core/PyObject.java
catch (PyException exc) { if (exc.match(Py.AttributeError)) { return null; } throw exc; }
// in src/org/python/core/PyObject.java
catch (PyException e) { if (e.value.getJavaProxy() != null) { Object t = e.value.__tojava__(Throwable.class); if (t != null && t != Py.NoConversion) { throw (Throwable) t; } } else { ThreadState ts = Py.getThreadState(); if (ts.frame == null) { Py.maybeSystemExit(e); } if (Options.showPythonProxyExceptions) { Py.stderr.println( "Exception in Python proxy returning to Java:"); Py.printException(e); } } throw e; }
// in src/org/python/core/PyObject.java
catch (PyException exc) { if (exc.match(Py.KeyError)) { noAttributeError(name); } else { throw exc; } }
// in src/org/python/core/PyObject.java
catch (PyException pye) { if (pye.match(Py.AttributeError)) { throw Py.TypeError("an integer is required"); } throw pye; }
// in src/org/python/core/PyObject.java
catch (PyException pye) { if (pye.match(Py.AttributeError)) { throw Py.TypeError("an integer is required"); } throw pye; }
// in src/org/python/core/PyObject.java
catch (PyException pye) { if (pye.match(Py.AttributeError)) { throw Py.TypeError("a float is required"); } throw pye; }
// in src/org/python/core/PyStringMap.java
catch(PyException pye) { if (pye.match(Py.TypeError)) { throw Py.TypeError(String.format("cannot convert dictionary update sequence " + "element #%d to a sequence", i)); } throw pye; }
// in src/org/python/core/PyList.java
catch (PyException pye) { if (!pye.match(Py.TypeError)) { throw pye; } return null; }
// in src/org/python/core/PyFloatDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyFloatDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyFloatDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyClass.java
catch (PyException pye) { noAttributeError(name); }
// in src/org/python/core/PyArrayDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyArrayDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyArrayDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/FunctionThread.java
catch (PyException exc) { if (exc.match(Py.SystemExit) || exc.match(_systemrestart.SystemRestart)) { return; } Py.stderr.println("Unhandled exception in thread started by " + func); Py.printException(exc); }
// in src/org/python/core/PyEnumerateDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyEnumerateDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyEnumerateDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PySystemState.java
catch (PyException pye) { // KeyError if (ret == null) { throw Py.AttributeError(name); } }
// in src/org/python/core/PySystemState.java
catch (PyException exc) { if (!exc.match(Py.SystemExit)) { Py.println(stderr, Py.newString("Error in sys.exitfunc:")); } Py.printException(exc); }
// in src/org/python/core/PySet.java
catch (PyException e) { PyObject frozen = asFrozen(e, o); b = _set.remove(frozen); }
// in src/org/python/core/PySet.java
catch (PyException e) { PyObject frozen = asFrozen(e, o); _set.remove(frozen); }
// in src/org/python/core/PyDictionary.java
catch(PyException pye) { if (pye.match(Py.TypeError)) { throw Py.TypeError(String.format("cannot convert dictionary update sequence " + "element #%d to a sequence", i)); } throw pye; }
// in src/org/python/core/PyUnicodeDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyUnicodeDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyUnicodeDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyFastSequenceIter.java
catch (PyException pye) { if (pye.match(Py.StopIteration)) { seq = null; return null; } throw pye; }
// in src/org/python/core/PyComplex.java
catch (PyException pye) { if (!pye.match(Py.AttributeError)) { // __complex__ not supported throw pye; } // otherwise try other means }
// in src/org/python/core/PyComplex.java
catch (PyException pye) { if (pye.match(Py.AttributeError)) { // __float__ not supported throw Py.TypeError("complex() argument must be a string or a number"); } throw pye; }
// in src/org/python/core/PyComplex.java
catch (PyException pye) { if (pye.match(Py.AttributeError)) { // __float__ not supported throw Py.TypeError("complex() argument must be a string or a number"); } throw pye; }
// in src/org/python/core/PyInstance.java
catch (PyException exc) { if (exc.match(Py.KeyError)) throw Py.AttributeError("class " + instclass.__name__ + " has no attribute '" + name + "'"); }
// in src/org/python/core/PyInstance.java
catch (PyException exc) { }
// in src/org/python/core/PyInstance.java
catch (PyException exc) { }
// in src/org/python/core/PyInstance.java
catch (PyException e) { if (e.match(Py.IndexError)) return null; if (e.match(Py.KeyError)) return null; throw e; }
// in src/org/python/core/PyInstance.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyInstance.java
catch (PyException pye) { if (!pye.match(Py.AttributeError)) { throw pye; } throw Py.TypeError("object cannot be interpreted as an index"); }
// in src/org/python/core/ContextGuard.java
catch(PyException e) { if (e.equals(exception)) { return false; } else { throw e; } }
// in src/org/python/core/PyFrame.java
catch (PyException pye) { if (pye.match(Py.KeyError)) { throw Py.NameError(String.format(NAME_ERROR_MSG, index)); } throw pye; }
// in src/org/python/core/PyFrame.java
catch (PyException pye) { if (pye.match(Py.KeyError)) { throw Py.NameError(String.format(GLOBAL_NAME_ERROR_MSG, index)); } throw pye; }
// in src/org/python/core/PyLongDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyLongDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyLongDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/AstList.java
catch (PyException pye) { if (!pye.match(Py.TypeError)) { throw pye; } return null; }
// in src/org/python/core/AstList.java
catch (PyException pye) { if (pye.match(Py.TypeError)) { throw Py.TypeError("can only assign an iterable"); } throw pye; }
// in src/org/python/core/PyFloat.java
catch (PyException e) { if (e.match(Py.AttributeError)) { // Translate AttributeError to TypeError // XXX: We are using the same message as CPython, even if // it is not strictly correct (instances of types // that implement the __float__ method are also // valid arguments) throw Py.TypeError("float() argument must be a string or a number"); } throw e; }
// in src/org/python/core/PySlice.java
catch (PyException pye) { if (!pye.match(Py.TypeError)) { throw pye; } }
// in src/org/python/core/PyIntegerDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyIntegerDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyIntegerDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyBaseExceptionDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyBaseExceptionDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyBaseExceptionDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/io/IOBase.java
catch (PyException pye) { if (!pye.match(Py.IOError)) { throw pye; } // If flush() fails, just give up }
// in src/org/python/core/io/BufferedIOMixin.java
catch (PyException pye) { if (!pye.match(Py.IOError)) { throw pye; } // If flush() fails, just give up }
// in src/org/python/core/PySuperDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PySuperDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PySuperDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/StdoutWrapper.java
catch (PyException pye) { // ok }
// in src/org/python/core/StdoutWrapper.java
catch (PyException pye) { // ok }
// in src/org/python/core/PyTraceback.java
catch (PyException pye) { return null; }
// in src/org/python/core/PyTraceback.java
catch (PyException pye) { // Proceed to closing the file }
// in src/org/python/core/PyTraceback.java
catch (PyException pye) { // Continue, we may have the line }
// in src/org/python/core/PyArray.java
catch (PyException e) { delegate.setSize(afterLast); throw new PyException(e.type, e.value); }
// in src/org/python/core/PyArray.java
catch(PyException e) { // trap any exception - any error invalidates the whole list delegate.setSize(size); // re-throw throw new PyException(e.type, e.value); }
// in src/org/python/core/PyModuleDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyModuleDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyModuleDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/__builtin__.java
catch (PyException pye) { if (!pye.match(Py.AttributeError)) { throw pye; } attributeError = pye; }
// in src/org/python/core/__builtin__.java
catch (PyException pye) { // swallow }
// in src/org/python/core/__builtin__.java
catch (PyException pye) { return handleRangeLongs(start, stop, step); }
// in src/org/python/core/__builtin__.java
catch (PyException pye) { return -1; }
// in src/org/python/core/__builtin__.java
catch (PyException e) { if (e.match(Py.AttributeError)) { throw Py.TypeError("vars() argument must have __dict__ attribute"); } throw e; }
// in src/org/python/core/__builtin__.java
catch (PyException e) { if (e.match(Py.StopIteration)) { return ret; } throw e; }
// in src/org/python/core/PyTypeDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyTypeDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyTypeDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PySetDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PySetDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PySetDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyType.java
catch (PyException t) { for (Iterator<Object> it = savedSubMros.iterator(); it.hasNext();) { PyType subtype = (PyType)it.next(); PyObject[] subtypeSavedMro = (PyObject[])it.next(); subtype.mro = subtypeSavedMro; } bases = savedBases; base = savedBase; mro = savedMro; throw t; }
// in src/org/python/core/PythonTraceFunction.java
catch(PyException exc) { frame.tracefunc = null; ts.tracefunc = null; ts.profilefunc = null; throw exc; }
// in src/org/python/core/PyPropertyDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyPropertyDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyPropertyDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/Py.java
catch (PyException e) { if (e.match(ImportError)) { return null; } throw e; }
// in src/org/python/core/Py.java
catch (PyException e) { Py.getSystemState().callExitFunc(); if (e.match(Py.SystemExit)) { return; } throw e; }
// in src/org/python/core/Py.java
catch (PyException exc2) { exc2.normalize(); flushLine(); stderr.println("Error in sys.excepthook:"); displayException(exc2.type, exc2.value, exc2.traceback, file); stderr.println(); stderr.println("Original exception was:"); displayException(exc.type, exc.value, exc.traceback, file); }
// in src/org/python/core/Py.java
catch (PyException pye) { if (!pye.match(TypeError)) { throw pye; } pye.value = Py.newString(String.format("Error when calling the metaclass bases\n " + "%s", pye.value.__str__().toString())); throw pye; }
// in src/org/python/core/Py.java
catch (PyException exc) { if (exc.match(Py.TypeError)) { throw Py.TypeError(message); } throw exc; }
// in src/org/python/core/Py.java
catch (PyException pye) { // ok }
// in src/org/python/core/PySequenceIter.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) { seq = null; return null; } throw exc; }
// in src/org/python/core/PyFileDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyFileDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyFileDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyCallIter.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) { callable = null; stopException = exc; return null; } throw exc; }
// in src/org/python/core/PyListDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyListDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyListDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyFrozenSetDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyFrozenSetDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyFrozenSetDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyDictionaryDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyDictionaryDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyDictionaryDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyBytecode.java
catch (PyException pye) { if (pye.match(Py.AttributeError)) { throw Py.ImportError(String.format("cannot import name %.230s", name)); } else { throw pye; } }
// in src/org/python/core/PyBytecode.java
catch (PyException pye) { if (!pye.match(Py.StopIteration)) { throw pye; } }
// in src/org/python/core/PyStringDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyStringDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyStringDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/codecs.java
catch (PyException exc) { if (exc.type != Py.ImportError) { throw exc; } }
// in src/org/python/core/codecs.java
catch (PyException ex) { if (ex.match(Py.LookupError)) { // If we couldn't find an encoding, see if we have a builtin if (encoding.equals("utf-8")) { return wrapDecodeResult(PyUnicode_DecodeUTF8(v.toString(), errors)); } else if(encoding.equals("utf-7")) { return wrapDecodeResult(PyUnicode_DecodeUTF7(v.toString(), errors)); } else if(encoding.equals("latin-1")) { return wrapDecodeResult(PyUnicode_DecodeLatin1(v.toString(), v.__len__(), errors)); } } throw ex; }
// in src/org/python/core/codecs.java
catch (PyException ex) { if (ex.match(Py.LookupError)) { // If we couldn't find an encoding, see if we have a builtin if (encoding.equals("utf-8")) { return PyUnicode_EncodeUTF8(v.toString(), errors); } else if(encoding.equals("utf-7")) { return codecs.PyUnicode_EncodeUTF7(v.toString(), false, false, errors); } } throw ex; }
// in src/org/python/core/PyException.java
catch (PyException pye) { // This function must not fail, so print the error here Py.writeUnraisable(pye, type); return false; }
// in src/org/python/core/BaseSet.java
catch (PyException pye) { PyFrozenSet frozen = asFrozen(pye, other); return _set.contains(frozen); }
// in src/org/python/core/PyInteger.java
catch (PyException pye) { if (pye.match(Py.OverflowError)) { return ((PyString) x).atol(base); } throw pye; }
// in src/org/python/core/PyInteger.java
catch (PyException pye) { if (!pye.match(Py.AttributeError)) { throw pye; } throw Py.TypeError("int() argument must be a string or a number"); }
// in src/org/python/core/PyObjectDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyObjectDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyObjectDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyComplexDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyComplexDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyComplexDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyLong.java
catch (PyException pye) { if (!pye.match(Py.AttributeError)) { throw pye; } throw Py.TypeError(String.format("long() argument must be a string or a number, " + "not '%.200s'", x.getType().fastGetName())); }
// in src/org/python/core/PyLong.java
catch (PyException e) { return Py.NoConversion; }
// in src/org/python/core/PyClassMethodDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyClassMethodDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyClassMethodDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyMethod.java
catch (PyException pye) { // continue }
// in src/org/python/core/PyTupleDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyTupleDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyTupleDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyString.java
catch (PyException e) { if (e.match(Py.OverflowError)) { return atol(10); } throw e; }
// in src/org/python/core/PyString.java
catch (PyException e) { // XXX: Swallow customs AttributeError throws from __float__ methods // No better alternative for the moment if (e.match(Py.AttributeError)) { throw Py.TypeError("int argument required"); } throw e; }
// in src/org/python/core/PyString.java
catch (PyException pye) { throw !pye.match(Py.TypeError) ? pye : Py.TypeError("float argument required"); }
// in src/org/python/core/PyString.java
catch (PyException e){ if (e.match(Py.AttributeError)) { throw Py.TypeError("%c requires int or char"); } throw e; }
// in src/org/python/core/imp.java
catch (PyException pye) { // another thread may have deleted it if (!pye.match(Py.KeyError)) { throw pye; } }
// in src/org/python/core/imp.java
catch (PyException e) { if (!e.match(Py.ImportError)) { throw e; } }
// in src/org/python/core/ClasspathPyImporterDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/ClasspathPyImporterDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/ClasspathPyImporterDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyGenerator.java
catch (PyException e) { if (!(e.type == Py.StopIteration || e.type == Py.GeneratorExit)) { throw e; } }
// in src/org/python/core/PyGenerator.java
catch (PyException pye) { // PEP 342 specifies that if an exception is raised by close, // we output to stderr and then forget about it; String className = PyException.exceptionClassName(pye.type); int lastDot = className.lastIndexOf('.'); if (lastDot != -1) { className = className.substring(lastDot + 1); } String msg = String.format("Exception %s: %s in %s", className, pye.value.__repr__(), __repr__()); Py.println(Py.getSystemState().stderr, Py.newString(msg)); }
// in src/org/python/core/PyGenerator.java
catch (PyException pye) { if (!(pye.type == Py.StopIteration || pye.type == Py.GeneratorExit)) { gi_frame = null; throw pye; } else { stopException = pye; gi_frame = null; return null; } }
// in src/org/python/core/Deriveds.java
catch (PyException pye) { if (!pye.match(Py.AttributeError)) { throw pye; } else { // saved to avoid swallowing custom AttributeErrors, and pass through to // __getattr__ firstAttributeError = pye; } }
// in src/org/python/util/PyFilter.java
catch (PyException e) { throw new ServletException(e); }
// in src/org/python/util/JycompileAntTask.java
catch (PyException pye) { pye.printStackTrace(); throw new BuildException("Compile failed; see the compiler error output for details."); }
// in src/org/python/util/InteractiveInterpreter.java
catch (PyException exc) { if (exc.match(Py.SyntaxError)) { // Case 1 showexception(exc); return false; } else if (exc.match(Py.ValueError) || exc.match(Py.OverflowError)) { // Should not print the stack trace, just the error. showexception(exc); return false; } else { throw exc; } }
// in src/org/python/util/InteractiveInterpreter.java
catch (PyException exc) { if (exc.match(Py.SystemExit)) throw exc; showexception(exc); }
// in src/org/python/util/InteractiveConsole.java
catch(PyException exc) { if(!exc.match(Py.EOFError)) throw exc; write("\n"); break; }
// in src/org/python/util/PyServlet.java
catch (PyException e) { throw new ServletException(e); }
// in src/org/python/util/PyServlet.java
catch (PyException e) { throw new ServletException(e); }
// in src/org/python/util/jython.java
catch (PyException pye) { if (!pye.match(Py.ImportError)) { System.err.println("error importing site"); Py.printException(pye); System.exit(-1); } }
// in src/org/python/util/jython.java
catch (PyException pye) { // continue }
// in src/org/python/util/PythonInterpreter.java
catch (PyException pye) { // fall through }
// in src/org/python/util/PythonInterpreter.java
catch (PyException pye) { // fall through }
478
            
// in src/com/ziclix/python/sql/Fetch.java
catch (PyException e) { throw e; }
// in src/com/ziclix/python/sql/Fetch.java
catch (PyException e) { throw e; }
// in src/com/ziclix/python/sql/Fetch.java
catch (PyException e) { throw e; }
// in src/com/ziclix/python/sql/Fetch.java
catch (PyException e) { throw e; }
// in src/com/ziclix/python/sql/PyStatement.java
catch (PyException e) { throw zxJDBC.makeException(zxJDBC.ProgrammingError, zxJDBC.getString("bindingValue")); }
// in src/com/ziclix/python/sql/PyCursor.java
catch (PyException e) { throw e; }
// in src/com/ziclix/python/sql/PyCursor.java
catch (PyException e) { throw e; }
// in src/com/xhaus/modjy/ModjyJServlet.java
catch (PyException ix) { throw new ServletException("Unable to import '" + MODJY_PYTHON_CLASSNAME + "': maybe you need to set the '" + PYTHON_HOME_PARAM + "' parameter?", ix); }
// in src/com/xhaus/modjy/ModjyJServlet.java
catch (PyException pyx) { throw new ServletException("Exception creating modjy servlet: " + pyx.toString(), pyx); }
// in src/org/python/compiler/Module.java
catch (PyException e) { if (!e.match(Py.SyntaxWarning)) { throw e; } }
// in src/org/python/antlr/ast/aliasDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/aliasDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/aliasDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/AttributeDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/AttributeDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/AttributeDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/UnaryOpDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/UnaryOpDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/UnaryOpDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/BreakDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/BreakDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/BreakDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/BoolOpDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/BoolOpDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/BoolOpDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ListCompDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/ListCompDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ListCompDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ContinueDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/ContinueDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ContinueDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/TupleDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/TupleDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/TupleDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/InteractiveDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/InteractiveDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/InteractiveDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/DeleteDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/DeleteDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/DeleteDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/IndexDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/IndexDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/IndexDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ModuleDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/ModuleDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ModuleDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/CallDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/CallDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/CallDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ReturnDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/ReturnDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ReturnDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ForDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/ForDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ForDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ExceptHandlerDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/ExceptHandlerDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ExceptHandlerDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/SubscriptDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/SubscriptDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/SubscriptDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/DictDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/DictDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/DictDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/LambdaDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/LambdaDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/LambdaDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/GlobalDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/GlobalDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/GlobalDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ListDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/ListDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ListDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/BinOpDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/BinOpDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/BinOpDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ClassDefDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/ClassDefDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ClassDefDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ExpressionDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/ExpressionDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ExpressionDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/SliceDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/SliceDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/SliceDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/NumDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/NumDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/NumDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ExprDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/ExprDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ExprDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/NameDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/NameDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/NameDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/TryFinallyDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/TryFinallyDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/TryFinallyDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/IfExpDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/IfExpDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/IfExpDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/AugAssignDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/AugAssignDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/AugAssignDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ImportDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/ImportDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ImportDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/IfDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/IfDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/IfDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/PassDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/PassDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/PassDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/FunctionDefDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/FunctionDefDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/FunctionDefDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/argumentsDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/argumentsDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/argumentsDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/WithDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/WithDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/WithDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ImportFromDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/ImportFromDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ImportFromDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/CompareDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/CompareDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/CompareDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ReprDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/ReprDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ReprDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/StrDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/StrDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/StrDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/YieldDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/YieldDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/YieldDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/EllipsisDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/EllipsisDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/EllipsisDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/RaiseDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/RaiseDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/RaiseDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/AssignDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/AssignDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/AssignDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/GeneratorExpDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/GeneratorExpDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/GeneratorExpDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/SuiteDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/SuiteDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/SuiteDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/AssertDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/AssertDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/AssertDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/TryExceptDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/TryExceptDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/TryExceptDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ExecDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/ExecDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ExecDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/WhileDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/WhileDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/WhileDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/keywordDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/keywordDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/keywordDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/comprehensionDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/comprehensionDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/comprehensionDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ExtSliceDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/ExtSliceDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ExtSliceDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/PrintDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/PrintDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/PrintDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/PowDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/PowDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/PowDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/LtEDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/LtEDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/LtEDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/ParamDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/ParamDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/ParamDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/EqDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/EqDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/EqDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/GtDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/GtDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/GtDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/IsDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/IsDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/IsDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/GtEDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/GtEDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/GtEDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/StoreDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/StoreDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/StoreDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/BitOrDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/BitOrDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/BitOrDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/RShiftDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/RShiftDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/RShiftDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/BitAndDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/BitAndDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/BitAndDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/NotInDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/NotInDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/NotInDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/LtDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/LtDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/LtDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/FloorDivDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/FloorDivDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/FloorDivDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/USubDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/USubDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/USubDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/InvertDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/InvertDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/InvertDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/AugLoadDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/AugLoadDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/AugLoadDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/AugStoreDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/AugStoreDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/AugStoreDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/LoadDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/LoadDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/LoadDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/IsNotDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/IsNotDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/IsNotDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/BitXorDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/BitXorDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/BitXorDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/NotEqDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/NotEqDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/NotEqDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/NotDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/NotDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/NotDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/AndDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/AndDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/AndDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/ModDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/ModDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/ModDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/AddDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/AddDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/AddDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/DelDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/DelDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/DelDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/DivDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/DivDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/DivDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/LShiftDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/LShiftDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/LShiftDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/InDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/InDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/InDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/MultDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/MultDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/MultDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/UAddDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/UAddDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/UAddDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/OrDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/OrDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/OrDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/SubDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/SubDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/SubDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/jsr223/PyScriptEngine.java
catch (PyException pye) { throw scriptException(pye); }
// in src/org/python/jsr223/PyScriptEngine.java
catch (PyException pye) { throw scriptException(pye); }
// in src/org/python/jsr223/PyScriptEngine.java
catch (PyException pye) { throw scriptException(pye); }
// in src/org/python/jsr223/PyScriptEngine.java
catch (PyException pye) { throw scriptException(pye); }
// in src/org/python/jsr223/PyScriptEngine.java
catch (PyException pye) { throw scriptException(pye); }
// in src/org/python/jsr223/PyScriptEngine.java
catch (PyException pye) { throw scriptException(pye); }
// in src/org/python/modules/zipimport/zipimporterDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/modules/zipimport/zipimporterDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/modules/zipimport/zipimporterDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/modules/zipimport/zipimporter.java
catch (PyException pye) { if (!pye.match(Py.TypeError)) { throw pye; } time = -1; date = -1; }
// in src/org/python/modules/struct.java
catch (PyException ex) { throw StructError("required argument is not an integer"); }
// in src/org/python/modules/binascii.java
catch (PyException e) { if (e.match(Py.AttributeError) || e.match(Py.ValueError)) throw Py.TypeError(errMsg); throw e; }
// in src/org/python/modules/_weakref/ReferenceTypeDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/modules/_weakref/ReferenceTypeDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/modules/_weakref/ReferenceTypeDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/modules/posix/PosixModule.java
catch (PyException pye) { if (!pye.match(Py.OSError)) { throw pye; } // ENOENT result = false; }
// in src/org/python/modules/posix/PosixModule.java
catch (PyException pye) { throw badFD(); }
// in src/org/python/modules/posix/PosixModule.java
catch (PyException pye) { if (!pye.match(Py.IOError)) { throw pye; } throw Py.OSError(Errno.EINVAL); }
// in src/org/python/modules/posix/PosixModule.java
catch (PyException pye) { throw Py.IOError(Errno.EBADF); }
// in src/org/python/modules/posix/PosixModule.java
catch (PyException pye) { throw badFD(); }
// in src/org/python/modules/posix/PosixModule.java
catch (PyException pye) { throw badFD(); }
// in src/org/python/modules/posix/PosixModule.java
catch (PyException pye) { throw badFD(); }
// in src/org/python/modules/posix/PosixModule.java
catch (PyException pye) { if (!pye.match(Py.KeyError)) { throw pye; } }
// in src/org/python/modules/thread/PyLocalDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/modules/thread/PyLocalDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/modules/thread/PyLocalDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/modules/_csv/PyDialectDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/modules/_csv/PyDialectDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/modules/_csv/PyDialectDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/modules/random/PyRandomDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/modules/random/PyRandomDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/modules/random/PyRandomDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/modules/_collections/PyDequeDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/modules/_collections/PyDequeDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/modules/_collections/PyDequeDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/modules/_collections/PyDefaultDictDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/modules/_collections/PyDefaultDictDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/modules/_collections/PyDefaultDictDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/modules/_collections/PyDeque.java
catch (PyException pe) { if (pe.match(Py.KeyError)) { return null; } throw pe; }
// in src/org/python/modules/itertools.java
catch (PyException pyEx) { if (pyEx.match(Py.StopIteration)) { // store exception - will be used by PyIterator.next() stopException = pyEx; } else { throw pyEx; } }
// in src/org/python/modules/itertools.java
catch (PyException pyEx) { if (pyEx.match(Py.TypeError)) { throw Py.ValueError(msg); } else { throw pyEx; } }
// in src/org/python/modules/_functools/PyPartialDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/modules/_functools/PyPartialDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/modules/_functools/PyPartialDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/modules/time/Time.java
catch (PyException e) { // CPython's mktime raises OverflowErrors... yuck! e.type = Py.OverflowError; throw e; }
// in src/org/python/modules/PyTeeIterator.java
catch (PyException pyEx) { if (pyEx.match(Py.StopIteration)) { // store exception - will be used by PyIterator.next() stopException = pyEx; } else { throw pyEx; } }
// in src/org/python/core/PyObject.java
catch (PyException pye) { if (!pye.match(Py.AttributeError)) { throw pye; } }
// in src/org/python/core/PyObject.java
catch (PyException exc) { if (exc.match(Py.AttributeError)) { return null; } throw exc; }
// in src/org/python/core/PyObject.java
catch (PyException e) { if (e.value.getJavaProxy() != null) { Object t = e.value.__tojava__(Throwable.class); if (t != null && t != Py.NoConversion) { throw (Throwable) t; } } else { ThreadState ts = Py.getThreadState(); if (ts.frame == null) { Py.maybeSystemExit(e); } if (Options.showPythonProxyExceptions) { Py.stderr.println( "Exception in Python proxy returning to Java:"); Py.printException(e); } } throw e; }
// in src/org/python/core/PyObject.java
catch (PyException exc) { if (exc.match(Py.KeyError)) { noAttributeError(name); } else { throw exc; } }
// in src/org/python/core/PyObject.java
catch (PyException pye) { if (pye.match(Py.AttributeError)) { throw Py.TypeError("an integer is required"); } throw pye; }
// in src/org/python/core/PyObject.java
catch (PyException pye) { if (pye.match(Py.AttributeError)) { throw Py.TypeError("an integer is required"); } throw pye; }
// in src/org/python/core/PyObject.java
catch (PyException pye) { if (pye.match(Py.AttributeError)) { throw Py.TypeError("a float is required"); } throw pye; }
// in src/org/python/core/PyStringMap.java
catch(PyException pye) { if (pye.match(Py.TypeError)) { throw Py.TypeError(String.format("cannot convert dictionary update sequence " + "element #%d to a sequence", i)); } throw pye; }
// in src/org/python/core/PyList.java
catch (PyException pye) { if (!pye.match(Py.TypeError)) { throw pye; } return null; }
// in src/org/python/core/PyFloatDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyFloatDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyFloatDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyArrayDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyArrayDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyArrayDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyEnumerateDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyEnumerateDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyEnumerateDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PySystemState.java
catch (PyException pye) { // KeyError if (ret == null) { throw Py.AttributeError(name); } }
// in src/org/python/core/PyDictionary.java
catch(PyException pye) { if (pye.match(Py.TypeError)) { throw Py.TypeError(String.format("cannot convert dictionary update sequence " + "element #%d to a sequence", i)); } throw pye; }
// in src/org/python/core/PyUnicodeDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyUnicodeDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyUnicodeDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyFastSequenceIter.java
catch (PyException pye) { if (pye.match(Py.StopIteration)) { seq = null; return null; } throw pye; }
// in src/org/python/core/PyComplex.java
catch (PyException pye) { if (!pye.match(Py.AttributeError)) { // __complex__ not supported throw pye; } // otherwise try other means }
// in src/org/python/core/PyComplex.java
catch (PyException pye) { if (pye.match(Py.AttributeError)) { // __float__ not supported throw Py.TypeError("complex() argument must be a string or a number"); } throw pye; }
// in src/org/python/core/PyComplex.java
catch (PyException pye) { if (pye.match(Py.AttributeError)) { // __float__ not supported throw Py.TypeError("complex() argument must be a string or a number"); } throw pye; }
// in src/org/python/core/PyInstance.java
catch (PyException exc) { if (exc.match(Py.KeyError)) throw Py.AttributeError("class " + instclass.__name__ + " has no attribute '" + name + "'"); }
// in src/org/python/core/PyInstance.java
catch (PyException e) { if (e.match(Py.IndexError)) return null; if (e.match(Py.KeyError)) return null; throw e; }
// in src/org/python/core/PyInstance.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyInstance.java
catch (PyException pye) { if (!pye.match(Py.AttributeError)) { throw pye; } throw Py.TypeError("object cannot be interpreted as an index"); }
// in src/org/python/core/ContextGuard.java
catch(PyException e) { if (e.equals(exception)) { return false; } else { throw e; } }
// in src/org/python/core/PyFrame.java
catch (PyException pye) { if (pye.match(Py.KeyError)) { throw Py.NameError(String.format(NAME_ERROR_MSG, index)); } throw pye; }
// in src/org/python/core/PyFrame.java
catch (PyException pye) { if (pye.match(Py.KeyError)) { throw Py.NameError(String.format(GLOBAL_NAME_ERROR_MSG, index)); } throw pye; }
// in src/org/python/core/PyLongDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyLongDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyLongDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/AstList.java
catch (PyException pye) { if (!pye.match(Py.TypeError)) { throw pye; } return null; }
// in src/org/python/core/AstList.java
catch (PyException pye) { if (pye.match(Py.TypeError)) { throw Py.TypeError("can only assign an iterable"); } throw pye; }
// in src/org/python/core/PyFloat.java
catch (PyException e) { if (e.match(Py.AttributeError)) { // Translate AttributeError to TypeError // XXX: We are using the same message as CPython, even if // it is not strictly correct (instances of types // that implement the __float__ method are also // valid arguments) throw Py.TypeError("float() argument must be a string or a number"); } throw e; }
// in src/org/python/core/PySlice.java
catch (PyException pye) { if (!pye.match(Py.TypeError)) { throw pye; } }
// in src/org/python/core/PyIntegerDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyIntegerDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyIntegerDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyBaseExceptionDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyBaseExceptionDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyBaseExceptionDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/io/IOBase.java
catch (PyException pye) { if (!pye.match(Py.IOError)) { throw pye; } // If flush() fails, just give up }
// in src/org/python/core/io/BufferedIOMixin.java
catch (PyException pye) { if (!pye.match(Py.IOError)) { throw pye; } // If flush() fails, just give up }
// in src/org/python/core/PySuperDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PySuperDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PySuperDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyArray.java
catch (PyException e) { delegate.setSize(afterLast); throw new PyException(e.type, e.value); }
// in src/org/python/core/PyArray.java
catch(PyException e) { // trap any exception - any error invalidates the whole list delegate.setSize(size); // re-throw throw new PyException(e.type, e.value); }
// in src/org/python/core/PyModuleDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyModuleDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyModuleDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/__builtin__.java
catch (PyException pye) { if (!pye.match(Py.AttributeError)) { throw pye; } attributeError = pye; }
// in src/org/python/core/__builtin__.java
catch (PyException e) { if (e.match(Py.AttributeError)) { throw Py.TypeError("vars() argument must have __dict__ attribute"); } throw e; }
// in src/org/python/core/__builtin__.java
catch (PyException e) { if (e.match(Py.StopIteration)) { return ret; } throw e; }
// in src/org/python/core/PyTypeDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyTypeDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyTypeDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PySetDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PySetDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PySetDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyType.java
catch (PyException t) { for (Iterator<Object> it = savedSubMros.iterator(); it.hasNext();) { PyType subtype = (PyType)it.next(); PyObject[] subtypeSavedMro = (PyObject[])it.next(); subtype.mro = subtypeSavedMro; } bases = savedBases; base = savedBase; mro = savedMro; throw t; }
// in src/org/python/core/PythonTraceFunction.java
catch(PyException exc) { frame.tracefunc = null; ts.tracefunc = null; ts.profilefunc = null; throw exc; }
// in src/org/python/core/PyPropertyDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyPropertyDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyPropertyDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/Py.java
catch (PyException e) { if (e.match(ImportError)) { return null; } throw e; }
// in src/org/python/core/Py.java
catch (PyException e) { Py.getSystemState().callExitFunc(); if (e.match(Py.SystemExit)) { return; } throw e; }
// in src/org/python/core/Py.java
catch (PyException pye) { if (!pye.match(TypeError)) { throw pye; } pye.value = Py.newString(String.format("Error when calling the metaclass bases\n " + "%s", pye.value.__str__().toString())); throw pye; }
// in src/org/python/core/Py.java
catch (PyException exc) { if (exc.match(Py.TypeError)) { throw Py.TypeError(message); } throw exc; }
// in src/org/python/core/PySequenceIter.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) { seq = null; return null; } throw exc; }
// in src/org/python/core/PyFileDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyFileDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyFileDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyCallIter.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) { callable = null; stopException = exc; return null; } throw exc; }
// in src/org/python/core/PyListDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyListDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyListDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyFrozenSetDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyFrozenSetDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyFrozenSetDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyDictionaryDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyDictionaryDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyDictionaryDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyBytecode.java
catch (PyException pye) { if (pye.match(Py.AttributeError)) { throw Py.ImportError(String.format("cannot import name %.230s", name)); } else { throw pye; } }
// in src/org/python/core/PyBytecode.java
catch (PyException pye) { if (!pye.match(Py.StopIteration)) { throw pye; } }
// in src/org/python/core/PyStringDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyStringDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyStringDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/codecs.java
catch (PyException exc) { if (exc.type != Py.ImportError) { throw exc; } }
// in src/org/python/core/codecs.java
catch (PyException ex) { if (ex.match(Py.LookupError)) { // If we couldn't find an encoding, see if we have a builtin if (encoding.equals("utf-8")) { return wrapDecodeResult(PyUnicode_DecodeUTF8(v.toString(), errors)); } else if(encoding.equals("utf-7")) { return wrapDecodeResult(PyUnicode_DecodeUTF7(v.toString(), errors)); } else if(encoding.equals("latin-1")) { return wrapDecodeResult(PyUnicode_DecodeLatin1(v.toString(), v.__len__(), errors)); } } throw ex; }
// in src/org/python/core/codecs.java
catch (PyException ex) { if (ex.match(Py.LookupError)) { // If we couldn't find an encoding, see if we have a builtin if (encoding.equals("utf-8")) { return PyUnicode_EncodeUTF8(v.toString(), errors); } else if(encoding.equals("utf-7")) { return codecs.PyUnicode_EncodeUTF7(v.toString(), false, false, errors); } } throw ex; }
// in src/org/python/core/PyInteger.java
catch (PyException pye) { if (pye.match(Py.OverflowError)) { return ((PyString) x).atol(base); } throw pye; }
// in src/org/python/core/PyInteger.java
catch (PyException pye) { if (!pye.match(Py.AttributeError)) { throw pye; } throw Py.TypeError("int() argument must be a string or a number"); }
// in src/org/python/core/PyObjectDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyObjectDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyObjectDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyComplexDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyComplexDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyComplexDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyLong.java
catch (PyException pye) { if (!pye.match(Py.AttributeError)) { throw pye; } throw Py.TypeError(String.format("long() argument must be a string or a number, " + "not '%.200s'", x.getType().fastGetName())); }
// in src/org/python/core/PyClassMethodDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyClassMethodDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyClassMethodDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyTupleDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyTupleDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyTupleDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyString.java
catch (PyException e) { if (e.match(Py.OverflowError)) { return atol(10); } throw e; }
// in src/org/python/core/PyString.java
catch (PyException e) { // XXX: Swallow customs AttributeError throws from __float__ methods // No better alternative for the moment if (e.match(Py.AttributeError)) { throw Py.TypeError("int argument required"); } throw e; }
// in src/org/python/core/PyString.java
catch (PyException pye) { throw !pye.match(Py.TypeError) ? pye : Py.TypeError("float argument required"); }
// in src/org/python/core/PyString.java
catch (PyException e){ if (e.match(Py.AttributeError)) { throw Py.TypeError("%c requires int or char"); } throw e; }
// in src/org/python/core/imp.java
catch (PyException pye) { // another thread may have deleted it if (!pye.match(Py.KeyError)) { throw pye; } }
// in src/org/python/core/imp.java
catch (PyException e) { if (!e.match(Py.ImportError)) { throw e; } }
// in src/org/python/core/ClasspathPyImporterDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/ClasspathPyImporterDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/ClasspathPyImporterDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyGenerator.java
catch (PyException e) { if (!(e.type == Py.StopIteration || e.type == Py.GeneratorExit)) { throw e; } }
// in src/org/python/core/PyGenerator.java
catch (PyException pye) { if (!(pye.type == Py.StopIteration || pye.type == Py.GeneratorExit)) { gi_frame = null; throw pye; } else { stopException = pye; gi_frame = null; return null; } }
// in src/org/python/core/Deriveds.java
catch (PyException pye) { if (!pye.match(Py.AttributeError)) { throw pye; } else { // saved to avoid swallowing custom AttributeErrors, and pass through to // __getattr__ firstAttributeError = pye; } }
// in src/org/python/util/PyFilter.java
catch (PyException e) { throw new ServletException(e); }
// in src/org/python/util/JycompileAntTask.java
catch (PyException pye) { pye.printStackTrace(); throw new BuildException("Compile failed; see the compiler error output for details."); }
// in src/org/python/util/InteractiveInterpreter.java
catch (PyException exc) { if (exc.match(Py.SyntaxError)) { // Case 1 showexception(exc); return false; } else if (exc.match(Py.ValueError) || exc.match(Py.OverflowError)) { // Should not print the stack trace, just the error. showexception(exc); return false; } else { throw exc; } }
// in src/org/python/util/InteractiveInterpreter.java
catch (PyException exc) { if (exc.match(Py.SystemExit)) throw exc; showexception(exc); }
// in src/org/python/util/InteractiveConsole.java
catch(PyException exc) { if(!exc.match(Py.EOFError)) throw exc; write("\n"); break; }
// in src/org/python/util/PyServlet.java
catch (PyException e) { throw new ServletException(e); }
// in src/org/python/util/PyServlet.java
catch (PyException e) { throw new ServletException(e); }
(Lib) IOException 93
            
// in src/com/ziclix/python/sql/DataHandler.java
catch (IOException ioe) { throw zxJDBC.makeException(ioe); }
// in src/com/ziclix/python/sql/DataHandler.java
catch (IOException ioe) { throw zxJDBC.makeException(ioe); }
// in src/com/ziclix/python/sql/DataHandler.java
catch (IOException ioe) { throw zxJDBC.makeException(ioe); }
// in src/com/ziclix/python/sql/DataHandler.java
catch (IOException ioe) { throw zxJDBC.makeException(ioe); }
// in src/com/xhaus/modjy/ModjyJServlet.java
catch (IOException iox) { System.err.println("IOException: " + iox.toString()); }
// in src/org/python/indexer/AstCache.java
catch (IOException iox) { fine(filename + ": " + iox); return null; }
// in src/org/python/expose/generate/ExposeTask.java
catch (IOException e) { throw new BuildException("Unable to read '" + f + "' to expose it", e); }
// in src/org/python/expose/generate/ExposeTask.java
catch (IOException e) { throw new BuildException("Unable to write to '" + dest + "'", e); }
// in src/org/python/expose/generate/ExposeTask.java
catch (IOException e) { // Le sigh... }
// in src/org/python/Version.java
catch (IOException ioe) { System.err.println("There was a problem loading ".concat(versionProperties) .concat(":")); ioe.printStackTrace(); }
// in src/org/python/Version.java
catch (IOException ioe) { // ok }
// in src/org/python/modules/zipimport/zipimporter.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/modules/zipimport/zipimporter.java
catch (IOException ioe) { throw zipimport.ZipImportError("zipimport: can not open file: " + archive); }
// in src/org/python/modules/zipimport/zipimporter.java
catch (IOException ioe) { Py.writeDebug("import", "zipimporter.getDataStream exception: " + ioe.toString()); throw zipimport.ZipImportError("zipimport: can not open file: " + archive); }
// in src/org/python/modules/zipimport/zipimporter.java
catch (IOException ioe) { throw zipimport.ZipImportError(String.format("can't read Zip file: '%s'", archive)); }
// in src/org/python/modules/zipimport/zipimporter.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/modules/zipimport/zipimporter.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/modules/posix/PosixModule.java
catch (IOException ioe) { throw Py.OSError(ioe); }
// in src/org/python/modules/posix/PosixModule.java
catch (IOException ioe) { throw Py.OSError(ioe); }
// in src/org/python/modules/posix/PosixModule.java
catch (IOException ioe) { throw Py.OSError(ioe); }
// in src/org/python/modules/random/PyRandom.java
catch (IOException e) { throw Py.SystemError("state vector invalid: "+e.getMessage()); }
// in src/org/python/modules/random/PyRandom.java
catch (IOException e) { throw Py.SystemError("creation of state vector failed: "+ e.getMessage()); }
// in src/org/python/modules/imp.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/SyspathJavaLoader.java
catch (IOException exc) { return null; }
// in src/org/python/core/SyspathJavaLoader.java
catch (IOException e) { // Nothing to do }
// in src/org/python/core/SyspathJavaLoader.java
catch (IOException e) { return null; }
// in src/org/python/core/PySystemState.java
catch (IOException ioe) { return rootFile.getAbsolutePath(); }
// in src/org/python/core/PySystemState.java
catch (IOException e) { System.err.println("couldn't open registry file: " + file.toString()); }
// in src/org/python/core/PySystemState.java
catch (IOException e) { Py.writeWarning("initializer", "Failed reading '" + INITIALIZER_SERVICE + "' from " + initializerClassLoader); e.printStackTrace(System.err); return false; }
// in src/org/python/core/PySystemState.java
catch (IOException ioe) { executableFile = executableFile.getAbsoluteFile(); }
// in src/org/python/core/PySystemState.java
catch (IOException ioe) { }
// in src/org/python/core/PySystemState.java
catch (IOException e) { }
// in src/org/python/core/PyFileWriter.java
catch (IOException e) { throw Py.IOError(e); }
// in src/org/python/core/PyFileWriter.java
catch (IOException e) { throw Py.IOError(e); }
// in src/org/python/core/PyFileWriter.java
catch (IOException e) { throw Py.IOError(e); }
// in src/org/python/core/io/StreamIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/StreamIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/StreamIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/StreamIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/StreamIO.java
catch (IOException e) { return false; }
// in src/org/python/core/io/SocketIOBase.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/FileIO.java
catch (IOException ioe) { // On Solaris and Linux, ftruncate(3C) returns EINVAL if not a regular // file whereas, e.g., open(os.devnull, "w") works. Because we have to // simulate the "w" mode in Java, we suppress the exception. // Likewise Windows returns ERROR_INVALID_FUNCTION in that case and // ERROR_INVALID_HANDLE on ttys. Identifying those by the IOException // message is tedious as their messages are localized, so we suppress them // all =[ if (Platform.IS_WINDOWS || ((Platform.IS_SOLARIS || Platform.IS_LINUX) && Errno.EINVAL.description().equals(ioe.getMessage()))) { return; } throw Py.IOError(ioe); }
// in src/org/python/core/io/FileIO.java
catch (IOException e) { return false; }
// in src/org/python/core/io/FileIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/FileIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/FileIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/FileIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/FileIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/FileIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/FileIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/FileIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/FileIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/DatagramSocketIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/DatagramSocketIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/DatagramSocketIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/DatagramSocketIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/SocketIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/SocketIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/SocketIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/SocketIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/PyArray.java
catch(IOException e) { // discard anything successfully loaded delegate.setSize(origsize); throw Py.IOError(e); }
// in src/org/python/core/PyArray.java
catch(IOException e) { throw Py.IOError(e); }
// in src/org/python/core/PyFileReader.java
catch (IOException e) { throw Py.IOError(e); }
// in src/org/python/core/PyFileReader.java
catch (IOException e) { throw Py.IOError(e); }
// in src/org/python/core/PyFileReader.java
catch (IOException e) { throw Py.IOError(e); }
// in src/org/python/core/PyFileReader.java
catch (IOException e) { throw Py.IOError(e); }
// in src/org/python/core/__builtin__.java
catch (IOException e) { throw Py.IOError(e); }
// in src/org/python/core/ParserFacade.java
catch (IOException ioe) { }
// in src/org/python/core/ParserFacade.java
catch (IOException e) { reader = null; }
// in src/org/python/core/ParserFacade.java
catch (IOException i) { // XXX: Log the error? }
// in src/org/python/core/ClasspathPyImporter.java
catch (IOException e) { throw Py.JavaError(e); }
// in src/org/python/core/imp.java
catch(IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/imp.java
catch(IOException e) { throw Py.IOError(e); }
// in src/org/python/core/imp.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/imp.java
catch (IOException ioe) { if (!testing) { throw Py.ImportError(ioe.getMessage() + "[name=" + name + ", source=" + sourceName + ", compiled=" + compiledName + "]"); } }
// in src/org/python/core/imp.java
catch(IOException exc) { // If we can't write the cache file, just log and continue Py.writeDebug(IMPORT_LOG, "Unable to write to source cache file '" + compiledFilename + "' due to " + exc); return null; }
// in src/org/python/core/imp.java
catch(IOException e) { Py.writeDebug(IMPORT_LOG, "Unable to close source cache file '" + compiledFilename + "' due to " + e); }
// in src/org/python/core/imp.java
catch (IOException exc) { return false; }
// in src/org/python/core/util/importer.java
catch (IOException ioe) { throw Py.ImportError(ioe.getMessage() + "[path=" + fullSearchPath + "]"); }
// in src/org/python/core/packagecache/PathPackageManager.java
catch (IOException e) { continue; }
// in src/org/python/core/packagecache/PathPackageManager.java
catch (IOException e) { warning("skipping bad directory, '" + dir + "'"); }
// in src/org/python/core/packagecache/CachedJarsPackageManager.java
catch (IOException ioe) { // silently skip any bad directories warning("skipping bad jar, '" + (jarfile != null ? jarfile.toString() : jarurl.toString()) + "'"); }
// in src/org/python/core/packagecache/CachedJarsPackageManager.java
catch (IOException ioe) { // if (cachefile.exists()) cachefile.delete(); return null; }
// in src/org/python/core/packagecache/CachedJarsPackageManager.java
catch (IOException ioe) { warning("can't write cache file for '" + jarcanon + "'"); }
// in src/org/python/core/packagecache/CachedJarsPackageManager.java
catch (IOException ioe) { warning("invalid index file"); }
// in src/org/python/core/packagecache/CachedJarsPackageManager.java
catch (IOException ioe) { warning("can't write index file"); }
// in src/org/python/util/TemplateAntTask.java
catch(IOException e2) { throw new BuildException(e2.toString(), e2); }
// in src/org/python/util/JLineConsole.java
catch (IOException e) { // oh well, no history from file }
// in src/org/python/util/JLineConsole.java
catch (IOException e) { throw new RuntimeException(e); }
// in src/org/python/util/JLineConsole.java
catch (IOException ioe) { if (!fromSuspend(ioe)) { throw Py.IOError(ioe); } // Hopefully an IOException caused by ctrl-z (seems only BSD throws this). // Must reset jline to continue try { reader.getTerminal().initializeTerminal(); } catch (Exception e) { throw Py.IOError(e.getMessage()); } // Don't redisplay the prompt promptString = ""; }
// in src/org/python/util/jython.java
catch (IOException e) { throw Py.IOError(e); }
// in src/org/python/util/jython.java
catch (IOException ioe) { path = new File(opts.filename).getAbsoluteFile().getParent(); }
// in src/org/python/util/ReadlineConsole.java
catch(IOException ioe) { throw new PyException(Py.IOError); }
63
            
// in src/com/ziclix/python/sql/DataHandler.java
catch (IOException ioe) { throw zxJDBC.makeException(ioe); }
// in src/com/ziclix/python/sql/DataHandler.java
catch (IOException ioe) { throw zxJDBC.makeException(ioe); }
// in src/com/ziclix/python/sql/DataHandler.java
catch (IOException ioe) { throw zxJDBC.makeException(ioe); }
// in src/com/ziclix/python/sql/DataHandler.java
catch (IOException ioe) { throw zxJDBC.makeException(ioe); }
// in src/org/python/expose/generate/ExposeTask.java
catch (IOException e) { throw new BuildException("Unable to read '" + f + "' to expose it", e); }
// in src/org/python/expose/generate/ExposeTask.java
catch (IOException e) { throw new BuildException("Unable to write to '" + dest + "'", e); }
// in src/org/python/modules/zipimport/zipimporter.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/modules/zipimport/zipimporter.java
catch (IOException ioe) { throw zipimport.ZipImportError("zipimport: can not open file: " + archive); }
// in src/org/python/modules/zipimport/zipimporter.java
catch (IOException ioe) { Py.writeDebug("import", "zipimporter.getDataStream exception: " + ioe.toString()); throw zipimport.ZipImportError("zipimport: can not open file: " + archive); }
// in src/org/python/modules/zipimport/zipimporter.java
catch (IOException ioe) { throw zipimport.ZipImportError(String.format("can't read Zip file: '%s'", archive)); }
// in src/org/python/modules/zipimport/zipimporter.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/modules/zipimport/zipimporter.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/modules/posix/PosixModule.java
catch (IOException ioe) { throw Py.OSError(ioe); }
// in src/org/python/modules/posix/PosixModule.java
catch (IOException ioe) { throw Py.OSError(ioe); }
// in src/org/python/modules/posix/PosixModule.java
catch (IOException ioe) { throw Py.OSError(ioe); }
// in src/org/python/modules/random/PyRandom.java
catch (IOException e) { throw Py.SystemError("state vector invalid: "+e.getMessage()); }
// in src/org/python/modules/random/PyRandom.java
catch (IOException e) { throw Py.SystemError("creation of state vector failed: "+ e.getMessage()); }
// in src/org/python/modules/imp.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/PyFileWriter.java
catch (IOException e) { throw Py.IOError(e); }
// in src/org/python/core/PyFileWriter.java
catch (IOException e) { throw Py.IOError(e); }
// in src/org/python/core/PyFileWriter.java
catch (IOException e) { throw Py.IOError(e); }
// in src/org/python/core/io/StreamIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/StreamIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/StreamIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/StreamIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/SocketIOBase.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/FileIO.java
catch (IOException ioe) { // On Solaris and Linux, ftruncate(3C) returns EINVAL if not a regular // file whereas, e.g., open(os.devnull, "w") works. Because we have to // simulate the "w" mode in Java, we suppress the exception. // Likewise Windows returns ERROR_INVALID_FUNCTION in that case and // ERROR_INVALID_HANDLE on ttys. Identifying those by the IOException // message is tedious as their messages are localized, so we suppress them // all =[ if (Platform.IS_WINDOWS || ((Platform.IS_SOLARIS || Platform.IS_LINUX) && Errno.EINVAL.description().equals(ioe.getMessage()))) { return; } throw Py.IOError(ioe); }
// in src/org/python/core/io/FileIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/FileIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/FileIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/FileIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/FileIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/FileIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/FileIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/FileIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/FileIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/DatagramSocketIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/DatagramSocketIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/DatagramSocketIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/DatagramSocketIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/SocketIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/SocketIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/SocketIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/SocketIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/PyArray.java
catch(IOException e) { // discard anything successfully loaded delegate.setSize(origsize); throw Py.IOError(e); }
// in src/org/python/core/PyArray.java
catch(IOException e) { throw Py.IOError(e); }
// in src/org/python/core/PyFileReader.java
catch (IOException e) { throw Py.IOError(e); }
// in src/org/python/core/PyFileReader.java
catch (IOException e) { throw Py.IOError(e); }
// in src/org/python/core/PyFileReader.java
catch (IOException e) { throw Py.IOError(e); }
// in src/org/python/core/PyFileReader.java
catch (IOException e) { throw Py.IOError(e); }
// in src/org/python/core/__builtin__.java
catch (IOException e) { throw Py.IOError(e); }
// in src/org/python/core/ClasspathPyImporter.java
catch (IOException e) { throw Py.JavaError(e); }
// in src/org/python/core/imp.java
catch(IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/imp.java
catch(IOException e) { throw Py.IOError(e); }
// in src/org/python/core/imp.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/imp.java
catch (IOException ioe) { if (!testing) { throw Py.ImportError(ioe.getMessage() + "[name=" + name + ", source=" + sourceName + ", compiled=" + compiledName + "]"); } }
// in src/org/python/core/util/importer.java
catch (IOException ioe) { throw Py.ImportError(ioe.getMessage() + "[path=" + fullSearchPath + "]"); }
// in src/org/python/util/TemplateAntTask.java
catch(IOException e2) { throw new BuildException(e2.toString(), e2); }
// in src/org/python/util/JLineConsole.java
catch (IOException e) { throw new RuntimeException(e); }
// in src/org/python/util/JLineConsole.java
catch (IOException ioe) { if (!fromSuspend(ioe)) { throw Py.IOError(ioe); } // Hopefully an IOException caused by ctrl-z (seems only BSD throws this). // Must reset jline to continue try { reader.getTerminal().initializeTerminal(); } catch (Exception e) { throw Py.IOError(e.getMessage()); } // Don't redisplay the prompt promptString = ""; }
// in src/org/python/util/jython.java
catch (IOException e) { throw Py.IOError(e); }
// in src/org/python/util/ReadlineConsole.java
catch(IOException ioe) { throw new PyException(Py.IOError); }
(Lib) Exception 58
            
// in src/com/ziclix/python/sql/DataHandler.java
catch (Exception e) { SQLException cause = null, ex = new SQLException("error setting index [" + index + "]"); if (e instanceof SQLException) { cause = (SQLException) e; } else { cause = new SQLException(e.getMessage()); } ex.setNextException(cause); throw ex; }
// in src/com/ziclix/python/sql/DataHandler.java
catch (Exception e) { SQLException cause = null, ex = new SQLException("error setting index [" + index + "], type [" + type + "]"); if (e instanceof SQLException) { cause = (SQLException) e; } else { cause = new SQLException(e.getMessage()); } ex.setNextException(cause); throw ex; }
// in src/com/ziclix/python/sql/Jython22DataHandler.java
catch (Exception e) { SQLException cause = null, ex = new SQLException("error setting index [" + index + "]"); if (e instanceof SQLException) { cause = (SQLException) e; } else { cause = new SQLException(e.getMessage()); } ex.setNextException(cause); throw ex; }
// in src/com/ziclix/python/sql/Jython22DataHandler.java
catch (Exception e) { SQLException cause = null, ex = new SQLException("error setting index [" + index + "], type [" + type + "]"); if (e instanceof SQLException) { cause = (SQLException) e; } else { cause = new SQLException(e.getMessage()); } ex.setNextException(cause); throw ex; }
// in src/com/ziclix/python/sql/connect/Connectx.java
catch (Exception e) { throw zxJDBC.makeException(zxJDBC.DatabaseError, "unable to instantiate datasource"); }
// in src/com/ziclix/python/sql/pipe/db/DBSink.java
catch (Exception e) { // either a KeyError or this.bindings is None or null this.indexedBindings.__setitem__(pyIndex, entry.__getitem__(1)); }
// in src/com/ziclix/python/sql/pipe/db/DBSink.java
catch (Exception e) { // either a KeyError or this.bindings is None or null this.indexedBindings.__setitem__(pyIndex, entry.__getitem__(1)); }
// in src/com/ziclix/python/sql/pipe/db/BaseDB.java
catch (Exception e) { return cursor; }
// in src/com/ziclix/python/sql/pipe/db/BaseDB.java
catch (Exception e) { return cursor; }
// in src/com/ziclix/python/sql/Procedure.java
catch (SQLException e) { if (statement != null) { try { statement.close(); } catch (Exception ex) { } } throw e; }
// in src/com/ziclix/python/sql/Procedure.java
catch (Exception ex) { }
// in src/org/python/indexer/ast/BindingFinder.java
catch (Exception x) { Indexer.idx.handleException("error binding names for " + n, x); }
// in src/org/python/indexer/ast/NNode.java
catch (Exception x) { return handleExceptionInResolve(n, x); }
// in src/org/python/indexer/AstCache.java
catch (Exception x) { severe("Failed to clear disk cache: " + x); return false; }
// in src/org/python/indexer/AstCache.java
catch (Exception x) { fine("parse for " + filename + " failed: " + x); }
// in src/org/python/indexer/AstCache.java
catch (Exception x) { severe("Failed to deserialize " + sourcePath + ": " + x); return null; }
// in src/org/python/indexer/demos/Linker.java
catch (Exception x) { System.err.println("path problem: dest=" + destPath + ", root=" + rootPath + ": " + x); return null; }
// in src/org/python/expose/generate/TypeExposer.java
catch(Exception e) { // If we're unable to create the generated class, the process is // definitely ill, but that shouldn't be the case most of the time // so make this a runtime exception throw new RuntimeException("Unable to create generated builder", e); }
// in src/org/python/antlr/AnalyzingParser.java
catch (Exception x) { x.printStackTrace(); }
// in src/org/python/jsr223/PyScriptEngine.java
catch (Exception ee) { se = new ScriptException(pye); }
// in src/org/python/modules/_weakref/AbstractReference.java
catch (Exception exc) { Py.writeUnraisable(exc, callback); }
// in src/org/python/modules/ucnhash.java
catch (Exception exc) { return false; }
// in src/org/python/modules/_collections/PyDefaultDict.java
catch (Exception ex) { throw Py.KeyError(key); }
// in src/org/python/core/PyBeanProperty.java
catch (Exception e) { throw Py.JavaError(e); }
// in src/org/python/core/PyBeanProperty.java
catch (Exception e) { throw Py.JavaError(e); }
// in src/org/python/core/PyObject.java
catch (Exception exc) { throw Py.JavaError(exc); }
// in src/org/python/core/SyspathJavaLoader.java
catch (Exception e) { return path; }
// in src/org/python/core/PySystemState.java
catch (Exception exc) { return null; }
// in src/org/python/core/PySystemState.java
catch (Exception exc) { }
// in src/org/python/core/PySystemState.java
catch (Exception e) { // ignore any exception }
// in src/org/python/core/PySystemState.java
catch (Exception e) { Py.writeWarning("initializer", "Unexpected exception thrown while trying to use initializer service"); e.printStackTrace(System.err); }
// in src/org/python/core/PySystemState.java
catch (Exception e) { Py.writeWarning("initializer", "Failed initializing with class '" + className + "', continuing"); e.printStackTrace(System.err); return false; }
// in src/org/python/core/PySystemState.java
catch (Exception e) {}
// in src/org/python/core/PySystemState.java
catch (Exception e) { // just continue, nothing we can do }
// in src/org/python/core/PySystemState.java
catch (Exception e) { // continue - nothing we can do now! }
// in src/org/python/core/MakeProxies.java
catch (Exception exc) { throw Py.JavaError(exc); }
// in src/org/python/core/MakeProxies.java
catch (Exception exc) { throw Py.JavaError(exc); }
// in src/org/python/core/BytecodeLoader.java
catch (Exception e) { throw Py.JavaError(e); }
// in src/org/python/core/PyReflectedFunction.java
catch (Exception e) { throw Py.JavaError(e); }
// in src/org/python/core/PyBeanEventProperty.java
catch (Exception exc) { throw Py.JavaError(exc); }
// in src/org/python/core/PyBeanEventProperty.java
catch (Exception e) { throw Py.JavaError(e); }
// in src/org/python/core/PyBeanEventProperty.java
catch (Exception exc) { throw Py.JavaError(exc); }
// in src/org/python/core/PyBeanEvent.java
catch (Exception e) { throw Py.JavaError(e); }
// in src/org/python/core/io/StreamIO.java
catch (Exception e) { // XXX: masking other exceptions }
// in src/org/python/core/io/StreamIO.java
catch (Exception e) { // XXX: masking other exceptions }
// in src/org/python/core/PyRunnableBootstrap.java
catch (Exception e) { throw new IllegalArgumentException( "PyRunnable class does not specify apropriate constructor.", e); }
// in src/org/python/core/PyRunnableBootstrap.java
catch (Exception e) { throw new IllegalArgumentException( "PyRunnable class constructor does not support instantiation protocol.", e); }
// in src/org/python/core/exceptions.java
catch (Exception e) { throw Py.JavaError(e); }
// in src/org/python/core/PyJavaType.java
catch (Exception exc) { throw Py.JavaError(exc); }
// in src/org/python/core/PyJavaType.java
catch (Exception ex) { throw Py.TypeError("Could not copy Java object"); }
// in src/org/python/core/PyJavaType.java
catch (Exception ex) { throw Py.TypeError("Could not copy Java object"); }
// in src/org/python/core/PyJavaType.java
catch (Exception e) { throw Py.JavaError(e); }
// in src/org/python/core/CodeLoader.java
catch (Exception e) { return false; }
// in src/org/python/core/ParserFacade.java
catch (Exception e) { return lexer.eofWhileNested; }
// in src/org/python/core/imp.java
catch (Exception exc) { continue; }
// in src/org/python/core/NewCompilerResources.java
catch (Exception exc) { continue; }
// in src/org/python/util/JythoncAntTask.java
catch (Exception e) { // Have to catch this because of the semantics of calling main() String msg = "Exception while calling " + JYTHON_CLASS + ". Details: " + e.toString(); throw new BuildException(msg, e); }
// in src/org/python/util/JLineConsole.java
catch (Exception ex) { System.err.println(ex); }
// in src/org/python/util/JLineConsole.java
catch (IOException ioe) { if (!fromSuspend(ioe)) { throw Py.IOError(ioe); } // Hopefully an IOException caused by ctrl-z (seems only BSD throws this). // Must reset jline to continue try { reader.getTerminal().initializeTerminal(); } catch (Exception e) { throw Py.IOError(e.getMessage()); } // Don't redisplay the prompt promptString = ""; }
// in src/org/python/util/JLineConsole.java
catch (Exception e) { throw Py.IOError(e.getMessage()); }
27
            
// in src/com/ziclix/python/sql/DataHandler.java
catch (Exception e) { SQLException cause = null, ex = new SQLException("error setting index [" + index + "]"); if (e instanceof SQLException) { cause = (SQLException) e; } else { cause = new SQLException(e.getMessage()); } ex.setNextException(cause); throw ex; }
// in src/com/ziclix/python/sql/DataHandler.java
catch (Exception e) { SQLException cause = null, ex = new SQLException("error setting index [" + index + "], type [" + type + "]"); if (e instanceof SQLException) { cause = (SQLException) e; } else { cause = new SQLException(e.getMessage()); } ex.setNextException(cause); throw ex; }
// in src/com/ziclix/python/sql/Jython22DataHandler.java
catch (Exception e) { SQLException cause = null, ex = new SQLException("error setting index [" + index + "]"); if (e instanceof SQLException) { cause = (SQLException) e; } else { cause = new SQLException(e.getMessage()); } ex.setNextException(cause); throw ex; }
// in src/com/ziclix/python/sql/Jython22DataHandler.java
catch (Exception e) { SQLException cause = null, ex = new SQLException("error setting index [" + index + "], type [" + type + "]"); if (e instanceof SQLException) { cause = (SQLException) e; } else { cause = new SQLException(e.getMessage()); } ex.setNextException(cause); throw ex; }
// in src/com/ziclix/python/sql/connect/Connectx.java
catch (Exception e) { throw zxJDBC.makeException(zxJDBC.DatabaseError, "unable to instantiate datasource"); }
// in src/com/ziclix/python/sql/Procedure.java
catch (SQLException e) { if (statement != null) { try { statement.close(); } catch (Exception ex) { } } throw e; }
// in src/org/python/expose/generate/TypeExposer.java
catch(Exception e) { // If we're unable to create the generated class, the process is // definitely ill, but that shouldn't be the case most of the time // so make this a runtime exception throw new RuntimeException("Unable to create generated builder", e); }
// in src/org/python/modules/_collections/PyDefaultDict.java
catch (Exception ex) { throw Py.KeyError(key); }
// in src/org/python/core/PyBeanProperty.java
catch (Exception e) { throw Py.JavaError(e); }
// in src/org/python/core/PyBeanProperty.java
catch (Exception e) { throw Py.JavaError(e); }
// in src/org/python/core/PyObject.java
catch (Exception exc) { throw Py.JavaError(exc); }
// in src/org/python/core/MakeProxies.java
catch (Exception exc) { throw Py.JavaError(exc); }
// in src/org/python/core/MakeProxies.java
catch (Exception exc) { throw Py.JavaError(exc); }
// in src/org/python/core/BytecodeLoader.java
catch (Exception e) { throw Py.JavaError(e); }
// in src/org/python/core/PyReflectedFunction.java
catch (Exception e) { throw Py.JavaError(e); }
// in src/org/python/core/PyBeanEventProperty.java
catch (Exception exc) { throw Py.JavaError(exc); }
// in src/org/python/core/PyBeanEventProperty.java
catch (Exception e) { throw Py.JavaError(e); }
// in src/org/python/core/PyBeanEventProperty.java
catch (Exception exc) { throw Py.JavaError(exc); }
// in src/org/python/core/PyBeanEvent.java
catch (Exception e) { throw Py.JavaError(e); }
// in src/org/python/core/PyRunnableBootstrap.java
catch (Exception e) { throw new IllegalArgumentException( "PyRunnable class does not specify apropriate constructor.", e); }
// in src/org/python/core/PyRunnableBootstrap.java
catch (Exception e) { throw new IllegalArgumentException( "PyRunnable class constructor does not support instantiation protocol.", e); }
// in src/org/python/core/exceptions.java
catch (Exception e) { throw Py.JavaError(e); }
// in src/org/python/core/PyJavaType.java
catch (Exception exc) { throw Py.JavaError(exc); }
// in src/org/python/core/PyJavaType.java
catch (Exception ex) { throw Py.TypeError("Could not copy Java object"); }
// in src/org/python/core/PyJavaType.java
catch (Exception ex) { throw Py.TypeError("Could not copy Java object"); }
// in src/org/python/core/PyJavaType.java
catch (Exception e) { throw Py.JavaError(e); }
// in src/org/python/util/JythoncAntTask.java
catch (Exception e) { // Have to catch this because of the semantics of calling main() String msg = "Exception while calling " + JYTHON_CLASS + ". Details: " + e.toString(); throw new BuildException(msg, e); }
// in src/org/python/util/JLineConsole.java
catch (IOException ioe) { if (!fromSuspend(ioe)) { throw Py.IOError(ioe); } // Hopefully an IOException caused by ctrl-z (seems only BSD throws this). // Must reset jline to continue try { reader.getTerminal().initializeTerminal(); } catch (Exception e) { throw Py.IOError(e.getMessage()); } // Don't redisplay the prompt promptString = ""; }
// in src/org/python/util/JLineConsole.java
catch (Exception e) { throw Py.IOError(e.getMessage()); }
(Lib) Throwable 55
            
// in src/com/ziclix/python/sql/handler/RowIdHandler.java
catch (Throwable t) { ROWIDS.put(c, CHECKED); }
// in src/com/ziclix/python/sql/handler/RowIdHandler.java
catch (Throwable t) {}
// in src/com/ziclix/python/sql/Fetch.java
catch (Throwable t) { // ok }
// in src/com/ziclix/python/sql/Fetch.java
catch (Throwable e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/Fetch.java
catch (Throwable e) { }
// in src/com/ziclix/python/sql/Fetch.java
catch (Throwable e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/Fetch.java
catch (Throwable e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/Fetch.java
catch (Throwable e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/Fetch.java
catch (Throwable t) { throw zxJDBC.makeException(t); }
// in src/com/ziclix/python/sql/zxJDBC.java
catch (Throwable t) { throw makeException(t); }
// in src/com/ziclix/python/sql/zxJDBC.java
catch (Throwable t) { Py.writeComment("zxJDBC", "failed to load connector [" + name + "] using class [" + className + "]"); }
// in src/com/ziclix/python/sql/DataHandler.java
catch (Throwable t) { SQLException cause = null; SQLException ex = new SQLException("error setting index [" + index + "], coltype [" + colType + "], datatype [" + dataType + "], datatypename [" + dataTypeName + "]"); if (t instanceof SQLException) { cause = (SQLException)t; } else { cause = new SQLException(t.getMessage()); } ex.setNextException(cause); throw ex; }
// in src/com/ziclix/python/sql/DataHandler.java
catch (Throwable t) {}
// in src/com/ziclix/python/sql/Jython22DataHandler.java
catch (Throwable t) {}
// in src/com/ziclix/python/sql/Jython22DataHandler.java
catch (Throwable t) { bd = set.getBigDecimal(col, 10); }
// in src/com/ziclix/python/sql/Jython22DataHandler.java
catch (Throwable t) { SQLException cause = null; SQLException ex = new SQLException("error setting index [" + index + "], coltype [" + colType + "], datatype [" + dataType + "], datatypename [" + dataTypeName + "]"); if (t instanceof SQLException) { cause = (SQLException)t; } else { cause = new SQLException(t.getMessage()); } ex.setNextException(cause); throw ex; }
// in src/com/ziclix/python/sql/connect/Connect.java
catch (Throwable e) { throw zxJDBC.makeException(zxJDBC.DatabaseError, "driver [" + driver + "] not found"); }
// in src/com/ziclix/python/sql/pipe/Pipe.java
catch (Throwable e) { this.exception = e.fillInStackTrace(); this.queue.close(); }
// in src/com/ziclix/python/sql/PyCursor.java
catch (Throwable t) {}
// in src/com/ziclix/python/sql/PyCursor.java
catch (Throwable e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyCursor.java
catch (Throwable t) { if (statement != null) { statement.close(); } throw zxJDBC.makeException(t); }
// in src/com/ziclix/python/sql/PyCursor.java
catch (Throwable t) { if (statement != null && !(sql instanceof PyStatement)) { // only close static, single-use statements statement.close(); } throw zxJDBC.makeException(zxJDBC.Error, t, rowIndex); }
// in src/com/ziclix/python/sql/PyCursor.java
catch (Throwable e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyCursor.java
catch (Throwable e) { // ok }
// in src/org/python/compiler/ScopesCompiler.java
catch (Throwable t) { throw ParserFacade.fixParseError(null, t, code_compiler.getFilename()); }
// in src/org/python/core/PyBeanProperty.java
catch (Throwable t) { throw Py.JavaError(t); }
// in src/org/python/core/PyObject.java
catch (Throwable t) { _jthrow(t); return null; }
// in src/org/python/core/PyReflectedConstructor.java
catch (Throwable t) { throw Py.JavaError(t); }
// in src/org/python/core/PyReflectedConstructor.java
catch (Throwable t) { throw Py.JavaError(t); }
// in src/org/python/core/PyTableCode.java
catch (Throwable t) { // Convert exceptions that occured in Java code to PyExceptions PyException pye = Py.JavaError(t); pye.tracebackHere(frame); frame.f_lasti = -1; if (frame.tracefunc != null) { frame.tracefunc.traceException(frame, pye); } if (ts.profilefunc != null) { ts.profilefunc.traceException(frame, pye); } // Rethrow the exception to the next stack frame ts.exception = previous_exception; ts.frame = ts.frame.f_back; throw pye; }
// in src/org/python/core/PyReflectedFunction.java
catch (Throwable t) { throw Py.JavaError(t); }
// in src/org/python/core/PyBaseCode.java
catch (Throwable t) { // Convert exceptions that occured in Java code to PyExceptions PyException pye = Py.JavaError(t); pye.tracebackHere(frame); frame.f_lasti = -1; if (frame.tracefunc != null) { frame.tracefunc.traceException(frame, pye); } if (ts.profilefunc != null) { ts.profilefunc.traceException(frame, pye); } // Rethrow the exception to the next stack frame ts.exception = previous_exception; ts.frame = ts.frame.f_back; throw pye; }
// in src/org/python/core/exceptions.java
catch (Throwable t) { throw Py.JavaError(t); }
// in src/org/python/core/CompilerFacade.java
catch (Throwable t) { throw ParserFacade.fixParseError(null, t, filename); }
// in src/org/python/core/Py.java
catch (Throwable t) { // continue }
// in src/org/python/core/Py.java
catch (Throwable t) { t.printStackTrace(); }
// in src/org/python/core/Py.java
catch (Throwable t) { throw Py.JavaError(t); }
// in src/org/python/core/PySequence.java
catch (Throwable t) { // ok }
// in src/org/python/core/ParserFacade.java
catch (Throwable t) { if (bufReader == null) throw Py.JavaError(t); // can't do any more try { // then, try parsing as a module bufReader.reset(); return parse(bufReader, CompileMode.exec, filename, cflags); } catch (Throwable tt) { throw fixParseError(bufReader, tt, filename); } }
// in src/org/python/core/ParserFacade.java
catch (Throwable tt) { throw fixParseError(bufReader, tt, filename); }
// in src/org/python/core/ParserFacade.java
catch (Throwable t) { throw fixParseError(bufReader, t, filename); }
// in src/org/python/core/ParserFacade.java
catch (Throwable t) { throw fixParseError(bufReader, t, filename); }
// in src/org/python/core/ParserFacade.java
catch (Throwable t) { throw fixParseError(bufReader, t, filename); }
// in src/org/python/core/ParserFacade.java
catch (Throwable t) { PyException p = fixParseError(reader, t, filename); if (reader != null && validPartialSentence(reader, kind, filename)) { return null; } throw p; }
// in src/org/python/core/PyBytecode.java
catch (Throwable t) { PyException pye = Py.setException(t, f); why = Why.EXCEPTION; ts.exception = pye; if (debug) { System.err.println("Caught exception:" + pye); } }
// in src/org/python/core/imp.java
catch (Throwable t) { if (testing) { return null; } else { throw Py.JavaError(t); } }
// in src/org/python/core/imp.java
catch(Throwable t) { throw ParserFacade.fixParseError(null, t, filename); }
// in src/org/python/core/PyGenerator.java
catch (Throwable t) { // but we currently ignore any Java exception completely. perhaps we // can also output something meaningful too? }
// in src/org/python/util/jython.java
catch (Throwable t) { Py.printException(t); System.exit(-1); }
// in src/org/python/util/jython.java
catch (Throwable t) { Py.printException(t); }
// in src/org/python/util/jython.java
catch (Throwable t) { if (t instanceof PyException && ((PyException)t).match(_systemrestart.SystemRestart)) { // Shutdown this instance... shouldRestart = true; shutdownInterpreter(); interp.cleanup(); // ..reset the state... Py.setSystemState(new PySystemState()); // ...and start again return; } else { Py.printException(t); interp.cleanup(); System.exit(-1); } }
// in src/org/python/util/jython.java
catch (Throwable t) { Py.printException(t); System.exit(1); }
// in src/org/python/util/jython.java
catch (Throwable t) { Py.printException(t); interp.cleanup(); System.exit(-1); }
// in src/org/python/util/jython.java
catch (Throwable t) { Py.printException(t); }
// in src/org/python/util/jython.java
catch (Throwable t) { // fall through }
31
            
// in src/com/ziclix/python/sql/Fetch.java
catch (Throwable e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/Fetch.java
catch (Throwable e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/Fetch.java
catch (Throwable e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/Fetch.java
catch (Throwable e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/Fetch.java
catch (Throwable t) { throw zxJDBC.makeException(t); }
// in src/com/ziclix/python/sql/zxJDBC.java
catch (Throwable t) { throw makeException(t); }
// in src/com/ziclix/python/sql/DataHandler.java
catch (Throwable t) { SQLException cause = null; SQLException ex = new SQLException("error setting index [" + index + "], coltype [" + colType + "], datatype [" + dataType + "], datatypename [" + dataTypeName + "]"); if (t instanceof SQLException) { cause = (SQLException)t; } else { cause = new SQLException(t.getMessage()); } ex.setNextException(cause); throw ex; }
// in src/com/ziclix/python/sql/Jython22DataHandler.java
catch (Throwable t) { SQLException cause = null; SQLException ex = new SQLException("error setting index [" + index + "], coltype [" + colType + "], datatype [" + dataType + "], datatypename [" + dataTypeName + "]"); if (t instanceof SQLException) { cause = (SQLException)t; } else { cause = new SQLException(t.getMessage()); } ex.setNextException(cause); throw ex; }
// in src/com/ziclix/python/sql/connect/Connect.java
catch (Throwable e) { throw zxJDBC.makeException(zxJDBC.DatabaseError, "driver [" + driver + "] not found"); }
// in src/com/ziclix/python/sql/PyCursor.java
catch (Throwable e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyCursor.java
catch (Throwable t) { if (statement != null) { statement.close(); } throw zxJDBC.makeException(t); }
// in src/com/ziclix/python/sql/PyCursor.java
catch (Throwable t) { if (statement != null && !(sql instanceof PyStatement)) { // only close static, single-use statements statement.close(); } throw zxJDBC.makeException(zxJDBC.Error, t, rowIndex); }
// in src/com/ziclix/python/sql/PyCursor.java
catch (Throwable e) { throw zxJDBC.makeException(e); }
// in src/org/python/compiler/ScopesCompiler.java
catch (Throwable t) { throw ParserFacade.fixParseError(null, t, code_compiler.getFilename()); }
// in src/org/python/core/PyBeanProperty.java
catch (Throwable t) { throw Py.JavaError(t); }
// in src/org/python/core/PyReflectedConstructor.java
catch (Throwable t) { throw Py.JavaError(t); }
// in src/org/python/core/PyReflectedConstructor.java
catch (Throwable t) { throw Py.JavaError(t); }
// in src/org/python/core/PyTableCode.java
catch (Throwable t) { // Convert exceptions that occured in Java code to PyExceptions PyException pye = Py.JavaError(t); pye.tracebackHere(frame); frame.f_lasti = -1; if (frame.tracefunc != null) { frame.tracefunc.traceException(frame, pye); } if (ts.profilefunc != null) { ts.profilefunc.traceException(frame, pye); } // Rethrow the exception to the next stack frame ts.exception = previous_exception; ts.frame = ts.frame.f_back; throw pye; }
// in src/org/python/core/PyReflectedFunction.java
catch (Throwable t) { throw Py.JavaError(t); }
// in src/org/python/core/PyBaseCode.java
catch (Throwable t) { // Convert exceptions that occured in Java code to PyExceptions PyException pye = Py.JavaError(t); pye.tracebackHere(frame); frame.f_lasti = -1; if (frame.tracefunc != null) { frame.tracefunc.traceException(frame, pye); } if (ts.profilefunc != null) { ts.profilefunc.traceException(frame, pye); } // Rethrow the exception to the next stack frame ts.exception = previous_exception; ts.frame = ts.frame.f_back; throw pye; }
// in src/org/python/core/exceptions.java
catch (Throwable t) { throw Py.JavaError(t); }
// in src/org/python/core/CompilerFacade.java
catch (Throwable t) { throw ParserFacade.fixParseError(null, t, filename); }
// in src/org/python/core/Py.java
catch (Throwable t) { throw Py.JavaError(t); }
// in src/org/python/core/ParserFacade.java
catch (Throwable t) { if (bufReader == null) throw Py.JavaError(t); // can't do any more try { // then, try parsing as a module bufReader.reset(); return parse(bufReader, CompileMode.exec, filename, cflags); } catch (Throwable tt) { throw fixParseError(bufReader, tt, filename); } }
// in src/org/python/core/ParserFacade.java
catch (Throwable tt) { throw fixParseError(bufReader, tt, filename); }
// in src/org/python/core/ParserFacade.java
catch (Throwable t) { throw fixParseError(bufReader, t, filename); }
// in src/org/python/core/ParserFacade.java
catch (Throwable t) { throw fixParseError(bufReader, t, filename); }
// in src/org/python/core/ParserFacade.java
catch (Throwable t) { throw fixParseError(bufReader, t, filename); }
// in src/org/python/core/ParserFacade.java
catch (Throwable t) { PyException p = fixParseError(reader, t, filename); if (reader != null && validPartialSentence(reader, kind, filename)) { return null; } throw p; }
// in src/org/python/core/imp.java
catch (Throwable t) { if (testing) { return null; } else { throw Py.JavaError(t); } }
// in src/org/python/core/imp.java
catch(Throwable t) { throw ParserFacade.fixParseError(null, t, filename); }
(Lib) SQLException 39
            
// in src/com/ziclix/python/sql/handler/OracleDataHandler.java
catch (SQLException sqle) { scale = precision = 0; }
// in src/com/ziclix/python/sql/handler/InformixDataHandler.java
catch (SQLException e) { obj = super.getPyObject(set, col, type); }
// in src/com/ziclix/python/sql/handler/PostgresqlDataHandler.java
catch (SQLException e) { obj = super.getPyObject(set, col, Types.VARCHAR); }
// in src/com/ziclix/python/sql/Fetch.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyConnection.java
catch (SQLException e) { return String.format("<PyConnection object at %s", Py.idstr(this)); }
// in src/com/ziclix/python/sql/PyConnection.java
catch (SQLException e) { throw zxJDBC.makeException(zxJDBC.DatabaseError, e); }
// in src/com/ziclix/python/sql/PyConnection.java
catch (SQLException e) { throw zxJDBC.makeException(zxJDBC.DatabaseError, e); }
// in src/com/ziclix/python/sql/PyConnection.java
catch (SQLException e) { throw zxJDBC.makeException(zxJDBC.DatabaseError, e); }
// in src/com/ziclix/python/sql/PyConnection.java
catch (SQLException e) { throw zxJDBC.makeException(zxJDBC.DatabaseError, e); }
// in src/com/ziclix/python/sql/PyConnection.java
catch (SQLException e) { throw zxJDBC.makeException(zxJDBC.DatabaseError, e); }
// in src/com/ziclix/python/sql/PyConnection.java
catch (SQLException e) { throw zxJDBC.makeException(zxJDBC.DatabaseError, e); }
// in src/com/ziclix/python/sql/PyConnection.java
catch (SQLException e) { throw zxJDBC.makeException(zxJDBC.DatabaseError, e); }
// in src/com/ziclix/python/sql/PyConnection.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyConnection.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyConnection.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyConnection.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyExtendedCursor.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyExtendedCursor.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyExtendedCursor.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyExtendedCursor.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyExtendedCursor.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyExtendedCursor.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyExtendedCursor.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyExtendedCursor.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyExtendedCursor.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyExtendedCursor.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyExtendedCursor.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyExtendedCursor.java
catch (SQLException e) { }
// in src/com/ziclix/python/sql/connect/Connectx.java
catch (SQLException e) { throw zxJDBC.makeException(zxJDBC.DatabaseError, e); }
// in src/com/ziclix/python/sql/connect/Connectx.java
catch (SQLException e) { throw zxJDBC.makeException(zxJDBC.DatabaseError, e); }
// in src/com/ziclix/python/sql/connect/Connect.java
catch (SQLException e) { throw zxJDBC.makeException(zxJDBC.DatabaseError, e); }
// in src/com/ziclix/python/sql/connect/Connect.java
catch (SQLException e) { throw zxJDBC.makeException(zxJDBC.DatabaseError, e); }
// in src/com/ziclix/python/sql/connect/Lookup.java
catch (SQLException e) { throw zxJDBC.makeException(zxJDBC.DatabaseError, e); }
// in src/com/ziclix/python/sql/connect/Lookup.java
catch (SQLException e) { throw zxJDBC.makeException(zxJDBC.DatabaseError, e); }
// in src/com/ziclix/python/sql/PyStatement.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyStatement.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/JDBC20DataHandler.java
catch (SQLException e) { obj = super.getPyObject(set, col, type); }
// in src/com/ziclix/python/sql/Procedure.java
catch (SQLException e) { if (statement != null) { try { statement.close(); } catch (Exception ex) { } } throw e; }
// in src/com/ziclix/python/sql/PyCursor.java
catch (SQLException sqle) { throw zxJDBC.makeException(sqle); }
33
            
// in src/com/ziclix/python/sql/Fetch.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyConnection.java
catch (SQLException e) { throw zxJDBC.makeException(zxJDBC.DatabaseError, e); }
// in src/com/ziclix/python/sql/PyConnection.java
catch (SQLException e) { throw zxJDBC.makeException(zxJDBC.DatabaseError, e); }
// in src/com/ziclix/python/sql/PyConnection.java
catch (SQLException e) { throw zxJDBC.makeException(zxJDBC.DatabaseError, e); }
// in src/com/ziclix/python/sql/PyConnection.java
catch (SQLException e) { throw zxJDBC.makeException(zxJDBC.DatabaseError, e); }
// in src/com/ziclix/python/sql/PyConnection.java
catch (SQLException e) { throw zxJDBC.makeException(zxJDBC.DatabaseError, e); }
// in src/com/ziclix/python/sql/PyConnection.java
catch (SQLException e) { throw zxJDBC.makeException(zxJDBC.DatabaseError, e); }
// in src/com/ziclix/python/sql/PyConnection.java
catch (SQLException e) { throw zxJDBC.makeException(zxJDBC.DatabaseError, e); }
// in src/com/ziclix/python/sql/PyConnection.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyConnection.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyConnection.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyConnection.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyExtendedCursor.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyExtendedCursor.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyExtendedCursor.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyExtendedCursor.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyExtendedCursor.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyExtendedCursor.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyExtendedCursor.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyExtendedCursor.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyExtendedCursor.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyExtendedCursor.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyExtendedCursor.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/connect/Connectx.java
catch (SQLException e) { throw zxJDBC.makeException(zxJDBC.DatabaseError, e); }
// in src/com/ziclix/python/sql/connect/Connectx.java
catch (SQLException e) { throw zxJDBC.makeException(zxJDBC.DatabaseError, e); }
// in src/com/ziclix/python/sql/connect/Connect.java
catch (SQLException e) { throw zxJDBC.makeException(zxJDBC.DatabaseError, e); }
// in src/com/ziclix/python/sql/connect/Connect.java
catch (SQLException e) { throw zxJDBC.makeException(zxJDBC.DatabaseError, e); }
// in src/com/ziclix/python/sql/connect/Lookup.java
catch (SQLException e) { throw zxJDBC.makeException(zxJDBC.DatabaseError, e); }
// in src/com/ziclix/python/sql/connect/Lookup.java
catch (SQLException e) { throw zxJDBC.makeException(zxJDBC.DatabaseError, e); }
// in src/com/ziclix/python/sql/PyStatement.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyStatement.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/Procedure.java
catch (SQLException e) { if (statement != null) { try { statement.close(); } catch (Exception ex) { } } throw e; }
// in src/com/ziclix/python/sql/PyCursor.java
catch (SQLException sqle) { throw zxJDBC.makeException(sqle); }
(Lib) SecurityException 20
            
// in src/org/python/compiler/ProxyMaker.java
catch (SecurityException e) { return; }
// in src/org/python/modules/zipimport/zipimporter.java
catch (SecurityException se) { // continue }
// in src/org/python/modules/posix/PosixModule.java
catch (SecurityException se) { return environ; }
// in src/org/python/core/SyspathJavaLoader.java
catch(SecurityException e) { return null; }
// in src/org/python/core/PySystemState.java
catch (SecurityException e) { }
// in src/org/python/core/PySystemState.java
catch (SecurityException se) { // ignore, can't do anything about it }
// in src/org/python/core/PySystemState.java
catch (SecurityException e) { // Must be running in a security environment that doesn't allow access to the class // loader }
// in src/org/python/core/PySystemState.java
catch (SecurityException se) { Py.writeDebug("PySystemState", "Can't register cleanup closer hook"); return null; }
// in src/org/python/core/BytecodeLoader.java
catch (SecurityException e) { }
// in src/org/python/core/PyReflectedFunction.java
catch (SecurityException se) { // This case is pretty far in the corner, so don't scream if we can't set the method // accessible due to a security manager. Any calls to it will fail with an // IllegalAccessException, so it'll become visible there. This way we don't spam // people who aren't calling methods like this from Python with warnings if a // library they're using happens to have a method like this. }
// in src/org/python/core/PyTraceback.java
catch (SecurityException e) { return null; // If we don't have read access to the file, return null }
// in src/org/python/core/PyType.java
catch (SecurityException e) { exc = e; }
// in src/org/python/core/Py.java
catch (SecurityException e) { syspathJavaLoaderRestricted = true; }
// in src/org/python/core/imp.java
catch (SecurityException e) { return false; }
// in src/org/python/core/imp.java
catch(SecurityException exc) { // If we can't write the cache file, just log and continue Py.writeDebug(IMPORT_LOG, "Unable to write to source cache file '" + compiledFilename + "' due to " + exc); return null; }
// in src/org/python/core/imp.java
catch (SecurityException e) { // ok }
// in src/org/python/core/imp.java
catch (SecurityException e) { // ok }
// in src/org/python/core/packagecache/PathPackageManager.java
catch (SecurityException se) { return false; }
// in src/org/python/util/JLineConsole.java
catch (SecurityException se) { // continue }
// in src/org/python/util/jython.java
catch (SecurityException e) { // continue }
0
(Lib) ClassCastException 9
            
// in src/com/ziclix/python/sql/connect/Connectx.java
catch (NoSuchMethodException e) { Class<?> primitive = null; try { Field f = valueClass.getField("TYPE"); primitive = (Class<?>) f.get(valueClass); } catch (NoSuchFieldException ex) { } catch (IllegalAccessException ex) { } catch (ClassCastException ex) { } if (primitive != null && primitive.isPrimitive()) { return getMethod(srcClass, methodName, primitive); } }
// in src/com/ziclix/python/sql/connect/Connectx.java
catch (ClassCastException ex) { }
// in src/org/python/core/PyArray.java
catch (ClassCastException e) { throw Py.TypeError("Type not compatible with array type"); }
// in src/org/python/core/PyArray.java
catch(ClassCastException e) { throw Py.TypeError("Type not compatible with array type"); }
// in src/org/python/core/PyArray.java
catch(ClassCastException e) { throw Py.TypeError("Type not compatible with array type"); }
// in src/org/python/core/PyArray.java
catch(ClassCastException e) { throw Py.TypeError("Type not compatible with array type"); }
// in src/org/python/core/PyArray.java
catch(ClassCastException e) { throw Py.TypeError("Type not compatible with array type"); }
// in src/org/python/core/__builtin__.java
catch (ClassCastException e) { throw Py.TypeError("apply() 3rd argument must be a " + "dictionary with string keys"); }
// in src/org/python/core/__builtin__.java
catch (ClassCastException e) { throw Py.TypeError(String.format("Expected keys() to be a list, not '%s'", retObj.getType().fastGetName())); }
// in src/org/python/core/PyJavaType.java
catch(ClassCastException classCast) { return Py.NotImplemented; }
7
            
// in src/org/python/core/PyArray.java
catch (ClassCastException e) { throw Py.TypeError("Type not compatible with array type"); }
// in src/org/python/core/PyArray.java
catch(ClassCastException e) { throw Py.TypeError("Type not compatible with array type"); }
// in src/org/python/core/PyArray.java
catch(ClassCastException e) { throw Py.TypeError("Type not compatible with array type"); }
// in src/org/python/core/PyArray.java
catch(ClassCastException e) { throw Py.TypeError("Type not compatible with array type"); }
// in src/org/python/core/PyArray.java
catch(ClassCastException e) { throw Py.TypeError("Type not compatible with array type"); }
// in src/org/python/core/__builtin__.java
catch (ClassCastException e) { throw Py.TypeError("apply() 3rd argument must be a " + "dictionary with string keys"); }
// in src/org/python/core/__builtin__.java
catch (ClassCastException e) { throw Py.TypeError(String.format("Expected keys() to be a list, not '%s'", retObj.getType().fastGetName())); }
(Lib) ClassNotFoundException 9
            
// in src/com/ziclix/python/sql/JDBC30DataHandler.java
catch (ClassNotFoundException e) { throw new RuntimeException("JDBC3.0 required to use this DataHandler"); }
// in src/org/python/modules/random/PyRandom.java
catch (ClassNotFoundException e) { throw Py.SystemError("state vector invalid: "+e.getMessage()); }
// in src/org/python/core/PySystemState.java
catch (ClassNotFoundException e) { Py.writeWarning("initializer", "Specified initializer class '" + className + "' not found, continuing"); return false; }
// in src/org/python/core/BytecodeLoader.java
catch (ClassNotFoundException cnfe) {}
// in src/org/python/core/PyType.java
catch (ClassNotFoundException e) { // Well, this is certainly surprising. throw new RuntimeException("Got ClassNotFound calling Class.forName on an already " + " found class.", e); }
// in src/org/python/core/Py.java
catch (ClassNotFoundException cnfe) { // let the default classloader try // XXX: by trying another classloader that may not be on a // parent/child relationship with the Jython's parent // classsloader we are risking some nasty class loading // problems (such as having two incompatible copies for // the same class that is itself a dependency of two // classes loaded from these two different class loaders) }
// in src/org/python/core/Py.java
catch (ClassNotFoundException e) { // e.printStackTrace(); return null; }
// in src/org/python/core/Py.java
catch (ClassNotFoundException e) { return null; }
// in src/org/python/util/PythonObjectInputStream.java
catch (ClassNotFoundException exc) { PyObject m = importModule(clsName); Object cls = m.__tojava__(Class.class); if (cls != null && cls != Py.NoConversion) { return (Class<?>)cls; } throw exc; }
4
            
// in src/com/ziclix/python/sql/JDBC30DataHandler.java
catch (ClassNotFoundException e) { throw new RuntimeException("JDBC3.0 required to use this DataHandler"); }
// in src/org/python/modules/random/PyRandom.java
catch (ClassNotFoundException e) { throw Py.SystemError("state vector invalid: "+e.getMessage()); }
// in src/org/python/core/PyType.java
catch (ClassNotFoundException e) { // Well, this is certainly surprising. throw new RuntimeException("Got ClassNotFound calling Class.forName on an already " + " found class.", e); }
// in src/org/python/util/PythonObjectInputStream.java
catch (ClassNotFoundException exc) { PyObject m = importModule(clsName); Object cls = m.__tojava__(Class.class); if (cls != null && cls != Py.NoConversion) { return (Class<?>)cls; } throw exc; }
(Lib) IllegalArgumentException 8
            
// in src/org/python/core/FutureFeature.java
catch (IllegalArgumentException ex) { throw new ParseException("future feature " + featureName + " is not defined"); }
// in src/org/python/core/stringlib/MarkupIterator.java
catch (IllegalArgumentException e) { throw Py.ValueError(e.getMessage()); }
// in src/org/python/core/PyArray.java
catch(IllegalArgumentException e) { throw Py.TypeError("Slice typecode '" + array.typecode + "' is not compatible with this array (typecode '" + this.typecode + "')"); }
// in src/org/python/core/Py.java
catch (IllegalArgumentException e) { // e.printStackTrace(); return null; }
// in src/org/python/core/Py.java
catch (IllegalArgumentException e) { throw JavaError(e); }
// in src/org/python/core/PyInteger.java
catch (IllegalArgumentException e) { throw Py.ValueError(e.getMessage()); }
// in src/org/python/core/PyString.java
catch (IllegalArgumentException e) { throw Py.ValueError(e.getMessage()); }
// in src/org/python/core/PyString.java
catch (IllegalArgumentException e) { throw Py.ValueError(e.getMessage()); }
7
            
// in src/org/python/core/FutureFeature.java
catch (IllegalArgumentException ex) { throw new ParseException("future feature " + featureName + " is not defined"); }
// in src/org/python/core/stringlib/MarkupIterator.java
catch (IllegalArgumentException e) { throw Py.ValueError(e.getMessage()); }
// in src/org/python/core/PyArray.java
catch(IllegalArgumentException e) { throw Py.TypeError("Slice typecode '" + array.typecode + "' is not compatible with this array (typecode '" + this.typecode + "')"); }
// in src/org/python/core/Py.java
catch (IllegalArgumentException e) { throw JavaError(e); }
// in src/org/python/core/PyInteger.java
catch (IllegalArgumentException e) { throw Py.ValueError(e.getMessage()); }
// in src/org/python/core/PyString.java
catch (IllegalArgumentException e) { throw Py.ValueError(e.getMessage()); }
// in src/org/python/core/PyString.java
catch (IllegalArgumentException e) { throw Py.ValueError(e.getMessage()); }
(Lib) NumberFormatException 8
            
// in src/org/python/modules/ucnhash.java
catch (NumberFormatException exc) { return -1; // Maybe fallthrough to the main algorithme. }
// in src/org/python/modules/cPickle.java
catch(NumberFormatException e) { try { value = Py.newLong(line); } catch(NumberFormatException e2) { throw Py.ValueError("could not convert string to int"); } }
// in src/org/python/modules/cPickle.java
catch(NumberFormatException e2) { throw Py.ValueError("could not convert string to int"); }
// in src/org/python/core/stringlib/FieldNameIterator.java
catch (NumberFormatException e) { this.head = headStr;
// in src/org/python/core/stringlib/FieldNameIterator.java
catch (NumberFormatException e) { chunk.value = itemValue; }
// in src/org/python/core/PyString.java
catch (NumberFormatException exc) { throw Py.ValueError("invalid literal for __float__: "+getString()); }
// in src/org/python/core/PyString.java
catch (NumberFormatException exc) { throw Py.ValueError("invalid literal for int() with base " + base + ": " + getString()); }
// in src/org/python/core/PyString.java
catch (NumberFormatException exc) { if (this instanceof PyUnicode) { // TODO: here's a basic issue: do we use the BigInteger constructor // above, or add an equivalent to CPython's PyUnicode_EncodeDecimal; // we should note that the current error string does not quite match // CPython regardless of the codec, that's going to require some more work throw Py.UnicodeEncodeError("decimal", "codec can't encode character", 0,0, "invalid decimal Unicode string"); } else { throw Py.ValueError("invalid literal for long() with base " + base + ": " + getString()); } }
5
            
// in src/org/python/modules/cPickle.java
catch(NumberFormatException e) { try { value = Py.newLong(line); } catch(NumberFormatException e2) { throw Py.ValueError("could not convert string to int"); } }
// in src/org/python/modules/cPickle.java
catch(NumberFormatException e2) { throw Py.ValueError("could not convert string to int"); }
// in src/org/python/core/PyString.java
catch (NumberFormatException exc) { throw Py.ValueError("invalid literal for __float__: "+getString()); }
// in src/org/python/core/PyString.java
catch (NumberFormatException exc) { throw Py.ValueError("invalid literal for int() with base " + base + ": " + getString()); }
// in src/org/python/core/PyString.java
catch (NumberFormatException exc) { if (this instanceof PyUnicode) { // TODO: here's a basic issue: do we use the BigInteger constructor // above, or add an equivalent to CPython's PyUnicode_EncodeDecimal; // we should note that the current error string does not quite match // CPython regardless of the codec, that's going to require some more work throw Py.UnicodeEncodeError("decimal", "codec can't encode character", 0,0, "invalid decimal Unicode string"); } else { throw Py.ValueError("invalid literal for long() with base " + base + ": " + getString()); } }
(Lib) IllegalAccessException 7
            
// in src/com/ziclix/python/sql/connect/Connectx.java
catch (IllegalAccessException e) { throw zxJDBC.makeException("illegal access for " + exceptionMsg); }
// in src/com/ziclix/python/sql/connect/Connectx.java
catch (NoSuchMethodException e) { Class<?> primitive = null; try { Field f = valueClass.getField("TYPE"); primitive = (Class<?>) f.get(valueClass); } catch (NoSuchFieldException ex) { } catch (IllegalAccessException ex) { } catch (ClassCastException ex) { } if (primitive != null && primitive.isPrimitive()) { return getMethod(srcClass, methodName, primitive); } }
// in src/com/ziclix/python/sql/connect/Connectx.java
catch (IllegalAccessException ex) { }
// in src/com/ziclix/python/sql/connect/Lookup.java
catch (IllegalAccessException e) { throw zxJDBC.makeException(zxJDBC.ProgrammingError, e); }
// in src/org/python/core/PyReflectedField.java
catch (IllegalAccessException exc) { throw Py.JavaError(exc); }
// in src/org/python/core/PyReflectedField.java
catch (IllegalAccessException exc) { throw Py.JavaError(exc); }
// in src/org/python/core/PyJavaType.java
catch (IllegalAccessException e) { throw Py.JavaError(e); }
// in src/org/python/core/imp.java
catch (IllegalAccessException e) { throw Py.JavaError(e); }
6
            
// in src/com/ziclix/python/sql/connect/Connectx.java
catch (IllegalAccessException e) { throw zxJDBC.makeException("illegal access for " + exceptionMsg); }
// in src/com/ziclix/python/sql/connect/Lookup.java
catch (IllegalAccessException e) { throw zxJDBC.makeException(zxJDBC.ProgrammingError, e); }
// in src/org/python/core/PyReflectedField.java
catch (IllegalAccessException exc) { throw Py.JavaError(exc); }
// in src/org/python/core/PyReflectedField.java
catch (IllegalAccessException exc) { throw Py.JavaError(exc); }
// in src/org/python/core/PyJavaType.java
catch (IllegalAccessException e) { throw Py.JavaError(e); }
// in src/org/python/core/imp.java
catch (IllegalAccessException e) { throw Py.JavaError(e); }
(Lib) FileNotFoundException 6
            
// in src/org/python/modules/posix/PosixModule.java
catch (FileNotFoundException fnfe) { throw Py.OSError(file.isDirectory() ? Errno.EISDIR : Errno.ENOENT, path); }
// in src/org/python/core/SyspathJavaLoader.java
catch (FileNotFoundException e) { return null; }
// in src/org/python/core/io/FileIO.java
catch (FileNotFoundException fnfe) { if (absPath.isDirectory()) { throw Py.IOError(Errno.EISDIR, name); } if ((writing && !absPath.canWrite()) || fnfe.getMessage().endsWith("(Permission denied)")) { throw Py.IOError(Errno.EACCES, name); } throw Py.IOError(Errno.ENOENT, name); }
// in src/org/python/core/__builtin__.java
catch (FileNotFoundException e) { throw Py.IOError(e); }
// in src/org/python/util/JLineConsole.java
catch (FileNotFoundException fnfe) { // Shouldn't really ever happen fnfe.printStackTrace(); }
// in src/org/python/util/jython.java
catch (FileNotFoundException e) { throw Py.IOError(e); }
6
            
// in src/org/python/modules/posix/PosixModule.java
catch (FileNotFoundException fnfe) { throw Py.OSError(file.isDirectory() ? Errno.EISDIR : Errno.ENOENT, path); }
// in src/org/python/core/io/FileIO.java
catch (FileNotFoundException fnfe) { if (absPath.isDirectory()) { throw Py.IOError(Errno.EISDIR, name); } if ((writing && !absPath.canWrite()) || fnfe.getMessage().endsWith("(Permission denied)")) { throw Py.IOError(Errno.EACCES, name); } throw Py.IOError(Errno.ENOENT, name); }
// in src/org/python/core/__builtin__.java
catch (FileNotFoundException e) { throw Py.IOError(e); }
// in src/org/python/util/jython.java
catch (FileNotFoundException e) { throw Py.IOError(e); }
(Lib) EOFException 5
            
// in src/org/python/core/PyArray.java
catch(EOFException e) { // stubbed catch for fromStream throws throw Py.EOFError("not enough items in string"); }
// in src/org/python/core/packagecache/PackageManager.java
catch (EOFException eof) { //Empty or 1 byte file. return -1; }
// in src/org/python/core/packagecache/CachedJarsPackageManager.java
catch (EOFException eof) { ; }
// in src/org/python/core/packagecache/CachedJarsPackageManager.java
catch (EOFException eof) { ; }
// in src/org/python/util/ReadlineConsole.java
catch(EOFException eofe) { throw new PyException(Py.EOFError); }
2
            
// in src/org/python/core/PyArray.java
catch(EOFException e) { // stubbed catch for fromStream throws throw Py.EOFError("not enough items in string"); }
// in src/org/python/util/ReadlineConsole.java
catch(EOFException eofe) { throw new PyException(Py.EOFError); }
(Lib) InterruptedException 5
            
// in src/com/ziclix/python/sql/pipe/Pipe.java
catch (InterruptedException e) { queue.close(); throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/pipe/Pipe.java
catch (InterruptedException e) { queue.close(); throw zxJDBC.makeException(e); }
// in src/org/python/modules/_weakref/GlobalRef.java
catch (InterruptedException exc) { // ok }
// in src/org/python/modules/thread/PyLock.java
catch (InterruptedException e) { System.err.println("Interrupted thread"); }
// in src/org/python/modules/time/Time.java
catch (java.lang.InterruptedException e) { throw new PyException(Py.KeyboardInterrupt, "interrupted sleep"); }
3
            
// in src/com/ziclix/python/sql/pipe/Pipe.java
catch (InterruptedException e) { queue.close(); throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/pipe/Pipe.java
catch (InterruptedException e) { queue.close(); throw zxJDBC.makeException(e); }
// in src/org/python/modules/time/Time.java
catch (java.lang.InterruptedException e) { throw new PyException(Py.KeyboardInterrupt, "interrupted sleep"); }
(Lib) StringIndexOutOfBoundsException 5
            
// in src/org/python/indexer/demos/Styler.java
catch (StringIndexOutOfBoundsException sx) { System.out.println("whoops: beg=" + a + ", end=" + b + ", len=" + source.length()); return ""; }
// in src/org/python/modules/_marshal.java
catch (StringIndexOutOfBoundsException e) { // convert from our PyIOFile abstraction to what marshal in CPython returns // (although it's really just looking for no bombing) throw Py.EOFError("EOF read where object expected"); }
// in src/org/python/core/PyString.java
catch (StringIndexOutOfBoundsException exc) { throw Py.ValueError("invalid literal for int() with base " + base + ": " + getString()); }
// in src/org/python/core/PyString.java
catch (StringIndexOutOfBoundsException exc) { throw Py.ValueError("invalid literal for long() with base " + base + ": " + getString()); }
// in src/org/python/core/PyString.java
catch (StringIndexOutOfBoundsException e) { throw Py.ValueError("incomplete format"); }
4
            
// in src/org/python/modules/_marshal.java
catch (StringIndexOutOfBoundsException e) { // convert from our PyIOFile abstraction to what marshal in CPython returns // (although it's really just looking for no bombing) throw Py.EOFError("EOF read where object expected"); }
// in src/org/python/core/PyString.java
catch (StringIndexOutOfBoundsException exc) { throw Py.ValueError("invalid literal for int() with base " + base + ": " + getString()); }
// in src/org/python/core/PyString.java
catch (StringIndexOutOfBoundsException exc) { throw Py.ValueError("invalid literal for long() with base " + base + ": " + getString()); }
// in src/org/python/core/PyString.java
catch (StringIndexOutOfBoundsException e) { throw Py.ValueError("incomplete format"); }
(Lib) NoSuchMethodException 4
            
// in src/com/ziclix/python/sql/connect/Connectx.java
catch (NoSuchMethodException e) { Class<?> primitive = null; try { Field f = valueClass.getField("TYPE"); primitive = (Class<?>) f.get(valueClass); } catch (NoSuchFieldException ex) { } catch (IllegalAccessException ex) { } catch (ClassCastException ex) { } if (primitive != null && primitive.isPrimitive()) { return getMethod(srcClass, methodName, primitive); } }
// in src/org/python/compiler/ProxyMaker.java
catch (NoSuchMethodException e) { // OK, no one else defines it, so we need to }
// in src/org/python/core/PyJavaType.java
catch (NoSuchMethodException e) { return null; }
// in src/org/python/core/Py.java
catch (NoSuchMethodException e) { throw Py.JavaError(e); }
1
            
// in src/org/python/core/Py.java
catch (NoSuchMethodException e) { throw Py.JavaError(e); }
(Lib) RuntimeException 4
            
// in src/org/python/indexer/demos/StyleApplier.java
catch (RuntimeException x) { System.err.println("Warning: " + x); }
// in src/org/python/core/BytecodeLoader.java
catch (RuntimeException re) { // Probably an invalid .class, fallback to the // specified name }
// in src/org/python/core/imp.java
catch (RuntimeException t) { removeModule(name); throw t; }
// in src/org/python/util/ReadlineConsole.java
catch(RuntimeException e) { // Silently ignore errors during load of the native library. // Will use a pure java fallback. }
1
            
// in src/org/python/core/imp.java
catch (RuntimeException t) { removeModule(name); throw t; }
(Lib) AbstractMethodError 3
            
// in src/com/ziclix/python/sql/Fetch.java
catch (AbstractMethodError e) { throw zxJDBC.makeException(zxJDBC.NotSupportedError, zxJDBC.getString("nodynamiccursors")); }
// in src/com/ziclix/python/sql/Fetch.java
catch (AbstractMethodError e) { throw zxJDBC.makeException(zxJDBC.NotSupportedError, zxJDBC.getString("nodynamiccursors")); }
// in src/com/ziclix/python/sql/PyCursor.java
catch (AbstractMethodError e) { throw zxJDBC.makeException(zxJDBC.NotSupportedError, zxJDBC.getString("nodynamiccursors")); }
3
            
// in src/com/ziclix/python/sql/Fetch.java
catch (AbstractMethodError e) { throw zxJDBC.makeException(zxJDBC.NotSupportedError, zxJDBC.getString("nodynamiccursors")); }
// in src/com/ziclix/python/sql/Fetch.java
catch (AbstractMethodError e) { throw zxJDBC.makeException(zxJDBC.NotSupportedError, zxJDBC.getString("nodynamiccursors")); }
// in src/com/ziclix/python/sql/PyCursor.java
catch (AbstractMethodError e) { throw zxJDBC.makeException(zxJDBC.NotSupportedError, zxJDBC.getString("nodynamiccursors")); }
(Lib) ArrayIndexOutOfBoundsException 3
            
// in src/org/python/modules/time/Time.java
catch (ArrayIndexOutOfBoundsException e) { throw new PyException(Py.ValueError, new PyString("day of week out of range (0-6)")); }
// in src/org/python/modules/time/Time.java
catch (ArrayIndexOutOfBoundsException e) { throw new PyException(Py.ValueError, new PyString("month out of range (1-12)")); }
// in src/org/python/core/AnnotationReader.java
catch (ArrayIndexOutOfBoundsException e) { IOException ioe = new IOException("Malformed bytecode: not enough data"); ioe.initCause(e);// IOException didn't grow a constructor that could take a cause till // 1.6, so do it the old fashioned way throw ioe; }
3
            
// in src/org/python/modules/time/Time.java
catch (ArrayIndexOutOfBoundsException e) { throw new PyException(Py.ValueError, new PyString("day of week out of range (0-6)")); }
// in src/org/python/modules/time/Time.java
catch (ArrayIndexOutOfBoundsException e) { throw new PyException(Py.ValueError, new PyString("month out of range (1-12)")); }
// in src/org/python/core/AnnotationReader.java
catch (ArrayIndexOutOfBoundsException e) { IOException ioe = new IOException("Malformed bytecode: not enough data"); ioe.initCause(e);// IOException didn't grow a constructor that could take a cause till // 1.6, so do it the old fashioned way throw ioe; }
(Lib) CloneNotSupportedException 3
            
// in src/org/python/modules/_hashlib.java
catch (CloneNotSupportedException cnse) { throw Py.RuntimeError(String.format("_hashlib.HASH (%s) internal error", name)); }
// in src/org/python/core/PyBuiltinMethodSet.java
catch (CloneNotSupportedException e) { throw new RuntimeException("Didn't expect PyBuiltinMethodSet to throw " + "CloneNotSupported since it implements Cloneable", e); }
// in src/org/python/core/PyBuiltinMethod.java
catch(CloneNotSupportedException e) { throw new RuntimeException("Didn't expect PyBuiltinMethodto throw " + "CloneNotSupported since it implements Cloneable", e); }
3
            
// in src/org/python/modules/_hashlib.java
catch (CloneNotSupportedException cnse) { throw Py.RuntimeError(String.format("_hashlib.HASH (%s) internal error", name)); }
// in src/org/python/core/PyBuiltinMethodSet.java
catch (CloneNotSupportedException e) { throw new RuntimeException("Didn't expect PyBuiltinMethodSet to throw " + "CloneNotSupported since it implements Cloneable", e); }
// in src/org/python/core/PyBuiltinMethod.java
catch(CloneNotSupportedException e) { throw new RuntimeException("Didn't expect PyBuiltinMethodto throw " + "CloneNotSupported since it implements Cloneable", e); }
(Lib) MissingResourceException 3
            
// in src/com/ziclix/python/sql/zxJDBC.java
catch (MissingResourceException e) { throw new RuntimeException("missing zxjdbc resource bundle"); }
// in src/com/ziclix/python/sql/zxJDBC.java
catch (MissingResourceException e) { break; }
// in src/com/ziclix/python/sql/zxJDBC.java
catch (MissingResourceException e) { return key; }
1
            
// in src/com/ziclix/python/sql/zxJDBC.java
catch (MissingResourceException e) { throw new RuntimeException("missing zxjdbc resource bundle"); }
(Lib) NoSuchFieldException 3
            
// in src/com/ziclix/python/sql/connect/Connectx.java
catch (NoSuchMethodException e) { Class<?> primitive = null; try { Field f = valueClass.getField("TYPE"); primitive = (Class<?>) f.get(valueClass); } catch (NoSuchFieldException ex) { } catch (IllegalAccessException ex) { } catch (ClassCastException ex) { } if (primitive != null && primitive.isPrimitive()) { return getMethod(srcClass, methodName, primitive); } }
// in src/com/ziclix/python/sql/connect/Connectx.java
catch (NoSuchFieldException ex) { }
// in src/com/ziclix/python/sql/connect/Lookup.java
catch (NoSuchFieldException e) { fieldname = keyword; }
// in src/org/python/core/PyBeanEventProperty.java
catch (NoSuchFieldException exc) { throw Py.AttributeError("Internal bean event error: " + __name__); }
1
            
// in src/org/python/core/PyBeanEventProperty.java
catch (NoSuchFieldException exc) { throw Py.AttributeError("Internal bean event error: " + __name__); }
(Lib) RecognitionException 3
            
// in src/org/python/antlr/BaseParser.java
catch (RecognitionException e) { //XXX: this can't happen. Need to strip the throws from antlr // generated code. }
// in src/org/python/antlr/BaseParser.java
catch (RecognitionException e) { //I am only throwing ParseExceptions, but "throws RecognitionException" still gets //into the generated code. System.err.println("FIXME: pretty sure this can't happen -- but needs to be checked"); }
// in src/org/python/antlr/BaseParser.java
catch (RecognitionException e) { //XXX: this can't happen. Need to strip the throws from antlr // generated code. }
0
(Lib) AccessControlException 2
            
// in src/org/python/core/PySystemState.java
catch (AccessControlException ace) { return new Properties(); }
// in src/org/python/core/packagecache/CachedJarsPackageManager.java
catch(AccessControlException ace) { warning("The java security manager isn't allowing access to the package cache dir, '" + aCachedir1 + "'"); return false; }
0
(Lib) InstantiationException 2
            
// in src/org/python/core/PyObject.java
catch (java.lang.InstantiationException e) { Class<?> sup = c.getSuperclass(); String msg = "Default constructor failed for Java superclass"; if (sup != null) { msg += " " + sup.getName(); } throw Py.TypeError(msg); }
// in src/org/python/core/imp.java
catch (InstantiationException e) { throw Py.JavaError(e); }
2
            
// in src/org/python/core/PyObject.java
catch (java.lang.InstantiationException e) { Class<?> sup = c.getSuperclass(); String msg = "Default constructor failed for Java superclass"; if (sup != null) { msg += " " + sup.getName(); } throw Py.TypeError(msg); }
// in src/org/python/core/imp.java
catch (InstantiationException e) { throw Py.JavaError(e); }
(Lib) InvocationTargetException 2
            
// in src/com/ziclix/python/sql/connect/Connectx.java
catch (InvocationTargetException e) { throw zxJDBC.makeException("invocation target exception for " + exceptionMsg); }
// in src/org/python/core/PyReflectedConstructor.java
catch (InvocationTargetException e) { if (e.getTargetException() instanceof InstantiationException) { Class<?> sup = proxy.getSuperclass(); String msg = "Constructor failed for Java superclass"; if (sup != null) { msg += " " + sup.getName(); } throw Py.TypeError(msg); } else throw Py.JavaError(e); }
3
            
// in src/com/ziclix/python/sql/connect/Connectx.java
catch (InvocationTargetException e) { throw zxJDBC.makeException("invocation target exception for " + exceptionMsg); }
// in src/org/python/core/PyReflectedConstructor.java
catch (InvocationTargetException e) { if (e.getTargetException() instanceof InstantiationException) { Class<?> sup = proxy.getSuperclass(); String msg = "Constructor failed for Java superclass"; if (sup != null) { msg += " " + sup.getName(); } throw Py.TypeError(msg); } else throw Py.JavaError(e); }
(Lib) MalformedURLException 2
            
// in src/org/python/core/SyspathJavaLoader.java
catch (MalformedURLException e) { throw new RuntimeException(e); }
// in src/org/python/core/SyspathJavaLoader.java
catch (MalformedURLException e) { throw new RuntimeException(e); }
2
            
// in src/org/python/core/SyspathJavaLoader.java
catch (MalformedURLException e) { throw new RuntimeException(e); }
// in src/org/python/core/SyspathJavaLoader.java
catch (MalformedURLException e) { throw new RuntimeException(e); }
(Lib) NamingException 2
            
// in src/com/ziclix/python/sql/connect/Lookup.java
catch (NamingException e) { throw zxJDBC.makeException(zxJDBC.DatabaseError, e); }
// in src/com/ziclix/python/sql/connect/Lookup.java
catch (NamingException e) { // ok }
1
            
// in src/com/ziclix/python/sql/connect/Lookup.java
catch (NamingException e) { throw zxJDBC.makeException(zxJDBC.DatabaseError, e); }
(Lib) NoClassDefFoundError 2
            
// in src/org/python/core/Py.java
catch (NoClassDefFoundError e) { // e.printStackTrace(); return null; }
// in src/org/python/core/imp.java
catch (NoClassDefFoundError e) { throw Py.ImportError("Cannot import " + name + ", missing class " + c.getName()); }
1
            
// in src/org/python/core/imp.java
catch (NoClassDefFoundError e) { throw Py.ImportError("Cannot import " + name + ", missing class " + c.getName()); }
(Domain) ParseException 2
            
// in src/org/python/compiler/Future.java
catch (ParseException pe) { throw new ParseException(pe.getMessage(), cand); }
// in src/org/python/modules/time/Time.java
catch (ParseException e) { throwValueError("time data did not match format: data=" + data_string + " fmt=" + format); }
1
            
// in src/org/python/compiler/Future.java
catch (ParseException pe) { throw new ParseException(pe.getMessage(), cand); }
(Lib) StackOverflowError 2
            
// in src/org/python/indexer/Indexer.java
catch (StackOverflowError soe) { handleException("Error loading " + path, soe); return null; }
// in src/org/python/indexer/ast/NNode.java
catch (StackOverflowError soe) { String msg = "Unable to resolve: " + n + " in " + n.getFile() + " (stack overflow)"; Indexer.idx.warn(msg); return handleExceptionInResolve(n, soe); }
0
(Lib) UnsupportedCharsetException 2
            
// in src/org/python/core/PySystemState.java
catch (UnsupportedCharsetException e) { Py.writeWarning("initializer", "Unable to load the UTF-8 charset to read an initializer definition"); e.printStackTrace(System.err); }
// in src/org/python/core/ParserFacade.java
catch (UnsupportedCharsetException exc) { throw new PySyntaxError("Unknown encoding: " + encoding, 1, 0, "", filename); }
1
            
// in src/org/python/core/ParserFacade.java
catch (UnsupportedCharsetException exc) { throw new PySyntaxError("Unknown encoding: " + encoding, 1, 0, "", filename); }
(Lib) ArrayStoreException 1
            
// in src/org/python/core/AbstractArray.java
catch (ArrayStoreException e) { throw new IllegalArgumentException("'ofArrayType' must be compatible with existing array type of " + getArray().getClass().getName() + "\tsee java.lang.Class.getName()."); }
1
            
// in src/org/python/core/AbstractArray.java
catch (ArrayStoreException e) { throw new IllegalArgumentException("'ofArrayType' must be compatible with existing array type of " + getArray().getClass().getName() + "\tsee java.lang.Class.getName()."); }
(Lib) BufferOverflowException 1
            
// in src/org/python/core/io/LineBufferedWriter.java
catch (BufferOverflowException boe) { // buffer is full; we *must* flush flush(); buffer.put(next); }
0
(Lib) ClosedChannelException 1
            
// in src/org/python/modules/posix/PosixModule.java
catch (ClosedChannelException cce) { // In the rare case it's closed but the rawIO wasn't throw Py.ValueError("I/O operation on closed file"); }
1
            
// in src/org/python/modules/posix/PosixModule.java
catch (ClosedChannelException cce) { // In the rare case it's closed but the rawIO wasn't throw Py.ValueError("I/O operation on closed file"); }
(Lib) ConcurrentModificationException 1
            
// in src/org/python/core/PyList.java
catch (ConcurrentModificationException ex) { throw Py.ValueError(message); }
1
            
// in src/org/python/core/PyList.java
catch (ConcurrentModificationException ex) { throw Py.ValueError(message); }
(Domain) ConversionException 1
            
// in src/org/python/core/PyObject.java
catch(PyObject.ConversionException e) { throw Py.TypeError("attribute name must be a string"); }
1
            
// in src/org/python/core/PyObject.java
catch(PyObject.ConversionException e) { throw Py.TypeError("attribute name must be a string"); }
(Lib) ExceptionInInitializerError 1
            
// in src/org/python/core/PyType.java
catch (ExceptionInInitializerError e) { throw Py.JavaError(e); }
1
            
// in src/org/python/core/PyType.java
catch (ExceptionInInitializerError e) { throw Py.JavaError(e); }
(Lib) IllegalMonitorStateException 1
            
// in src/org/python/modules/imp.java
catch(IllegalMonitorStateException e){ throw Py.RuntimeError("not holding the import lock"); }
1
            
// in src/org/python/modules/imp.java
catch(IllegalMonitorStateException e){ throw Py.RuntimeError("not holding the import lock"); }
(Lib) IllegalStateException 1
            
// in src/org/python/core/PySystemState.java
catch (IllegalStateException e) { // JVM is already shutting down, so we cannot remove this shutdown hook anyway }
0
(Lib) IndexOutOfBoundsException 1
            
// in src/org/python/core/PyString.java
catch (IndexOutOfBoundsException e) { throw Py.TypeError( "translate() only works for 8-bit character strings"); }
1
            
// in src/org/python/core/PyString.java
catch (IndexOutOfBoundsException e) { throw Py.TypeError( "translate() only works for 8-bit character strings"); }
(Domain) IndexingException 1
            
// in src/org/python/indexer/ast/NNode.java
catch (IndexingException ix) { throw ix; }
1
            
// in src/org/python/indexer/ast/NNode.java
catch (IndexingException ix) { throw ix; }
(Domain) InvalidExposingException 1
            
// in src/org/python/expose/generate/ExposeTask.java
catch (InvalidExposingException iee) { throw new BuildException(iee.getMessage()); }
1
            
// in src/org/python/expose/generate/ExposeTask.java
catch (InvalidExposingException iee) { throw new BuildException(iee.getMessage()); }
(Lib) LinkageError 1
            
// in src/org/python/core/Py.java
catch (LinkageError e) { throw JavaError(e); }
1
            
// in src/org/python/core/Py.java
catch (LinkageError e) { throw JavaError(e); }
(Lib) NoSuchAlgorithmException 1
            
// in src/org/python/modules/_hashlib.java
catch (NoSuchAlgorithmException nsae) { throw Py.ValueError("unsupported hash type"); }
1
            
// in src/org/python/modules/_hashlib.java
catch (NoSuchAlgorithmException nsae) { throw Py.ValueError("unsupported hash type"); }
(Lib) NoSuchElementException 1
            
// in src/org/python/core/PySet.java
catch (NoSuchElementException e) { throw new PyException(Py.KeyError, "pop from an empty set"); }
1
            
// in src/org/python/core/PySet.java
catch (NoSuchElementException e) { throw new PyException(Py.KeyError, "pop from an empty set"); }
(Lib) NoSuchMethodError 1
            
// in src/org/python/core/PyObject.java
catch (NoSuchMethodError nsme) { throw Py.TypeError("constructor requires arguments"); }
1
            
// in src/org/python/core/PyObject.java
catch (NoSuchMethodError nsme) { throw Py.TypeError("constructor requires arguments"); }
(Lib) OutOfMemoryError 1
            
// in src/org/python/indexer/Indexer.java
catch (OutOfMemoryError e) { if (astCache != null) { astCache.clear(); } System.gc(); return null; }
0
(Domain) QueueClosedException 1
            
// in src/com/ziclix/python/sql/pipe/Pipe.java
catch (QueueClosedException e) { /* * thrown by a closed queue when any operation is performed. we know * at this point that nothing else can happen to the queue and that * both producer and consumer will stop since one closed the queue * by throwing an exception (below) and the other is here. */ return; }
0
(Domain) StopIterationException 1
            
// in src/org/python/indexer/ast/NNode.java
catch (NNodeVisitor.StopIterationException six) { // expected }
0
(Lib) UnsupportedEncodingException 1
            
// in src/org/python/core/util/StringUtil.java
catch(UnsupportedEncodingException uee) { // This JVM is whacked, it doesn't even have iso-8859-1 throw Py.SystemError("Java couldn't find the ISO-8859-1 encoding"); }
1
            
// in src/org/python/core/util/StringUtil.java
catch(UnsupportedEncodingException uee) { // This JVM is whacked, it doesn't even have iso-8859-1 throw Py.SystemError("Java couldn't find the ISO-8859-1 encoding"); }
(Lib) UnsupportedOperationException 1
            
// in src/org/python/util/ReadlineConsole.java
catch (UnsupportedOperationException uoe) { // parseAndBind not supported by this readline }
0

Exception Recast Summary

There is a common practice of throwing exceptions from within a catch block (e.g. for wrapping a low-level exception). The following table summarizes the usage of this practice in the application. The last column gives the number of times it happens for a pair of exceptions. The graph below the table graphically renders the same information. For a given node, its color represents its origin (blue means library exception, orange means domain exception); the left-most number is the number of times it is thrown, the right-most is the number of times it is caught.

Catch Throw
(Lib) Throwable
Unknown
31
                    
// in src/com/ziclix/python/sql/Fetch.java
catch (Throwable e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/Fetch.java
catch (Throwable e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/Fetch.java
catch (Throwable e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/Fetch.java
catch (Throwable e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/Fetch.java
catch (Throwable t) { throw zxJDBC.makeException(t); }
// in src/com/ziclix/python/sql/zxJDBC.java
catch (Throwable t) { throw makeException(t); }
// in src/com/ziclix/python/sql/DataHandler.java
catch (Throwable t) { SQLException cause = null; SQLException ex = new SQLException("error setting index [" + index + "], coltype [" + colType + "], datatype [" + dataType + "], datatypename [" + dataTypeName + "]"); if (t instanceof SQLException) { cause = (SQLException)t; } else { cause = new SQLException(t.getMessage()); } ex.setNextException(cause); throw ex; }
// in src/com/ziclix/python/sql/Jython22DataHandler.java
catch (Throwable t) { SQLException cause = null; SQLException ex = new SQLException("error setting index [" + index + "], coltype [" + colType + "], datatype [" + dataType + "], datatypename [" + dataTypeName + "]"); if (t instanceof SQLException) { cause = (SQLException)t; } else { cause = new SQLException(t.getMessage()); } ex.setNextException(cause); throw ex; }
// in src/com/ziclix/python/sql/connect/Connect.java
catch (Throwable e) { throw zxJDBC.makeException(zxJDBC.DatabaseError, "driver [" + driver + "] not found"); }
// in src/com/ziclix/python/sql/PyCursor.java
catch (Throwable e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyCursor.java
catch (Throwable t) { if (statement != null) { statement.close(); } throw zxJDBC.makeException(t); }
// in src/com/ziclix/python/sql/PyCursor.java
catch (Throwable t) { if (statement != null && !(sql instanceof PyStatement)) { // only close static, single-use statements statement.close(); } throw zxJDBC.makeException(zxJDBC.Error, t, rowIndex); }
// in src/com/ziclix/python/sql/PyCursor.java
catch (Throwable e) { throw zxJDBC.makeException(e); }
// in src/org/python/compiler/ScopesCompiler.java
catch (Throwable t) { throw ParserFacade.fixParseError(null, t, code_compiler.getFilename()); }
// in src/org/python/core/PyBeanProperty.java
catch (Throwable t) { throw Py.JavaError(t); }
// in src/org/python/core/PyReflectedConstructor.java
catch (Throwable t) { throw Py.JavaError(t); }
// in src/org/python/core/PyReflectedConstructor.java
catch (Throwable t) { throw Py.JavaError(t); }
// in src/org/python/core/PyTableCode.java
catch (Throwable t) { // Convert exceptions that occured in Java code to PyExceptions PyException pye = Py.JavaError(t); pye.tracebackHere(frame); frame.f_lasti = -1; if (frame.tracefunc != null) { frame.tracefunc.traceException(frame, pye); } if (ts.profilefunc != null) { ts.profilefunc.traceException(frame, pye); } // Rethrow the exception to the next stack frame ts.exception = previous_exception; ts.frame = ts.frame.f_back; throw pye; }
// in src/org/python/core/PyReflectedFunction.java
catch (Throwable t) { throw Py.JavaError(t); }
// in src/org/python/core/PyBaseCode.java
catch (Throwable t) { // Convert exceptions that occured in Java code to PyExceptions PyException pye = Py.JavaError(t); pye.tracebackHere(frame); frame.f_lasti = -1; if (frame.tracefunc != null) { frame.tracefunc.traceException(frame, pye); } if (ts.profilefunc != null) { ts.profilefunc.traceException(frame, pye); } // Rethrow the exception to the next stack frame ts.exception = previous_exception; ts.frame = ts.frame.f_back; throw pye; }
// in src/org/python/core/exceptions.java
catch (Throwable t) { throw Py.JavaError(t); }
// in src/org/python/core/CompilerFacade.java
catch (Throwable t) { throw ParserFacade.fixParseError(null, t, filename); }
// in src/org/python/core/Py.java
catch (Throwable t) { throw Py.JavaError(t); }
// in src/org/python/core/ParserFacade.java
catch (Throwable t) { if (bufReader == null) throw Py.JavaError(t); // can't do any more try { // then, try parsing as a module bufReader.reset(); return parse(bufReader, CompileMode.exec, filename, cflags); } catch (Throwable tt) { throw fixParseError(bufReader, tt, filename); } }
// in src/org/python/core/ParserFacade.java
catch (Throwable tt) { throw fixParseError(bufReader, tt, filename); }
// in src/org/python/core/ParserFacade.java
catch (Throwable t) { throw fixParseError(bufReader, t, filename); }
// in src/org/python/core/ParserFacade.java
catch (Throwable t) { throw fixParseError(bufReader, t, filename); }
// in src/org/python/core/ParserFacade.java
catch (Throwable t) { throw fixParseError(bufReader, t, filename); }
// in src/org/python/core/ParserFacade.java
catch (Throwable t) { PyException p = fixParseError(reader, t, filename); if (reader != null && validPartialSentence(reader, kind, filename)) { return null; } throw p; }
// in src/org/python/core/imp.java
catch (Throwable t) { if (testing) { return null; } else { throw Py.JavaError(t); } }
// in src/org/python/core/imp.java
catch(Throwable t) { throw ParserFacade.fixParseError(null, t, filename); }
(Lib) SQLException
Unknown
33
                    
// in src/com/ziclix/python/sql/Fetch.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyConnection.java
catch (SQLException e) { throw zxJDBC.makeException(zxJDBC.DatabaseError, e); }
// in src/com/ziclix/python/sql/PyConnection.java
catch (SQLException e) { throw zxJDBC.makeException(zxJDBC.DatabaseError, e); }
// in src/com/ziclix/python/sql/PyConnection.java
catch (SQLException e) { throw zxJDBC.makeException(zxJDBC.DatabaseError, e); }
// in src/com/ziclix/python/sql/PyConnection.java
catch (SQLException e) { throw zxJDBC.makeException(zxJDBC.DatabaseError, e); }
// in src/com/ziclix/python/sql/PyConnection.java
catch (SQLException e) { throw zxJDBC.makeException(zxJDBC.DatabaseError, e); }
// in src/com/ziclix/python/sql/PyConnection.java
catch (SQLException e) { throw zxJDBC.makeException(zxJDBC.DatabaseError, e); }
// in src/com/ziclix/python/sql/PyConnection.java
catch (SQLException e) { throw zxJDBC.makeException(zxJDBC.DatabaseError, e); }
// in src/com/ziclix/python/sql/PyConnection.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyConnection.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyConnection.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyConnection.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyExtendedCursor.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyExtendedCursor.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyExtendedCursor.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyExtendedCursor.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyExtendedCursor.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyExtendedCursor.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyExtendedCursor.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyExtendedCursor.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyExtendedCursor.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyExtendedCursor.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyExtendedCursor.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/connect/Connectx.java
catch (SQLException e) { throw zxJDBC.makeException(zxJDBC.DatabaseError, e); }
// in src/com/ziclix/python/sql/connect/Connectx.java
catch (SQLException e) { throw zxJDBC.makeException(zxJDBC.DatabaseError, e); }
// in src/com/ziclix/python/sql/connect/Connect.java
catch (SQLException e) { throw zxJDBC.makeException(zxJDBC.DatabaseError, e); }
// in src/com/ziclix/python/sql/connect/Connect.java
catch (SQLException e) { throw zxJDBC.makeException(zxJDBC.DatabaseError, e); }
// in src/com/ziclix/python/sql/connect/Lookup.java
catch (SQLException e) { throw zxJDBC.makeException(zxJDBC.DatabaseError, e); }
// in src/com/ziclix/python/sql/connect/Lookup.java
catch (SQLException e) { throw zxJDBC.makeException(zxJDBC.DatabaseError, e); }
// in src/com/ziclix/python/sql/PyStatement.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyStatement.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/Procedure.java
catch (SQLException e) { if (statement != null) { try { statement.close(); } catch (Exception ex) { } } throw e; }
// in src/com/ziclix/python/sql/PyCursor.java
catch (SQLException sqle) { throw zxJDBC.makeException(sqle); }
(Domain) PyException
(Lib) ServletException
(Domain) PyException
(Lib) BuildException
Unknown
5
                    
// in src/com/xhaus/modjy/ModjyJServlet.java
catch (PyException ix) { throw new ServletException("Unable to import '" + MODJY_PYTHON_CLASSNAME + "': maybe you need to set the '" + PYTHON_HOME_PARAM + "' parameter?", ix); }
// in src/com/xhaus/modjy/ModjyJServlet.java
catch (PyException pyx) { throw new ServletException("Exception creating modjy servlet: " + pyx.toString(), pyx); }
// in src/org/python/util/PyFilter.java
catch (PyException e) { throw new ServletException(e); }
// in src/org/python/util/PyServlet.java
catch (PyException e) { throw new ServletException(e); }
// in src/org/python/util/PyServlet.java
catch (PyException e) { throw new ServletException(e); }
2
                    
// in src/org/python/core/PyArray.java
catch (PyException e) { delegate.setSize(afterLast); throw new PyException(e.type, e.value); }
// in src/org/python/core/PyArray.java
catch(PyException e) { // trap any exception - any error invalidates the whole list delegate.setSize(size); // re-throw throw new PyException(e.type, e.value); }
1
                    
// in src/org/python/util/JycompileAntTask.java
catch (PyException pye) { pye.printStackTrace(); throw new BuildException("Compile failed; see the compiler error output for details."); }
470
                    
// in src/com/ziclix/python/sql/Fetch.java
catch (PyException e) { throw e; }
// in src/com/ziclix/python/sql/Fetch.java
catch (PyException e) { throw e; }
// in src/com/ziclix/python/sql/Fetch.java
catch (PyException e) { throw e; }
// in src/com/ziclix/python/sql/Fetch.java
catch (PyException e) { throw e; }
// in src/com/ziclix/python/sql/PyStatement.java
catch (PyException e) { throw zxJDBC.makeException(zxJDBC.ProgrammingError, zxJDBC.getString("bindingValue")); }
// in src/com/ziclix/python/sql/PyCursor.java
catch (PyException e) { throw e; }
// in src/com/ziclix/python/sql/PyCursor.java
catch (PyException e) { throw e; }
// in src/org/python/compiler/Module.java
catch (PyException e) { if (!e.match(Py.SyntaxWarning)) { throw e; } }
// in src/org/python/antlr/ast/aliasDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/aliasDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/aliasDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/AttributeDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/AttributeDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/AttributeDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/UnaryOpDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/UnaryOpDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/UnaryOpDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/BreakDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/BreakDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/BreakDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/BoolOpDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/BoolOpDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/BoolOpDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ListCompDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/ListCompDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ListCompDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ContinueDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/ContinueDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ContinueDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/TupleDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/TupleDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/TupleDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/InteractiveDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/InteractiveDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/InteractiveDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/DeleteDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/DeleteDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/DeleteDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/IndexDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/IndexDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/IndexDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ModuleDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/ModuleDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ModuleDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/CallDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/CallDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/CallDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ReturnDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/ReturnDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ReturnDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ForDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/ForDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ForDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ExceptHandlerDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/ExceptHandlerDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ExceptHandlerDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/SubscriptDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/SubscriptDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/SubscriptDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/DictDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/DictDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/DictDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/LambdaDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/LambdaDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/LambdaDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/GlobalDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/GlobalDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/GlobalDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ListDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/ListDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ListDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/BinOpDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/BinOpDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/BinOpDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ClassDefDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/ClassDefDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ClassDefDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ExpressionDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/ExpressionDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ExpressionDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/SliceDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/SliceDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/SliceDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/NumDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/NumDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/NumDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ExprDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/ExprDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ExprDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/NameDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/NameDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/NameDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/TryFinallyDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/TryFinallyDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/TryFinallyDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/IfExpDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/IfExpDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/IfExpDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/AugAssignDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/AugAssignDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/AugAssignDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ImportDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/ImportDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ImportDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/IfDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/IfDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/IfDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/PassDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/PassDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/PassDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/FunctionDefDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/FunctionDefDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/FunctionDefDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/argumentsDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/argumentsDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/argumentsDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/WithDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/WithDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/WithDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ImportFromDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/ImportFromDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ImportFromDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/CompareDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/CompareDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/CompareDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ReprDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/ReprDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ReprDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/StrDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/StrDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/StrDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/YieldDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/YieldDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/YieldDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/EllipsisDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/EllipsisDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/EllipsisDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/RaiseDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/RaiseDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/RaiseDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/AssignDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/AssignDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/AssignDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/GeneratorExpDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/GeneratorExpDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/GeneratorExpDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/SuiteDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/SuiteDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/SuiteDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/AssertDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/AssertDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/AssertDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/TryExceptDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/TryExceptDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/TryExceptDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ExecDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/ExecDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ExecDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/WhileDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/WhileDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/WhileDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/keywordDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/keywordDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/keywordDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/comprehensionDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/comprehensionDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/comprehensionDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ExtSliceDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/ExtSliceDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ExtSliceDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/PrintDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/PrintDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/PrintDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/PowDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/PowDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/PowDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/LtEDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/LtEDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/LtEDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/ParamDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/ParamDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/ParamDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/EqDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/EqDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/EqDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/GtDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/GtDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/GtDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/IsDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/IsDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/IsDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/GtEDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/GtEDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/GtEDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/StoreDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/StoreDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/StoreDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/BitOrDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/BitOrDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/BitOrDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/RShiftDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/RShiftDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/RShiftDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/BitAndDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/BitAndDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/BitAndDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/NotInDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/NotInDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/NotInDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/LtDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/LtDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/LtDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/FloorDivDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/FloorDivDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/FloorDivDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/USubDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/USubDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/USubDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/InvertDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/InvertDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/InvertDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/AugLoadDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/AugLoadDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/AugLoadDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/AugStoreDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/AugStoreDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/AugStoreDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/LoadDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/LoadDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/LoadDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/IsNotDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/IsNotDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/IsNotDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/BitXorDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/BitXorDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/BitXorDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/NotEqDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/NotEqDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/NotEqDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/NotDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/NotDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/NotDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/AndDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/AndDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/AndDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/ModDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/ModDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/ModDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/AddDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/AddDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/AddDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/DelDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/DelDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/DelDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/DivDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/DivDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/DivDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/LShiftDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/LShiftDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/LShiftDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/InDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/InDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/InDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/MultDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/MultDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/MultDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/UAddDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/UAddDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/UAddDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/OrDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/OrDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/OrDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/SubDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/SubDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/SubDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/jsr223/PyScriptEngine.java
catch (PyException pye) { throw scriptException(pye); }
// in src/org/python/jsr223/PyScriptEngine.java
catch (PyException pye) { throw scriptException(pye); }
// in src/org/python/jsr223/PyScriptEngine.java
catch (PyException pye) { throw scriptException(pye); }
// in src/org/python/jsr223/PyScriptEngine.java
catch (PyException pye) { throw scriptException(pye); }
// in src/org/python/jsr223/PyScriptEngine.java
catch (PyException pye) { throw scriptException(pye); }
// in src/org/python/jsr223/PyScriptEngine.java
catch (PyException pye) { throw scriptException(pye); }
// in src/org/python/modules/zipimport/zipimporterDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/modules/zipimport/zipimporterDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/modules/zipimport/zipimporterDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/modules/zipimport/zipimporter.java
catch (PyException pye) { if (!pye.match(Py.TypeError)) { throw pye; } time = -1; date = -1; }
// in src/org/python/modules/struct.java
catch (PyException ex) { throw StructError("required argument is not an integer"); }
// in src/org/python/modules/binascii.java
catch (PyException e) { if (e.match(Py.AttributeError) || e.match(Py.ValueError)) throw Py.TypeError(errMsg); throw e; }
// in src/org/python/modules/_weakref/ReferenceTypeDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/modules/_weakref/ReferenceTypeDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/modules/_weakref/ReferenceTypeDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/modules/posix/PosixModule.java
catch (PyException pye) { if (!pye.match(Py.OSError)) { throw pye; } // ENOENT result = false; }
// in src/org/python/modules/posix/PosixModule.java
catch (PyException pye) { throw badFD(); }
// in src/org/python/modules/posix/PosixModule.java
catch (PyException pye) { if (!pye.match(Py.IOError)) { throw pye; } throw Py.OSError(Errno.EINVAL); }
// in src/org/python/modules/posix/PosixModule.java
catch (PyException pye) { throw Py.IOError(Errno.EBADF); }
// in src/org/python/modules/posix/PosixModule.java
catch (PyException pye) { throw badFD(); }
// in src/org/python/modules/posix/PosixModule.java
catch (PyException pye) { throw badFD(); }
// in src/org/python/modules/posix/PosixModule.java
catch (PyException pye) { throw badFD(); }
// in src/org/python/modules/posix/PosixModule.java
catch (PyException pye) { if (!pye.match(Py.KeyError)) { throw pye; } }
// in src/org/python/modules/thread/PyLocalDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/modules/thread/PyLocalDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/modules/thread/PyLocalDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/modules/_csv/PyDialectDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/modules/_csv/PyDialectDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/modules/_csv/PyDialectDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/modules/random/PyRandomDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/modules/random/PyRandomDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/modules/random/PyRandomDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/modules/_collections/PyDequeDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/modules/_collections/PyDequeDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/modules/_collections/PyDequeDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/modules/_collections/PyDefaultDictDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/modules/_collections/PyDefaultDictDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/modules/_collections/PyDefaultDictDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/modules/_collections/PyDeque.java
catch (PyException pe) { if (pe.match(Py.KeyError)) { return null; } throw pe; }
// in src/org/python/modules/itertools.java
catch (PyException pyEx) { if (pyEx.match(Py.StopIteration)) { // store exception - will be used by PyIterator.next() stopException = pyEx; } else { throw pyEx; } }
// in src/org/python/modules/itertools.java
catch (PyException pyEx) { if (pyEx.match(Py.TypeError)) { throw Py.ValueError(msg); } else { throw pyEx; } }
// in src/org/python/modules/_functools/PyPartialDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/modules/_functools/PyPartialDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/modules/_functools/PyPartialDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/modules/time/Time.java
catch (PyException e) { // CPython's mktime raises OverflowErrors... yuck! e.type = Py.OverflowError; throw e; }
// in src/org/python/modules/PyTeeIterator.java
catch (PyException pyEx) { if (pyEx.match(Py.StopIteration)) { // store exception - will be used by PyIterator.next() stopException = pyEx; } else { throw pyEx; } }
// in src/org/python/core/PyObject.java
catch (PyException pye) { if (!pye.match(Py.AttributeError)) { throw pye; } }
// in src/org/python/core/PyObject.java
catch (PyException exc) { if (exc.match(Py.AttributeError)) { return null; } throw exc; }
// in src/org/python/core/PyObject.java
catch (PyException e) { if (e.value.getJavaProxy() != null) { Object t = e.value.__tojava__(Throwable.class); if (t != null && t != Py.NoConversion) { throw (Throwable) t; } } else { ThreadState ts = Py.getThreadState(); if (ts.frame == null) { Py.maybeSystemExit(e); } if (Options.showPythonProxyExceptions) { Py.stderr.println( "Exception in Python proxy returning to Java:"); Py.printException(e); } } throw e; }
// in src/org/python/core/PyObject.java
catch (PyException exc) { if (exc.match(Py.KeyError)) { noAttributeError(name); } else { throw exc; } }
// in src/org/python/core/PyObject.java
catch (PyException pye) { if (pye.match(Py.AttributeError)) { throw Py.TypeError("an integer is required"); } throw pye; }
// in src/org/python/core/PyObject.java
catch (PyException pye) { if (pye.match(Py.AttributeError)) { throw Py.TypeError("an integer is required"); } throw pye; }
// in src/org/python/core/PyObject.java
catch (PyException pye) { if (pye.match(Py.AttributeError)) { throw Py.TypeError("a float is required"); } throw pye; }
// in src/org/python/core/PyStringMap.java
catch(PyException pye) { if (pye.match(Py.TypeError)) { throw Py.TypeError(String.format("cannot convert dictionary update sequence " + "element #%d to a sequence", i)); } throw pye; }
// in src/org/python/core/PyList.java
catch (PyException pye) { if (!pye.match(Py.TypeError)) { throw pye; } return null; }
// in src/org/python/core/PyFloatDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyFloatDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyFloatDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyArrayDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyArrayDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyArrayDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyEnumerateDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyEnumerateDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyEnumerateDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PySystemState.java
catch (PyException pye) { // KeyError if (ret == null) { throw Py.AttributeError(name); } }
// in src/org/python/core/PyDictionary.java
catch(PyException pye) { if (pye.match(Py.TypeError)) { throw Py.TypeError(String.format("cannot convert dictionary update sequence " + "element #%d to a sequence", i)); } throw pye; }
// in src/org/python/core/PyUnicodeDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyUnicodeDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyUnicodeDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyFastSequenceIter.java
catch (PyException pye) { if (pye.match(Py.StopIteration)) { seq = null; return null; } throw pye; }
// in src/org/python/core/PyComplex.java
catch (PyException pye) { if (!pye.match(Py.AttributeError)) { // __complex__ not supported throw pye; } // otherwise try other means }
// in src/org/python/core/PyComplex.java
catch (PyException pye) { if (pye.match(Py.AttributeError)) { // __float__ not supported throw Py.TypeError("complex() argument must be a string or a number"); } throw pye; }
// in src/org/python/core/PyComplex.java
catch (PyException pye) { if (pye.match(Py.AttributeError)) { // __float__ not supported throw Py.TypeError("complex() argument must be a string or a number"); } throw pye; }
// in src/org/python/core/PyInstance.java
catch (PyException exc) { if (exc.match(Py.KeyError)) throw Py.AttributeError("class " + instclass.__name__ + " has no attribute '" + name + "'"); }
// in src/org/python/core/PyInstance.java
catch (PyException e) { if (e.match(Py.IndexError)) return null; if (e.match(Py.KeyError)) return null; throw e; }
// in src/org/python/core/PyInstance.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyInstance.java
catch (PyException pye) { if (!pye.match(Py.AttributeError)) { throw pye; } throw Py.TypeError("object cannot be interpreted as an index"); }
// in src/org/python/core/ContextGuard.java
catch(PyException e) { if (e.equals(exception)) { return false; } else { throw e; } }
// in src/org/python/core/PyFrame.java
catch (PyException pye) { if (pye.match(Py.KeyError)) { throw Py.NameError(String.format(NAME_ERROR_MSG, index)); } throw pye; }
// in src/org/python/core/PyFrame.java
catch (PyException pye) { if (pye.match(Py.KeyError)) { throw Py.NameError(String.format(GLOBAL_NAME_ERROR_MSG, index)); } throw pye; }
// in src/org/python/core/PyLongDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyLongDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyLongDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/AstList.java
catch (PyException pye) { if (!pye.match(Py.TypeError)) { throw pye; } return null; }
// in src/org/python/core/AstList.java
catch (PyException pye) { if (pye.match(Py.TypeError)) { throw Py.TypeError("can only assign an iterable"); } throw pye; }
// in src/org/python/core/PyFloat.java
catch (PyException e) { if (e.match(Py.AttributeError)) { // Translate AttributeError to TypeError // XXX: We are using the same message as CPython, even if // it is not strictly correct (instances of types // that implement the __float__ method are also // valid arguments) throw Py.TypeError("float() argument must be a string or a number"); } throw e; }
// in src/org/python/core/PySlice.java
catch (PyException pye) { if (!pye.match(Py.TypeError)) { throw pye; } }
// in src/org/python/core/PyIntegerDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyIntegerDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyIntegerDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyBaseExceptionDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyBaseExceptionDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyBaseExceptionDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/io/IOBase.java
catch (PyException pye) { if (!pye.match(Py.IOError)) { throw pye; } // If flush() fails, just give up }
// in src/org/python/core/io/BufferedIOMixin.java
catch (PyException pye) { if (!pye.match(Py.IOError)) { throw pye; } // If flush() fails, just give up }
// in src/org/python/core/PySuperDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PySuperDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PySuperDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyModuleDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyModuleDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyModuleDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/__builtin__.java
catch (PyException pye) { if (!pye.match(Py.AttributeError)) { throw pye; } attributeError = pye; }
// in src/org/python/core/__builtin__.java
catch (PyException e) { if (e.match(Py.AttributeError)) { throw Py.TypeError("vars() argument must have __dict__ attribute"); } throw e; }
// in src/org/python/core/__builtin__.java
catch (PyException e) { if (e.match(Py.StopIteration)) { return ret; } throw e; }
// in src/org/python/core/PyTypeDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyTypeDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyTypeDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PySetDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PySetDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PySetDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyType.java
catch (PyException t) { for (Iterator<Object> it = savedSubMros.iterator(); it.hasNext();) { PyType subtype = (PyType)it.next(); PyObject[] subtypeSavedMro = (PyObject[])it.next(); subtype.mro = subtypeSavedMro; } bases = savedBases; base = savedBase; mro = savedMro; throw t; }
// in src/org/python/core/PythonTraceFunction.java
catch(PyException exc) { frame.tracefunc = null; ts.tracefunc = null; ts.profilefunc = null; throw exc; }
// in src/org/python/core/PyPropertyDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyPropertyDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyPropertyDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/Py.java
catch (PyException e) { if (e.match(ImportError)) { return null; } throw e; }
// in src/org/python/core/Py.java
catch (PyException e) { Py.getSystemState().callExitFunc(); if (e.match(Py.SystemExit)) { return; } throw e; }
// in src/org/python/core/Py.java
catch (PyException pye) { if (!pye.match(TypeError)) { throw pye; } pye.value = Py.newString(String.format("Error when calling the metaclass bases\n " + "%s", pye.value.__str__().toString())); throw pye; }
// in src/org/python/core/Py.java
catch (PyException exc) { if (exc.match(Py.TypeError)) { throw Py.TypeError(message); } throw exc; }
// in src/org/python/core/PySequenceIter.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) { seq = null; return null; } throw exc; }
// in src/org/python/core/PyFileDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyFileDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyFileDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyCallIter.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) { callable = null; stopException = exc; return null; } throw exc; }
// in src/org/python/core/PyListDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyListDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyListDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyFrozenSetDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyFrozenSetDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyFrozenSetDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyDictionaryDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyDictionaryDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyDictionaryDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyBytecode.java
catch (PyException pye) { if (pye.match(Py.AttributeError)) { throw Py.ImportError(String.format("cannot import name %.230s", name)); } else { throw pye; } }
// in src/org/python/core/PyBytecode.java
catch (PyException pye) { if (!pye.match(Py.StopIteration)) { throw pye; } }
// in src/org/python/core/PyStringDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyStringDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyStringDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/codecs.java
catch (PyException exc) { if (exc.type != Py.ImportError) { throw exc; } }
// in src/org/python/core/codecs.java
catch (PyException ex) { if (ex.match(Py.LookupError)) { // If we couldn't find an encoding, see if we have a builtin if (encoding.equals("utf-8")) { return wrapDecodeResult(PyUnicode_DecodeUTF8(v.toString(), errors)); } else if(encoding.equals("utf-7")) { return wrapDecodeResult(PyUnicode_DecodeUTF7(v.toString(), errors)); } else if(encoding.equals("latin-1")) { return wrapDecodeResult(PyUnicode_DecodeLatin1(v.toString(), v.__len__(), errors)); } } throw ex; }
// in src/org/python/core/codecs.java
catch (PyException ex) { if (ex.match(Py.LookupError)) { // If we couldn't find an encoding, see if we have a builtin if (encoding.equals("utf-8")) { return PyUnicode_EncodeUTF8(v.toString(), errors); } else if(encoding.equals("utf-7")) { return codecs.PyUnicode_EncodeUTF7(v.toString(), false, false, errors); } } throw ex; }
// in src/org/python/core/PyInteger.java
catch (PyException pye) { if (pye.match(Py.OverflowError)) { return ((PyString) x).atol(base); } throw pye; }
// in src/org/python/core/PyInteger.java
catch (PyException pye) { if (!pye.match(Py.AttributeError)) { throw pye; } throw Py.TypeError("int() argument must be a string or a number"); }
// in src/org/python/core/PyObjectDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyObjectDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyObjectDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyComplexDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyComplexDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyComplexDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyLong.java
catch (PyException pye) { if (!pye.match(Py.AttributeError)) { throw pye; } throw Py.TypeError(String.format("long() argument must be a string or a number, " + "not '%.200s'", x.getType().fastGetName())); }
// in src/org/python/core/PyClassMethodDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyClassMethodDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyClassMethodDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyTupleDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyTupleDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyTupleDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyString.java
catch (PyException e) { if (e.match(Py.OverflowError)) { return atol(10); } throw e; }
// in src/org/python/core/PyString.java
catch (PyException e) { // XXX: Swallow customs AttributeError throws from __float__ methods // No better alternative for the moment if (e.match(Py.AttributeError)) { throw Py.TypeError("int argument required"); } throw e; }
// in src/org/python/core/PyString.java
catch (PyException pye) { throw !pye.match(Py.TypeError) ? pye : Py.TypeError("float argument required"); }
// in src/org/python/core/PyString.java
catch (PyException e){ if (e.match(Py.AttributeError)) { throw Py.TypeError("%c requires int or char"); } throw e; }
// in src/org/python/core/imp.java
catch (PyException pye) { // another thread may have deleted it if (!pye.match(Py.KeyError)) { throw pye; } }
// in src/org/python/core/imp.java
catch (PyException e) { if (!e.match(Py.ImportError)) { throw e; } }
// in src/org/python/core/ClasspathPyImporterDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/ClasspathPyImporterDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/ClasspathPyImporterDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyGenerator.java
catch (PyException e) { if (!(e.type == Py.StopIteration || e.type == Py.GeneratorExit)) { throw e; } }
// in src/org/python/core/PyGenerator.java
catch (PyException pye) { if (!(pye.type == Py.StopIteration || pye.type == Py.GeneratorExit)) { gi_frame = null; throw pye; } else { stopException = pye; gi_frame = null; return null; } }
// in src/org/python/core/Deriveds.java
catch (PyException pye) { if (!pye.match(Py.AttributeError)) { throw pye; } else { // saved to avoid swallowing custom AttributeErrors, and pass through to // __getattr__ firstAttributeError = pye; } }
// in src/org/python/util/InteractiveInterpreter.java
catch (PyException exc) { if (exc.match(Py.SyntaxError)) { // Case 1 showexception(exc); return false; } else if (exc.match(Py.ValueError) || exc.match(Py.OverflowError)) { // Should not print the stack trace, just the error. showexception(exc); return false; } else { throw exc; } }
// in src/org/python/util/InteractiveInterpreter.java
catch (PyException exc) { if (exc.match(Py.SystemExit)) throw exc; showexception(exc); }
// in src/org/python/util/InteractiveConsole.java
catch(PyException exc) { if(!exc.match(Py.EOFError)) throw exc; write("\n"); break; }
(Lib) AbstractMethodError
Unknown
3
                    
// in src/com/ziclix/python/sql/Fetch.java
catch (AbstractMethodError e) { throw zxJDBC.makeException(zxJDBC.NotSupportedError, zxJDBC.getString("nodynamiccursors")); }
// in src/com/ziclix/python/sql/Fetch.java
catch (AbstractMethodError e) { throw zxJDBC.makeException(zxJDBC.NotSupportedError, zxJDBC.getString("nodynamiccursors")); }
// in src/com/ziclix/python/sql/PyCursor.java
catch (AbstractMethodError e) { throw zxJDBC.makeException(zxJDBC.NotSupportedError, zxJDBC.getString("nodynamiccursors")); }
(Lib) MissingResourceException
(Lib) RuntimeException
1
                    
// in src/com/ziclix/python/sql/zxJDBC.java
catch (MissingResourceException e) { throw new RuntimeException("missing zxjdbc resource bundle"); }
(Lib) RuntimeException
Unknown
1
                    
// in src/org/python/core/imp.java
catch (RuntimeException t) { removeModule(name); throw t; }
(Domain) IndexingException
Unknown
1
                    
// in src/org/python/indexer/ast/NNode.java
catch (IndexingException ix) { throw ix; }
(Domain) InvalidExposingException
(Lib) BuildException
1
                    
// in src/org/python/expose/generate/ExposeTask.java
catch (InvalidExposingException iee) { throw new BuildException(iee.getMessage()); }
(Domain) ParseException
(Domain) ParseException
1
                    
// in src/org/python/compiler/Future.java
catch (ParseException pe) { throw new ParseException(pe.getMessage(), cand); }
(Lib) Exception
(Lib) RuntimeException
(Lib) IllegalArgumentException
(Lib) BuildException
Unknown
1
                    
// in src/org/python/expose/generate/TypeExposer.java
catch(Exception e) { // If we're unable to create the generated class, the process is // definitely ill, but that shouldn't be the case most of the time // so make this a runtime exception throw new RuntimeException("Unable to create generated builder", e); }
2
                    
// in src/org/python/core/PyRunnableBootstrap.java
catch (Exception e) { throw new IllegalArgumentException( "PyRunnable class does not specify apropriate constructor.", e); }
// in src/org/python/core/PyRunnableBootstrap.java
catch (Exception e) { throw new IllegalArgumentException( "PyRunnable class constructor does not support instantiation protocol.", e); }
1
                    
// in src/org/python/util/JythoncAntTask.java
catch (Exception e) { // Have to catch this because of the semantics of calling main() String msg = "Exception while calling " + JYTHON_CLASS + ". Details: " + e.toString(); throw new BuildException(msg, e); }
23
                    
// in src/com/ziclix/python/sql/DataHandler.java
catch (Exception e) { SQLException cause = null, ex = new SQLException("error setting index [" + index + "]"); if (e instanceof SQLException) { cause = (SQLException) e; } else { cause = new SQLException(e.getMessage()); } ex.setNextException(cause); throw ex; }
// in src/com/ziclix/python/sql/DataHandler.java
catch (Exception e) { SQLException cause = null, ex = new SQLException("error setting index [" + index + "], type [" + type + "]"); if (e instanceof SQLException) { cause = (SQLException) e; } else { cause = new SQLException(e.getMessage()); } ex.setNextException(cause); throw ex; }
// in src/com/ziclix/python/sql/Jython22DataHandler.java
catch (Exception e) { SQLException cause = null, ex = new SQLException("error setting index [" + index + "]"); if (e instanceof SQLException) { cause = (SQLException) e; } else { cause = new SQLException(e.getMessage()); } ex.setNextException(cause); throw ex; }
// in src/com/ziclix/python/sql/Jython22DataHandler.java
catch (Exception e) { SQLException cause = null, ex = new SQLException("error setting index [" + index + "], type [" + type + "]"); if (e instanceof SQLException) { cause = (SQLException) e; } else { cause = new SQLException(e.getMessage()); } ex.setNextException(cause); throw ex; }
// in src/com/ziclix/python/sql/connect/Connectx.java
catch (Exception e) { throw zxJDBC.makeException(zxJDBC.DatabaseError, "unable to instantiate datasource"); }
// in src/org/python/modules/_collections/PyDefaultDict.java
catch (Exception ex) { throw Py.KeyError(key); }
// in src/org/python/core/PyBeanProperty.java
catch (Exception e) { throw Py.JavaError(e); }
// in src/org/python/core/PyBeanProperty.java
catch (Exception e) { throw Py.JavaError(e); }
// in src/org/python/core/PyObject.java
catch (Exception exc) { throw Py.JavaError(exc); }
// in src/org/python/core/MakeProxies.java
catch (Exception exc) { throw Py.JavaError(exc); }
// in src/org/python/core/MakeProxies.java
catch (Exception exc) { throw Py.JavaError(exc); }
// in src/org/python/core/BytecodeLoader.java
catch (Exception e) { throw Py.JavaError(e); }
// in src/org/python/core/PyReflectedFunction.java
catch (Exception e) { throw Py.JavaError(e); }
// in src/org/python/core/PyBeanEventProperty.java
catch (Exception exc) { throw Py.JavaError(exc); }
// in src/org/python/core/PyBeanEventProperty.java
catch (Exception e) { throw Py.JavaError(e); }
// in src/org/python/core/PyBeanEventProperty.java
catch (Exception exc) { throw Py.JavaError(exc); }
// in src/org/python/core/PyBeanEvent.java
catch (Exception e) { throw Py.JavaError(e); }
// in src/org/python/core/exceptions.java
catch (Exception e) { throw Py.JavaError(e); }
// in src/org/python/core/PyJavaType.java
catch (Exception exc) { throw Py.JavaError(exc); }
// in src/org/python/core/PyJavaType.java
catch (Exception ex) { throw Py.TypeError("Could not copy Java object"); }
// in src/org/python/core/PyJavaType.java
catch (Exception ex) { throw Py.TypeError("Could not copy Java object"); }
// in src/org/python/core/PyJavaType.java
catch (Exception e) { throw Py.JavaError(e); }
// in src/org/python/util/JLineConsole.java
catch (Exception e) { throw Py.IOError(e.getMessage()); }
(Domain) ConversionException
Unknown
1
                    
// in src/org/python/core/PyObject.java
catch(PyObject.ConversionException e) { throw Py.TypeError("attribute name must be a string"); }
(Lib) IOException
(Lib) BuildException
(Lib) RuntimeException
(Domain) PyException
Unknown
3
                    
// in src/org/python/expose/generate/ExposeTask.java
catch (IOException e) { throw new BuildException("Unable to read '" + f + "' to expose it", e); }
// in src/org/python/expose/generate/ExposeTask.java
catch (IOException e) { throw new BuildException("Unable to write to '" + dest + "'", e); }
// in src/org/python/util/TemplateAntTask.java
catch(IOException e2) { throw new BuildException(e2.toString(), e2); }
1
                    
// in src/org/python/util/JLineConsole.java
catch (IOException e) { throw new RuntimeException(e); }
1
                    
// in src/org/python/util/ReadlineConsole.java
catch(IOException ioe) { throw new PyException(Py.IOError); }
58
                    
// in src/com/ziclix/python/sql/DataHandler.java
catch (IOException ioe) { throw zxJDBC.makeException(ioe); }
// in src/com/ziclix/python/sql/DataHandler.java
catch (IOException ioe) { throw zxJDBC.makeException(ioe); }
// in src/com/ziclix/python/sql/DataHandler.java
catch (IOException ioe) { throw zxJDBC.makeException(ioe); }
// in src/com/ziclix/python/sql/DataHandler.java
catch (IOException ioe) { throw zxJDBC.makeException(ioe); }
// in src/org/python/modules/zipimport/zipimporter.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/modules/zipimport/zipimporter.java
catch (IOException ioe) { throw zipimport.ZipImportError("zipimport: can not open file: " + archive); }
// in src/org/python/modules/zipimport/zipimporter.java
catch (IOException ioe) { Py.writeDebug("import", "zipimporter.getDataStream exception: " + ioe.toString()); throw zipimport.ZipImportError("zipimport: can not open file: " + archive); }
// in src/org/python/modules/zipimport/zipimporter.java
catch (IOException ioe) { throw zipimport.ZipImportError(String.format("can't read Zip file: '%s'", archive)); }
// in src/org/python/modules/zipimport/zipimporter.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/modules/zipimport/zipimporter.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/modules/posix/PosixModule.java
catch (IOException ioe) { throw Py.OSError(ioe); }
// in src/org/python/modules/posix/PosixModule.java
catch (IOException ioe) { throw Py.OSError(ioe); }
// in src/org/python/modules/posix/PosixModule.java
catch (IOException ioe) { throw Py.OSError(ioe); }
// in src/org/python/modules/random/PyRandom.java
catch (IOException e) { throw Py.SystemError("state vector invalid: "+e.getMessage()); }
// in src/org/python/modules/random/PyRandom.java
catch (IOException e) { throw Py.SystemError("creation of state vector failed: "+ e.getMessage()); }
// in src/org/python/modules/imp.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/PyFileWriter.java
catch (IOException e) { throw Py.IOError(e); }
// in src/org/python/core/PyFileWriter.java
catch (IOException e) { throw Py.IOError(e); }
// in src/org/python/core/PyFileWriter.java
catch (IOException e) { throw Py.IOError(e); }
// in src/org/python/core/io/StreamIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/StreamIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/StreamIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/StreamIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/SocketIOBase.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/FileIO.java
catch (IOException ioe) { // On Solaris and Linux, ftruncate(3C) returns EINVAL if not a regular // file whereas, e.g., open(os.devnull, "w") works. Because we have to // simulate the "w" mode in Java, we suppress the exception. // Likewise Windows returns ERROR_INVALID_FUNCTION in that case and // ERROR_INVALID_HANDLE on ttys. Identifying those by the IOException // message is tedious as their messages are localized, so we suppress them // all =[ if (Platform.IS_WINDOWS || ((Platform.IS_SOLARIS || Platform.IS_LINUX) && Errno.EINVAL.description().equals(ioe.getMessage()))) { return; } throw Py.IOError(ioe); }
// in src/org/python/core/io/FileIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/FileIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/FileIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/FileIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/FileIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/FileIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/FileIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/FileIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/FileIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/DatagramSocketIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/DatagramSocketIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/DatagramSocketIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/DatagramSocketIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/SocketIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/SocketIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/SocketIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/SocketIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/PyArray.java
catch(IOException e) { // discard anything successfully loaded delegate.setSize(origsize); throw Py.IOError(e); }
// in src/org/python/core/PyArray.java
catch(IOException e) { throw Py.IOError(e); }
// in src/org/python/core/PyFileReader.java
catch (IOException e) { throw Py.IOError(e); }
// in src/org/python/core/PyFileReader.java
catch (IOException e) { throw Py.IOError(e); }
// in src/org/python/core/PyFileReader.java
catch (IOException e) { throw Py.IOError(e); }
// in src/org/python/core/PyFileReader.java
catch (IOException e) { throw Py.IOError(e); }
// in src/org/python/core/__builtin__.java
catch (IOException e) { throw Py.IOError(e); }
// in src/org/python/core/ClasspathPyImporter.java
catch (IOException e) { throw Py.JavaError(e); }
// in src/org/python/core/imp.java
catch(IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/imp.java
catch(IOException e) { throw Py.IOError(e); }
// in src/org/python/core/imp.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/imp.java
catch (IOException ioe) { if (!testing) { throw Py.ImportError(ioe.getMessage() + "[name=" + name + ", source=" + sourceName + ", compiled=" + compiledName + "]"); } }
// in src/org/python/core/util/importer.java
catch (IOException ioe) { throw Py.ImportError(ioe.getMessage() + "[path=" + fullSearchPath + "]"); }
// in src/org/python/util/JLineConsole.java
catch (IOException ioe) { if (!fromSuspend(ioe)) { throw Py.IOError(ioe); } // Hopefully an IOException caused by ctrl-z (seems only BSD throws this). // Must reset jline to continue try { reader.getTerminal().initializeTerminal(); } catch (Exception e) { throw Py.IOError(e.getMessage()); } // Don't redisplay the prompt promptString = ""; }
// in src/org/python/util/jython.java
catch (IOException e) { throw Py.IOError(e); }
(Lib) IllegalAccessException
Unknown
6
                    
// in src/com/ziclix/python/sql/connect/Connectx.java
catch (IllegalAccessException e) { throw zxJDBC.makeException("illegal access for " + exceptionMsg); }
// in src/com/ziclix/python/sql/connect/Lookup.java
catch (IllegalAccessException e) { throw zxJDBC.makeException(zxJDBC.ProgrammingError, e); }
// in src/org/python/core/PyReflectedField.java
catch (IllegalAccessException exc) { throw Py.JavaError(exc); }
// in src/org/python/core/PyReflectedField.java
catch (IllegalAccessException exc) { throw Py.JavaError(exc); }
// in src/org/python/core/PyJavaType.java
catch (IllegalAccessException e) { throw Py.JavaError(e); }
// in src/org/python/core/imp.java
catch (IllegalAccessException e) { throw Py.JavaError(e); }
(Lib) InvocationTargetException
Unknown
3
                    
// in src/com/ziclix/python/sql/connect/Connectx.java
catch (InvocationTargetException e) { throw zxJDBC.makeException("invocation target exception for " + exceptionMsg); }
// in src/org/python/core/PyReflectedConstructor.java
catch (InvocationTargetException e) { if (e.getTargetException() instanceof InstantiationException) { Class<?> sup = proxy.getSuperclass(); String msg = "Constructor failed for Java superclass"; if (sup != null) { msg += " " + sup.getName(); } throw Py.TypeError(msg); } else throw Py.JavaError(e); }
(Lib) NoSuchMethodException
Unknown
1
                    
// in src/org/python/core/Py.java
catch (NoSuchMethodException e) { throw Py.JavaError(e); }
(Lib) NoSuchFieldException
Unknown
1
                    
// in src/org/python/core/PyBeanEventProperty.java
catch (NoSuchFieldException exc) { throw Py.AttributeError("Internal bean event error: " + __name__); }
(Lib) ClassCastException
Unknown
7
                    
// in src/org/python/core/PyArray.java
catch (ClassCastException e) { throw Py.TypeError("Type not compatible with array type"); }
// in src/org/python/core/PyArray.java
catch(ClassCastException e) { throw Py.TypeError("Type not compatible with array type"); }
// in src/org/python/core/PyArray.java
catch(ClassCastException e) { throw Py.TypeError("Type not compatible with array type"); }
// in src/org/python/core/PyArray.java
catch(ClassCastException e) { throw Py.TypeError("Type not compatible with array type"); }
// in src/org/python/core/PyArray.java
catch(ClassCastException e) { throw Py.TypeError("Type not compatible with array type"); }
// in src/org/python/core/__builtin__.java
catch (ClassCastException e) { throw Py.TypeError("apply() 3rd argument must be a " + "dictionary with string keys"); }
// in src/org/python/core/__builtin__.java
catch (ClassCastException e) { throw Py.TypeError(String.format("Expected keys() to be a list, not '%s'", retObj.getType().fastGetName())); }
(Lib) NamingException
Unknown
1
                    
// in src/com/ziclix/python/sql/connect/Lookup.java
catch (NamingException e) { throw zxJDBC.makeException(zxJDBC.DatabaseError, e); }
(Lib) ClassNotFoundException
(Lib) RuntimeException
Unknown
2
                    
// in src/com/ziclix/python/sql/JDBC30DataHandler.java
catch (ClassNotFoundException e) { throw new RuntimeException("JDBC3.0 required to use this DataHandler"); }
// in src/org/python/core/PyType.java
catch (ClassNotFoundException e) { // Well, this is certainly surprising. throw new RuntimeException("Got ClassNotFound calling Class.forName on an already " + " found class.", e); }
2
                    
// in src/org/python/modules/random/PyRandom.java
catch (ClassNotFoundException e) { throw Py.SystemError("state vector invalid: "+e.getMessage()); }
// in src/org/python/util/PythonObjectInputStream.java
catch (ClassNotFoundException exc) { PyObject m = importModule(clsName); Object cls = m.__tojava__(Class.class); if (cls != null && cls != Py.NoConversion) { return (Class<?>)cls; } throw exc; }
(Lib) InterruptedException
(Domain) PyException
Unknown
1
                    
// in src/org/python/modules/time/Time.java
catch (java.lang.InterruptedException e) { throw new PyException(Py.KeyboardInterrupt, "interrupted sleep"); }
2
                    
// in src/com/ziclix/python/sql/pipe/Pipe.java
catch (InterruptedException e) { queue.close(); throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/pipe/Pipe.java
catch (InterruptedException e) { queue.close(); throw zxJDBC.makeException(e); }
(Lib) IllegalArgumentException
(Domain) ParseException
Unknown
1
                    
// in src/org/python/core/FutureFeature.java
catch (IllegalArgumentException ex) { throw new ParseException("future feature " + featureName + " is not defined"); }
6
                    
// in src/org/python/core/stringlib/MarkupIterator.java
catch (IllegalArgumentException e) { throw Py.ValueError(e.getMessage()); }
// in src/org/python/core/PyArray.java
catch(IllegalArgumentException e) { throw Py.TypeError("Slice typecode '" + array.typecode + "' is not compatible with this array (typecode '" + this.typecode + "')"); }
// in src/org/python/core/Py.java
catch (IllegalArgumentException e) { throw JavaError(e); }
// in src/org/python/core/PyInteger.java
catch (IllegalArgumentException e) { throw Py.ValueError(e.getMessage()); }
// in src/org/python/core/PyString.java
catch (IllegalArgumentException e) { throw Py.ValueError(e.getMessage()); }
// in src/org/python/core/PyString.java
catch (IllegalArgumentException e) { throw Py.ValueError(e.getMessage()); }
(Lib) StringIndexOutOfBoundsException
Unknown
4
                    
// in src/org/python/modules/_marshal.java
catch (StringIndexOutOfBoundsException e) { // convert from our PyIOFile abstraction to what marshal in CPython returns // (although it's really just looking for no bombing) throw Py.EOFError("EOF read where object expected"); }
// in src/org/python/core/PyString.java
catch (StringIndexOutOfBoundsException exc) { throw Py.ValueError("invalid literal for int() with base " + base + ": " + getString()); }
// in src/org/python/core/PyString.java
catch (StringIndexOutOfBoundsException exc) { throw Py.ValueError("invalid literal for long() with base " + base + ": " + getString()); }
// in src/org/python/core/PyString.java
catch (StringIndexOutOfBoundsException e) { throw Py.ValueError("incomplete format"); }
(Lib) InstantiationException
Unknown
2
                    
// in src/org/python/core/PyObject.java
catch (java.lang.InstantiationException e) { Class<?> sup = c.getSuperclass(); String msg = "Default constructor failed for Java superclass"; if (sup != null) { msg += " " + sup.getName(); } throw Py.TypeError(msg); }
// in src/org/python/core/imp.java
catch (InstantiationException e) { throw Py.JavaError(e); }
(Lib) ClosedChannelException
Unknown
1
                    
// in src/org/python/modules/posix/PosixModule.java
catch (ClosedChannelException cce) { // In the rare case it's closed but the rawIO wasn't throw Py.ValueError("I/O operation on closed file"); }
(Lib) FileNotFoundException
Unknown
6
                    
// in src/org/python/modules/posix/PosixModule.java
catch (FileNotFoundException fnfe) { throw Py.OSError(file.isDirectory() ? Errno.EISDIR : Errno.ENOENT, path); }
// in src/org/python/core/io/FileIO.java
catch (FileNotFoundException fnfe) { if (absPath.isDirectory()) { throw Py.IOError(Errno.EISDIR, name); } if ((writing && !absPath.canWrite()) || fnfe.getMessage().endsWith("(Permission denied)")) { throw Py.IOError(Errno.EACCES, name); } throw Py.IOError(Errno.ENOENT, name); }
// in src/org/python/core/__builtin__.java
catch (FileNotFoundException e) { throw Py.IOError(e); }
// in src/org/python/util/jython.java
catch (FileNotFoundException e) { throw Py.IOError(e); }
(Lib) NumberFormatException
Unknown
5
                    
// in src/org/python/modules/cPickle.java
catch(NumberFormatException e) { try { value = Py.newLong(line); } catch(NumberFormatException e2) { throw Py.ValueError("could not convert string to int"); } }
// in src/org/python/modules/cPickle.java
catch(NumberFormatException e2) { throw Py.ValueError("could not convert string to int"); }
// in src/org/python/core/PyString.java
catch (NumberFormatException exc) { throw Py.ValueError("invalid literal for __float__: "+getString()); }
// in src/org/python/core/PyString.java
catch (NumberFormatException exc) { throw Py.ValueError("invalid literal for int() with base " + base + ": " + getString()); }
// in src/org/python/core/PyString.java
catch (NumberFormatException exc) { if (this instanceof PyUnicode) { // TODO: here's a basic issue: do we use the BigInteger constructor // above, or add an equivalent to CPython's PyUnicode_EncodeDecimal; // we should note that the current error string does not quite match // CPython regardless of the codec, that's going to require some more work throw Py.UnicodeEncodeError("decimal", "codec can't encode character", 0,0, "invalid decimal Unicode string"); } else { throw Py.ValueError("invalid literal for long() with base " + base + ": " + getString()); } }
(Lib) IllegalMonitorStateException
Unknown
1
                    
// in src/org/python/modules/imp.java
catch(IllegalMonitorStateException e){ throw Py.RuntimeError("not holding the import lock"); }
(Lib) ArrayIndexOutOfBoundsException
(Domain) PyException
Unknown
2
                    
// in src/org/python/modules/time/Time.java
catch (ArrayIndexOutOfBoundsException e) { throw new PyException(Py.ValueError, new PyString("day of week out of range (0-6)")); }
// in src/org/python/modules/time/Time.java
catch (ArrayIndexOutOfBoundsException e) { throw new PyException(Py.ValueError, new PyString("month out of range (1-12)")); }
1
                    
// in src/org/python/core/AnnotationReader.java
catch (ArrayIndexOutOfBoundsException e) { IOException ioe = new IOException("Malformed bytecode: not enough data"); ioe.initCause(e);// IOException didn't grow a constructor that could take a cause till // 1.6, so do it the old fashioned way throw ioe; }
(Lib) NoSuchAlgorithmException
Unknown
1
                    
// in src/org/python/modules/_hashlib.java
catch (NoSuchAlgorithmException nsae) { throw Py.ValueError("unsupported hash type"); }
(Lib) CloneNotSupportedException
(Lib) RuntimeException
Unknown
2
                    
// in src/org/python/core/PyBuiltinMethodSet.java
catch (CloneNotSupportedException e) { throw new RuntimeException("Didn't expect PyBuiltinMethodSet to throw " + "CloneNotSupported since it implements Cloneable", e); }
// in src/org/python/core/PyBuiltinMethod.java
catch(CloneNotSupportedException e) { throw new RuntimeException("Didn't expect PyBuiltinMethodto throw " + "CloneNotSupported since it implements Cloneable", e); }
1
                    
// in src/org/python/modules/_hashlib.java
catch (CloneNotSupportedException cnse) { throw Py.RuntimeError(String.format("_hashlib.HASH (%s) internal error", name)); }
(Lib) NoSuchMethodError
Unknown
1
                    
// in src/org/python/core/PyObject.java
catch (NoSuchMethodError nsme) { throw Py.TypeError("constructor requires arguments"); }
(Lib) MalformedURLException
(Lib) RuntimeException
2
                    
// in src/org/python/core/SyspathJavaLoader.java
catch (MalformedURLException e) { throw new RuntimeException(e); }
// in src/org/python/core/SyspathJavaLoader.java
catch (MalformedURLException e) { throw new RuntimeException(e); }
(Lib) ConcurrentModificationException
Unknown
1
                    
// in src/org/python/core/PyList.java
catch (ConcurrentModificationException ex) { throw Py.ValueError(message); }
(Lib) IndexOutOfBoundsException
Unknown
1
                    
// in src/org/python/core/PyString.java
catch (IndexOutOfBoundsException e) { throw Py.TypeError( "translate() only works for 8-bit character strings"); }
(Lib) ArrayStoreException
(Lib) IllegalArgumentException
1
                    
// in src/org/python/core/AbstractArray.java
catch (ArrayStoreException e) { throw new IllegalArgumentException("'ofArrayType' must be compatible with existing array type of " + getArray().getClass().getName() + "\tsee java.lang.Class.getName()."); }
(Lib) UnsupportedCharsetException
(Domain) PySyntaxError
1
                    
// in src/org/python/core/ParserFacade.java
catch (UnsupportedCharsetException exc) { throw new PySyntaxError("Unknown encoding: " + encoding, 1, 0, "", filename); }
(Lib) NoSuchElementException
(Domain) PyException
1
                    
// in src/org/python/core/PySet.java
catch (NoSuchElementException e) { throw new PyException(Py.KeyError, "pop from an empty set"); }
(Lib) EOFException
(Domain) PyException
Unknown
1
                    
// in src/org/python/util/ReadlineConsole.java
catch(EOFException eofe) { throw new PyException(Py.EOFError); }
1
                    
// in src/org/python/core/PyArray.java
catch(EOFException e) { // stubbed catch for fromStream throws throw Py.EOFError("not enough items in string"); }
(Lib) ExceptionInInitializerError
Unknown
1
                    
// in src/org/python/core/PyType.java
catch (ExceptionInInitializerError e) { throw Py.JavaError(e); }
(Lib) NoClassDefFoundError
Unknown
1
                    
// in src/org/python/core/imp.java
catch (NoClassDefFoundError e) { throw Py.ImportError("Cannot import " + name + ", missing class " + c.getName()); }
(Lib) LinkageError
Unknown
1
                    
// in src/org/python/core/Py.java
catch (LinkageError e) { throw JavaError(e); }
(Lib) UnsupportedEncodingException
Unknown
1
                    
// in src/org/python/core/util/StringUtil.java
catch(UnsupportedEncodingException uee) { // This JVM is whacked, it doesn't even have iso-8859-1 throw Py.SystemError("Java couldn't find the ISO-8859-1 encoding"); }

Caught / Thrown Exception

Not all exceptions are thrown AND caught in the same project. The following table gives the exceptions types with respect to this. The lower left hand side sell lists all exceptions thrown but not caught (prevalent for libraries), the upper right-hand side lists all exceptions caught but not thrown (usually coming from external dependencies).

Thrown Not Thrown
Caught
Type Name
(Domain) PyException
(Lib) RuntimeException
(Domain) QueueClosedException
(Domain) IndexingException
(Domain) StopIterationException
(Domain) InvalidExposingException
(Domain) ParseException
(Lib) Exception
(Domain) ConversionException
(Lib) IOException
(Lib) NoSuchMethodException
(Lib) ClassNotFoundException
(Lib) IllegalArgumentException
(Lib) UnsupportedOperationException
(Lib) IllegalStateException
(Lib) InstantiationException
(Lib) FileNotFoundException
(Lib) NumberFormatException
(Lib) ArrayIndexOutOfBoundsException
(Lib) IndexOutOfBoundsException
(Lib) NoSuchElementException
Type Name
(Lib) Throwable
(Lib) SQLException
(Lib) AbstractMethodError
(Lib) MissingResourceException
(Lib) IllegalAccessException
(Lib) InvocationTargetException
(Lib) NoSuchFieldException
(Lib) ClassCastException
(Lib) NamingException
(Lib) InterruptedException
(Lib) StackOverflowError
(Lib) OutOfMemoryError
(Lib) StringIndexOutOfBoundsException
(Lib) SecurityException
(Lib) RecognitionException
(Lib) ClosedChannelException
(Lib) IllegalMonitorStateException
(Lib) NoSuchAlgorithmException
(Lib) CloneNotSupportedException
(Lib) NoSuchMethodError
(Lib) MalformedURLException
(Lib) ConcurrentModificationException
(Lib) ArrayStoreException
(Lib) AccessControlException
(Lib) UnsupportedCharsetException
(Lib) BufferOverflowException
(Lib) EOFException
(Lib) ExceptionInInitializerError
(Lib) NoClassDefFoundError
(Lib) LinkageError
(Lib) UnsupportedEncodingException
Not caught
Type Name
(Lib) ServletException
(Lib) BuildException
(Lib) MismatchedTokenException
(Lib) NullPointerException
(Lib) InternalError
(Lib) InvalidClassException
(Lib) StreamCorruptedException
(Domain) PySyntaxError
(Lib) Error

Methods called in Catch and Finally Blocks

The following shows the methods that are called inside catch blocks (first column) and finally blocks (second column). For each method, we give the number of times it is called in a catch block (second sub-column), and the total number of calls (third sub-column). If the method name is red, it means that it is only called from catch/finally blocks. Hovering over a number triggers showing code snippets from the application code.

Catch Finally
Method Nbr Nbr total
match 427
                  
// in src/org/python/compiler/Module.java
catch (PyException e) { if (!e.match(Py.SyntaxWarning)) { throw e; } }
// in src/org/python/antlr/ast/aliasDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/aliasDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/aliasDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/AttributeDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/AttributeDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/AttributeDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/UnaryOpDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/UnaryOpDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/UnaryOpDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/BreakDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/BreakDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/BreakDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/BoolOpDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/BoolOpDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/BoolOpDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ListCompDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/ListCompDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ListCompDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ContinueDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/ContinueDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ContinueDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/TupleDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/TupleDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/TupleDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/InteractiveDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/InteractiveDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/InteractiveDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/DeleteDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/DeleteDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/DeleteDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/IndexDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/IndexDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/IndexDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ModuleDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/ModuleDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ModuleDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/CallDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/CallDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/CallDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ReturnDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/ReturnDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ReturnDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ForDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/ForDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ForDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ExceptHandlerDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/ExceptHandlerDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ExceptHandlerDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/SubscriptDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/SubscriptDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/SubscriptDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/DictDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/DictDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/DictDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/LambdaDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/LambdaDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/LambdaDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/GlobalDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/GlobalDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/GlobalDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ListDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/ListDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ListDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/BinOpDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/BinOpDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/BinOpDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ClassDefDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/ClassDefDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ClassDefDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ExpressionDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/ExpressionDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ExpressionDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/SliceDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/SliceDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/SliceDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/NumDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/NumDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/NumDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ExprDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/ExprDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ExprDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/NameDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/NameDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/NameDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/TryFinallyDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/TryFinallyDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/TryFinallyDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/IfExpDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/IfExpDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/IfExpDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/AugAssignDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/AugAssignDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/AugAssignDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ImportDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/ImportDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ImportDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/IfDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/IfDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/IfDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/PassDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/PassDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/PassDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/FunctionDefDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/FunctionDefDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/FunctionDefDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/argumentsDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/argumentsDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/argumentsDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/WithDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/WithDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/WithDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ImportFromDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/ImportFromDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ImportFromDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/CompareDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/CompareDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/CompareDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ReprDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/ReprDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ReprDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/StrDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/StrDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/StrDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/YieldDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/YieldDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/YieldDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/EllipsisDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/EllipsisDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/EllipsisDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/RaiseDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/RaiseDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/RaiseDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/AssignDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/AssignDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/AssignDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/GeneratorExpDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/GeneratorExpDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/GeneratorExpDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/SuiteDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/SuiteDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/SuiteDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/AssertDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/AssertDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/AssertDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/TryExceptDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/TryExceptDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/TryExceptDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ExecDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/ExecDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ExecDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/WhileDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/WhileDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/WhileDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/keywordDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/keywordDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/keywordDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/comprehensionDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/comprehensionDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/comprehensionDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ExtSliceDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/ExtSliceDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ExtSliceDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/PrintDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/PrintDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/PrintDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/PowDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/PowDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/PowDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/LtEDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/LtEDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/LtEDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/ParamDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/ParamDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/ParamDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/EqDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/EqDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/EqDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/GtDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/GtDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/GtDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/IsDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/IsDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/IsDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/GtEDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/GtEDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/GtEDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/StoreDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/StoreDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/StoreDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/BitOrDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/BitOrDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/BitOrDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/RShiftDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/RShiftDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/RShiftDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/BitAndDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/BitAndDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/BitAndDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/NotInDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/NotInDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/NotInDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/LtDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/LtDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/LtDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/FloorDivDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/FloorDivDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/FloorDivDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/USubDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/USubDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/USubDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/InvertDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/InvertDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/InvertDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/AugLoadDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/AugLoadDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/AugLoadDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/AugStoreDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/AugStoreDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/AugStoreDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/LoadDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/LoadDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/LoadDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/IsNotDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/IsNotDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/IsNotDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/BitXorDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/BitXorDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/BitXorDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/NotEqDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/NotEqDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/NotEqDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/NotDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/NotDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/NotDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/AndDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/AndDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/AndDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/ModDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/ModDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/ModDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/AddDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/AddDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/AddDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/DelDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/DelDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/DelDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/DivDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/DivDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/DivDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/LShiftDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/LShiftDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/LShiftDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/InDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/InDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/InDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/MultDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/MultDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/MultDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/UAddDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/UAddDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/UAddDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/OrDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/OrDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/OrDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/SubDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/SubDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/SubDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/modules/zipimport/zipimporterDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/modules/zipimport/zipimporterDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/modules/zipimport/zipimporterDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/modules/zipimport/zipimporter.java
catch (PyException pye) { if (!pye.match(Py.TypeError)) { throw pye; } time = -1; date = -1; }
// in src/org/python/modules/binascii.java
catch (PyException e) { if (e.match(Py.AttributeError) || e.match(Py.ValueError)) throw Py.TypeError(errMsg); throw e; }
// in src/org/python/modules/_weakref/ReferenceTypeDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/modules/_weakref/ReferenceTypeDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/modules/_weakref/ReferenceTypeDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/modules/posix/PosixModule.java
catch (PyException pye) { if (!pye.match(Py.OSError)) { throw pye; } // ENOENT result = false; }
// in src/org/python/modules/posix/PosixModule.java
catch (PyException pye) { if (!pye.match(Py.IOError)) { throw pye; } throw Py.OSError(Errno.EINVAL); }
// in src/org/python/modules/posix/PosixModule.java
catch (PyException pye) { if (!pye.match(Py.KeyError)) { throw pye; } }
// in src/org/python/modules/thread/PyLocalDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/modules/thread/PyLocalDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/modules/thread/PyLocalDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/modules/_csv/PyDialectDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/modules/_csv/PyDialectDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/modules/_csv/PyDialectDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/modules/random/PyRandomDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/modules/random/PyRandomDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/modules/random/PyRandomDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/modules/_collections/PyDequeDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/modules/_collections/PyDequeDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/modules/_collections/PyDequeDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/modules/_collections/PyDefaultDictDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/modules/_collections/PyDefaultDictDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/modules/_collections/PyDefaultDictDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/modules/_collections/PyDeque.java
catch (PyException pe) { if (pe.match(Py.KeyError)) { return null; } throw pe; }
// in src/org/python/modules/itertools.java
catch (PyException pyEx) { if (pyEx.match(Py.StopIteration)) { // store exception - will be used by PyIterator.next() stopException = pyEx; } else { throw pyEx; } }
// in src/org/python/modules/itertools.java
catch (PyException pyEx) { if (pyEx.match(Py.TypeError)) { throw Py.ValueError(msg); } else { throw pyEx; } }
// in src/org/python/modules/_functools/PyPartialDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/modules/_functools/PyPartialDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/modules/_functools/PyPartialDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/modules/PyTeeIterator.java
catch (PyException pyEx) { if (pyEx.match(Py.StopIteration)) { // store exception - will be used by PyIterator.next() stopException = pyEx; } else { throw pyEx; } }
// in src/org/python/core/PyObject.java
catch (PyException pye) { if (!pye.match(Py.AttributeError)) { throw pye; } }
// in src/org/python/core/PyObject.java
catch (PyException exc) { if (exc.match(Py.AttributeError)) { return null; } throw exc; }
// in src/org/python/core/PyObject.java
catch (PyException exc) { if (exc.match(Py.KeyError)) { noAttributeError(name); } else { throw exc; } }
// in src/org/python/core/PyObject.java
catch (PyException pye) { if (pye.match(Py.AttributeError)) { throw Py.TypeError("an integer is required"); } throw pye; }
// in src/org/python/core/PyObject.java
catch (PyException pye) { if (pye.match(Py.AttributeError)) { throw Py.TypeError("an integer is required"); } throw pye; }
// in src/org/python/core/PyObject.java
catch (PyException pye) { if (pye.match(Py.AttributeError)) { throw Py.TypeError("a float is required"); } throw pye; }
// in src/org/python/core/PyStringMap.java
catch(PyException pye) { if (pye.match(Py.TypeError)) { throw Py.TypeError(String.format("cannot convert dictionary update sequence " + "element #%d to a sequence", i)); } throw pye; }
// in src/org/python/core/PyList.java
catch (PyException pye) { if (!pye.match(Py.TypeError)) { throw pye; } return null; }
// in src/org/python/core/PyFloatDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyFloatDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyFloatDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyArrayDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyArrayDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyArrayDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/FunctionThread.java
catch (PyException exc) { if (exc.match(Py.SystemExit) || exc.match(_systemrestart.SystemRestart)) { return; } Py.stderr.println("Unhandled exception in thread started by " + func); Py.printException(exc); }
// in src/org/python/core/PyEnumerateDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyEnumerateDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyEnumerateDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PySystemState.java
catch (PyException exc) { if (!exc.match(Py.SystemExit)) { Py.println(stderr, Py.newString("Error in sys.exitfunc:")); } Py.printException(exc); }
// in src/org/python/core/PyDictionary.java
catch(PyException pye) { if (pye.match(Py.TypeError)) { throw Py.TypeError(String.format("cannot convert dictionary update sequence " + "element #%d to a sequence", i)); } throw pye; }
// in src/org/python/core/PyUnicodeDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyUnicodeDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyUnicodeDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyFastSequenceIter.java
catch (PyException pye) { if (pye.match(Py.StopIteration)) { seq = null; return null; } throw pye; }
// in src/org/python/core/PyComplex.java
catch (PyException pye) { if (!pye.match(Py.AttributeError)) { // __complex__ not supported throw pye; } // otherwise try other means }
// in src/org/python/core/PyComplex.java
catch (PyException pye) { if (pye.match(Py.AttributeError)) { // __float__ not supported throw Py.TypeError("complex() argument must be a string or a number"); } throw pye; }
// in src/org/python/core/PyComplex.java
catch (PyException pye) { if (pye.match(Py.AttributeError)) { // __float__ not supported throw Py.TypeError("complex() argument must be a string or a number"); } throw pye; }
// in src/org/python/core/PyInstance.java
catch (PyException exc) { if (exc.match(Py.KeyError)) throw Py.AttributeError("class " + instclass.__name__ + " has no attribute '" + name + "'"); }
// in src/org/python/core/PyInstance.java
catch (PyException e) { if (e.match(Py.IndexError)) return null; if (e.match(Py.KeyError)) return null; throw e; }
// in src/org/python/core/PyInstance.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyInstance.java
catch (PyException pye) { if (!pye.match(Py.AttributeError)) { throw pye; } throw Py.TypeError("object cannot be interpreted as an index"); }
// in src/org/python/core/PyFrame.java
catch (PyException pye) { if (pye.match(Py.KeyError)) { throw Py.NameError(String.format(NAME_ERROR_MSG, index)); } throw pye; }
// in src/org/python/core/PyFrame.java
catch (PyException pye) { if (pye.match(Py.KeyError)) { throw Py.NameError(String.format(GLOBAL_NAME_ERROR_MSG, index)); } throw pye; }
// in src/org/python/core/PyLongDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyLongDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyLongDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/AstList.java
catch (PyException pye) { if (!pye.match(Py.TypeError)) { throw pye; } return null; }
// in src/org/python/core/AstList.java
catch (PyException pye) { if (pye.match(Py.TypeError)) { throw Py.TypeError("can only assign an iterable"); } throw pye; }
// in src/org/python/core/PyFloat.java
catch (PyException e) { if (e.match(Py.AttributeError)) { // Translate AttributeError to TypeError // XXX: We are using the same message as CPython, even if // it is not strictly correct (instances of types // that implement the __float__ method are also // valid arguments) throw Py.TypeError("float() argument must be a string or a number"); } throw e; }
// in src/org/python/core/PySlice.java
catch (PyException pye) { if (!pye.match(Py.TypeError)) { throw pye; } }
// in src/org/python/core/PyIntegerDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyIntegerDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyIntegerDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyBaseExceptionDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyBaseExceptionDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyBaseExceptionDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/io/IOBase.java
catch (PyException pye) { if (!pye.match(Py.IOError)) { throw pye; } // If flush() fails, just give up }
// in src/org/python/core/io/BufferedIOMixin.java
catch (PyException pye) { if (!pye.match(Py.IOError)) { throw pye; } // If flush() fails, just give up }
// in src/org/python/core/PySuperDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PySuperDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PySuperDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyModuleDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyModuleDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyModuleDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/__builtin__.java
catch (PyException pye) { if (!pye.match(Py.AttributeError)) { throw pye; } attributeError = pye; }
// in src/org/python/core/__builtin__.java
catch (PyException e) { if (e.match(Py.AttributeError)) { throw Py.TypeError("vars() argument must have __dict__ attribute"); } throw e; }
// in src/org/python/core/__builtin__.java
catch (PyException e) { if (e.match(Py.StopIteration)) { return ret; } throw e; }
// in src/org/python/core/PyTypeDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyTypeDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyTypeDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PySetDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PySetDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PySetDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyPropertyDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyPropertyDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyPropertyDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/Py.java
catch (PyException e) { if (e.match(ImportError)) { return null; } throw e; }
// in src/org/python/core/Py.java
catch (PyException e) { Py.getSystemState().callExitFunc(); if (e.match(Py.SystemExit)) { return; } throw e; }
// in src/org/python/core/Py.java
catch (PyException pye) { if (!pye.match(TypeError)) { throw pye; } pye.value = Py.newString(String.format("Error when calling the metaclass bases\n " + "%s", pye.value.__str__().toString())); throw pye; }
// in src/org/python/core/Py.java
catch (PyException exc) { if (exc.match(Py.TypeError)) { throw Py.TypeError(message); } throw exc; }
// in src/org/python/core/PySequenceIter.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) { seq = null; return null; } throw exc; }
// in src/org/python/core/PyFileDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyFileDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyFileDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyCallIter.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) { callable = null; stopException = exc; return null; } throw exc; }
// in src/org/python/core/PyListDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyListDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyListDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyFrozenSetDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyFrozenSetDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyFrozenSetDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyDictionaryDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyDictionaryDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyDictionaryDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyBytecode.java
catch (PyException pye) { if (pye.match(Py.AttributeError)) { throw Py.ImportError(String.format("cannot import name %.230s", name)); } else { throw pye; } }
// in src/org/python/core/PyBytecode.java
catch (PyException pye) { if (!pye.match(Py.StopIteration)) { throw pye; } }
// in src/org/python/core/PyStringDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyStringDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyStringDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/codecs.java
catch (PyException ex) { if (ex.match(Py.LookupError)) { // If we couldn't find an encoding, see if we have a builtin if (encoding.equals("utf-8")) { return wrapDecodeResult(PyUnicode_DecodeUTF8(v.toString(), errors)); } else if(encoding.equals("utf-7")) { return wrapDecodeResult(PyUnicode_DecodeUTF7(v.toString(), errors)); } else if(encoding.equals("latin-1")) { return wrapDecodeResult(PyUnicode_DecodeLatin1(v.toString(), v.__len__(), errors)); } } throw ex; }
// in src/org/python/core/codecs.java
catch (PyException ex) { if (ex.match(Py.LookupError)) { // If we couldn't find an encoding, see if we have a builtin if (encoding.equals("utf-8")) { return PyUnicode_EncodeUTF8(v.toString(), errors); } else if(encoding.equals("utf-7")) { return codecs.PyUnicode_EncodeUTF7(v.toString(), false, false, errors); } } throw ex; }
// in src/org/python/core/PyInteger.java
catch (PyException pye) { if (pye.match(Py.OverflowError)) { return ((PyString) x).atol(base); } throw pye; }
// in src/org/python/core/PyInteger.java
catch (PyException pye) { if (!pye.match(Py.AttributeError)) { throw pye; } throw Py.TypeError("int() argument must be a string or a number"); }
// in src/org/python/core/PyObjectDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyObjectDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyObjectDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyComplexDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyComplexDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyComplexDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyLong.java
catch (PyException pye) { if (!pye.match(Py.AttributeError)) { throw pye; } throw Py.TypeError(String.format("long() argument must be a string or a number, " + "not '%.200s'", x.getType().fastGetName())); }
// in src/org/python/core/PyClassMethodDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyClassMethodDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyClassMethodDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyTupleDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyTupleDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyTupleDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyString.java
catch (PyException e) { if (e.match(Py.OverflowError)) { return atol(10); } throw e; }
// in src/org/python/core/PyString.java
catch (PyException e) { // XXX: Swallow customs AttributeError throws from __float__ methods // No better alternative for the moment if (e.match(Py.AttributeError)) { throw Py.TypeError("int argument required"); } throw e; }
// in src/org/python/core/PyString.java
catch (PyException pye) { throw !pye.match(Py.TypeError) ? pye : Py.TypeError("float argument required"); }
// in src/org/python/core/PyString.java
catch (PyException e){ if (e.match(Py.AttributeError)) { throw Py.TypeError("%c requires int or char"); } throw e; }
// in src/org/python/core/imp.java
catch (PyException pye) { // another thread may have deleted it if (!pye.match(Py.KeyError)) { throw pye; } }
// in src/org/python/core/imp.java
catch (PyException e) { if (!e.match(Py.ImportError)) { throw e; } }
// in src/org/python/core/ClasspathPyImporterDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/ClasspathPyImporterDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/ClasspathPyImporterDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/Deriveds.java
catch (PyException pye) { if (!pye.match(Py.AttributeError)) { throw pye; } else { // saved to avoid swallowing custom AttributeErrors, and pass through to // __getattr__ firstAttributeError = pye; } }
// in src/org/python/util/InteractiveInterpreter.java
catch (PyException exc) { if (exc.match(Py.SyntaxError)) { // Case 1 showexception(exc); return false; } else if (exc.match(Py.ValueError) || exc.match(Py.OverflowError)) { // Should not print the stack trace, just the error. showexception(exc); return false; } else { throw exc; } }
// in src/org/python/util/InteractiveInterpreter.java
catch (PyException exc) { if (exc.match(Py.SystemExit)) throw exc; showexception(exc); }
// in src/org/python/util/InteractiveConsole.java
catch(PyException exc) { if(!exc.match(Py.EOFError)) throw exc; write("\n"); break; }
// in src/org/python/util/jython.java
catch (PyException pye) { if (!pye.match(Py.ImportError)) { System.err.println("error importing site"); Py.printException(pye); System.exit(-1); } }
// in src/org/python/util/jython.java
catch (Throwable t) { if (t instanceof PyException && ((PyException)t).match(_systemrestart.SystemRestart)) { // Shutdown this instance... shouldRestart = true; shutdownInterpreter(); interp.cleanup(); // ..reset the state... Py.setSystemState(new PySystemState()); // ...and start again return; } else { Py.printException(t); interp.cleanup(); System.exit(-1); } }
436
makeException 58
                  
// in src/com/ziclix/python/sql/Fetch.java
catch (Throwable e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/Fetch.java
catch (Throwable e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/Fetch.java
catch (Throwable e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/Fetch.java
catch (AbstractMethodError e) { throw zxJDBC.makeException(zxJDBC.NotSupportedError, zxJDBC.getString("nodynamiccursors")); }
// in src/com/ziclix/python/sql/Fetch.java
catch (Throwable e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/Fetch.java
catch (AbstractMethodError e) { throw zxJDBC.makeException(zxJDBC.NotSupportedError, zxJDBC.getString("nodynamiccursors")); }
// in src/com/ziclix/python/sql/Fetch.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/Fetch.java
catch (Throwable t) { throw zxJDBC.makeException(t); }
// in src/com/ziclix/python/sql/zxJDBC.java
catch (Throwable t) { throw makeException(t); }
// in src/com/ziclix/python/sql/PyConnection.java
catch (SQLException e) { throw zxJDBC.makeException(zxJDBC.DatabaseError, e); }
// in src/com/ziclix/python/sql/PyConnection.java
catch (SQLException e) { throw zxJDBC.makeException(zxJDBC.DatabaseError, e); }
// in src/com/ziclix/python/sql/PyConnection.java
catch (SQLException e) { throw zxJDBC.makeException(zxJDBC.DatabaseError, e); }
// in src/com/ziclix/python/sql/PyConnection.java
catch (SQLException e) { throw zxJDBC.makeException(zxJDBC.DatabaseError, e); }
// in src/com/ziclix/python/sql/PyConnection.java
catch (SQLException e) { throw zxJDBC.makeException(zxJDBC.DatabaseError, e); }
// in src/com/ziclix/python/sql/PyConnection.java
catch (SQLException e) { throw zxJDBC.makeException(zxJDBC.DatabaseError, e); }
// in src/com/ziclix/python/sql/PyConnection.java
catch (SQLException e) { throw zxJDBC.makeException(zxJDBC.DatabaseError, e); }
// in src/com/ziclix/python/sql/PyConnection.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyConnection.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyConnection.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyConnection.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/DataHandler.java
catch (IOException ioe) { throw zxJDBC.makeException(ioe); }
// in src/com/ziclix/python/sql/DataHandler.java
catch (IOException ioe) { throw zxJDBC.makeException(ioe); }
// in src/com/ziclix/python/sql/DataHandler.java
catch (IOException ioe) { throw zxJDBC.makeException(ioe); }
// in src/com/ziclix/python/sql/DataHandler.java
catch (IOException ioe) { throw zxJDBC.makeException(ioe); }
// in src/com/ziclix/python/sql/PyExtendedCursor.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyExtendedCursor.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyExtendedCursor.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyExtendedCursor.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyExtendedCursor.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyExtendedCursor.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyExtendedCursor.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyExtendedCursor.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyExtendedCursor.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyExtendedCursor.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyExtendedCursor.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/connect/Connectx.java
catch (Exception e) { throw zxJDBC.makeException(zxJDBC.DatabaseError, "unable to instantiate datasource"); }
// in src/com/ziclix/python/sql/connect/Connectx.java
catch (SQLException e) { throw zxJDBC.makeException(zxJDBC.DatabaseError, e); }
// in src/com/ziclix/python/sql/connect/Connectx.java
catch (SQLException e) { throw zxJDBC.makeException(zxJDBC.DatabaseError, e); }
// in src/com/ziclix/python/sql/connect/Connectx.java
catch (IllegalAccessException e) { throw zxJDBC.makeException("illegal access for " + exceptionMsg); }
// in src/com/ziclix/python/sql/connect/Connectx.java
catch (InvocationTargetException e) { throw zxJDBC.makeException("invocation target exception for " + exceptionMsg); }
// in src/com/ziclix/python/sql/connect/Connect.java
catch (Throwable e) { throw zxJDBC.makeException(zxJDBC.DatabaseError, "driver [" + driver + "] not found"); }
// in src/com/ziclix/python/sql/connect/Connect.java
catch (SQLException e) { throw zxJDBC.makeException(zxJDBC.DatabaseError, e); }
// in src/com/ziclix/python/sql/connect/Connect.java
catch (SQLException e) { throw zxJDBC.makeException(zxJDBC.DatabaseError, e); }
// in src/com/ziclix/python/sql/connect/Lookup.java
catch (IllegalAccessException e) { throw zxJDBC.makeException(zxJDBC.ProgrammingError, e); }
// in src/com/ziclix/python/sql/connect/Lookup.java
catch (NamingException e) { throw zxJDBC.makeException(zxJDBC.DatabaseError, e); }
// in src/com/ziclix/python/sql/connect/Lookup.java
catch (SQLException e) { throw zxJDBC.makeException(zxJDBC.DatabaseError, e); }
// in src/com/ziclix/python/sql/connect/Lookup.java
catch (SQLException e) { throw zxJDBC.makeException(zxJDBC.DatabaseError, e); }
// in src/com/ziclix/python/sql/PyStatement.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyStatement.java
catch (PyException e) { throw zxJDBC.makeException(zxJDBC.ProgrammingError, zxJDBC.getString("bindingValue")); }
// in src/com/ziclix/python/sql/PyStatement.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/pipe/Pipe.java
catch (InterruptedException e) { queue.close(); throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/pipe/Pipe.java
catch (InterruptedException e) { queue.close(); throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyCursor.java
catch (AbstractMethodError e) { throw zxJDBC.makeException(zxJDBC.NotSupportedError, zxJDBC.getString("nodynamiccursors")); }
// in src/com/ziclix/python/sql/PyCursor.java
catch (Throwable e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyCursor.java
catch (Throwable t) { if (statement != null) { statement.close(); } throw zxJDBC.makeException(t); }
// in src/com/ziclix/python/sql/PyCursor.java
catch (Throwable t) { if (statement != null && !(sql instanceof PyStatement)) { // only close static, single-use statements statement.close(); } throw zxJDBC.makeException(zxJDBC.Error, t, rowIndex); }
// in src/com/ziclix/python/sql/PyCursor.java
catch (Throwable e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyCursor.java
catch (SQLException sqle) { throw zxJDBC.makeException(sqle); }
106
IOError 49
                  
// in src/org/python/modules/zipimport/zipimporter.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/modules/zipimport/zipimporter.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/modules/zipimport/zipimporter.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/modules/posix/PosixModule.java
catch (PyException pye) { throw Py.IOError(Errno.EBADF); }
// in src/org/python/modules/imp.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/PyFileWriter.java
catch (IOException e) { throw Py.IOError(e); }
// in src/org/python/core/PyFileWriter.java
catch (IOException e) { throw Py.IOError(e); }
// in src/org/python/core/PyFileWriter.java
catch (IOException e) { throw Py.IOError(e); }
// in src/org/python/core/io/StreamIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/StreamIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/StreamIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/StreamIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/SocketIOBase.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/FileIO.java
catch (FileNotFoundException fnfe) { if (absPath.isDirectory()) { throw Py.IOError(Errno.EISDIR, name); } if ((writing && !absPath.canWrite()) || fnfe.getMessage().endsWith("(Permission denied)")) { throw Py.IOError(Errno.EACCES, name); } throw Py.IOError(Errno.ENOENT, name); }
// in src/org/python/core/io/FileIO.java
catch (IOException ioe) { // On Solaris and Linux, ftruncate(3C) returns EINVAL if not a regular // file whereas, e.g., open(os.devnull, "w") works. Because we have to // simulate the "w" mode in Java, we suppress the exception. // Likewise Windows returns ERROR_INVALID_FUNCTION in that case and // ERROR_INVALID_HANDLE on ttys. Identifying those by the IOException // message is tedious as their messages are localized, so we suppress them // all =[ if (Platform.IS_WINDOWS || ((Platform.IS_SOLARIS || Platform.IS_LINUX) && Errno.EINVAL.description().equals(ioe.getMessage()))) { return; } throw Py.IOError(ioe); }
// in src/org/python/core/io/FileIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/FileIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/FileIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/FileIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/FileIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/FileIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/FileIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/FileIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/FileIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/DatagramSocketIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/DatagramSocketIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/DatagramSocketIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/DatagramSocketIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/SocketIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/SocketIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/SocketIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/SocketIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/PyArray.java
catch(IOException e) { // discard anything successfully loaded delegate.setSize(origsize); throw Py.IOError(e); }
// in src/org/python/core/PyArray.java
catch(IOException e) { throw Py.IOError(e); }
// in src/org/python/core/PyFileReader.java
catch (IOException e) { throw Py.IOError(e); }
// in src/org/python/core/PyFileReader.java
catch (IOException e) { throw Py.IOError(e); }
// in src/org/python/core/PyFileReader.java
catch (IOException e) { throw Py.IOError(e); }
// in src/org/python/core/PyFileReader.java
catch (IOException e) { throw Py.IOError(e); }
// in src/org/python/core/__builtin__.java
catch (FileNotFoundException e) { throw Py.IOError(e); }
// in src/org/python/core/__builtin__.java
catch (IOException e) { throw Py.IOError(e); }
// in src/org/python/core/imp.java
catch(IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/imp.java
catch(IOException e) { throw Py.IOError(e); }
// in src/org/python/core/imp.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/util/JLineConsole.java
catch (IOException ioe) { if (!fromSuspend(ioe)) { throw Py.IOError(ioe); } // Hopefully an IOException caused by ctrl-z (seems only BSD throws this). // Must reset jline to continue try { reader.getTerminal().initializeTerminal(); } catch (Exception e) { throw Py.IOError(e.getMessage()); } // Don't redisplay the prompt promptString = ""; }
// in src/org/python/util/JLineConsole.java
catch (Exception e) { throw Py.IOError(e.getMessage()); }
// in src/org/python/util/jython.java
catch (IOException e) { throw Py.IOError(e); }
// in src/org/python/util/jython.java
catch (FileNotFoundException e) { throw Py.IOError(e); }
57
JavaError 35
                  
// in src/org/python/core/PyBeanProperty.java
catch (Exception e) { throw Py.JavaError(e); }
// in src/org/python/core/PyBeanProperty.java
catch (Throwable t) { throw Py.JavaError(t); }
// in src/org/python/core/PyBeanProperty.java
catch (Exception e) { throw Py.JavaError(e); }
// in src/org/python/core/PyObject.java
catch (Exception exc) { throw Py.JavaError(exc); }
// in src/org/python/core/PyReflectedConstructor.java
catch (Throwable t) { throw Py.JavaError(t); }
// in src/org/python/core/PyReflectedConstructor.java
catch (InvocationTargetException e) { if (e.getTargetException() instanceof InstantiationException) { Class<?> sup = proxy.getSuperclass(); String msg = "Constructor failed for Java superclass"; if (sup != null) { msg += " " + sup.getName(); } throw Py.TypeError(msg); } else throw Py.JavaError(e); }
// in src/org/python/core/PyReflectedConstructor.java
catch (Throwable t) { throw Py.JavaError(t); }
// in src/org/python/core/MakeProxies.java
catch (Exception exc) { throw Py.JavaError(exc); }
// in src/org/python/core/MakeProxies.java
catch (Exception exc) { throw Py.JavaError(exc); }
// in src/org/python/core/BytecodeLoader.java
catch (Exception e) { throw Py.JavaError(e); }
// in src/org/python/core/PyTableCode.java
catch (Throwable t) { // Convert exceptions that occured in Java code to PyExceptions PyException pye = Py.JavaError(t); pye.tracebackHere(frame); frame.f_lasti = -1; if (frame.tracefunc != null) { frame.tracefunc.traceException(frame, pye); } if (ts.profilefunc != null) { ts.profilefunc.traceException(frame, pye); } // Rethrow the exception to the next stack frame ts.exception = previous_exception; ts.frame = ts.frame.f_back; throw pye; }
// in src/org/python/core/PyReflectedField.java
catch (IllegalAccessException exc) { throw Py.JavaError(exc); }
// in src/org/python/core/PyReflectedField.java
catch (IllegalAccessException exc) { throw Py.JavaError(exc); }
// in src/org/python/core/PyReflectedFunction.java
catch (Exception e) { throw Py.JavaError(e); }
// in src/org/python/core/PyReflectedFunction.java
catch (Throwable t) { throw Py.JavaError(t); }
// in src/org/python/core/PyBeanEventProperty.java
catch (Exception exc) { throw Py.JavaError(exc); }
// in src/org/python/core/PyBeanEventProperty.java
catch (Exception e) { throw Py.JavaError(e); }
// in src/org/python/core/PyBeanEventProperty.java
catch (Exception exc) { throw Py.JavaError(exc); }
// in src/org/python/core/PyBeanEvent.java
catch (Exception e) { throw Py.JavaError(e); }
// in src/org/python/core/PyBaseCode.java
catch (Throwable t) { // Convert exceptions that occured in Java code to PyExceptions PyException pye = Py.JavaError(t); pye.tracebackHere(frame); frame.f_lasti = -1; if (frame.tracefunc != null) { frame.tracefunc.traceException(frame, pye); } if (ts.profilefunc != null) { ts.profilefunc.traceException(frame, pye); } // Rethrow the exception to the next stack frame ts.exception = previous_exception; ts.frame = ts.frame.f_back; throw pye; }
// in src/org/python/core/exceptions.java
catch (Exception e) { throw Py.JavaError(e); }
// in src/org/python/core/exceptions.java
catch (Throwable t) { throw Py.JavaError(t); }
// in src/org/python/core/PyType.java
catch (ExceptionInInitializerError e) { throw Py.JavaError(e); }
// in src/org/python/core/PyJavaType.java
catch (IllegalAccessException e) { throw Py.JavaError(e); }
// in src/org/python/core/PyJavaType.java
catch (Exception exc) { throw Py.JavaError(exc); }
// in src/org/python/core/PyJavaType.java
catch (Exception e) { throw Py.JavaError(e); }
// in src/org/python/core/Py.java
catch (NoSuchMethodException e) { throw Py.JavaError(e); }
// in src/org/python/core/Py.java
catch (IllegalArgumentException e) { throw JavaError(e); }
// in src/org/python/core/Py.java
catch (LinkageError e) { throw JavaError(e); }
// in src/org/python/core/Py.java
catch (Throwable t) { throw Py.JavaError(t); }
// in src/org/python/core/ParserFacade.java
catch (Throwable t) { if (bufReader == null) throw Py.JavaError(t); // can't do any more try { // then, try parsing as a module bufReader.reset(); return parse(bufReader, CompileMode.exec, filename, cflags); } catch (Throwable tt) { throw fixParseError(bufReader, tt, filename); } }
// in src/org/python/core/ClasspathPyImporter.java
catch (IOException e) { throw Py.JavaError(e); }
// in src/org/python/core/imp.java
catch (Throwable t) { if (testing) { return null; } else { throw Py.JavaError(t); } }
// in src/org/python/core/imp.java
catch (InstantiationException e) { throw Py.JavaError(e); }
// in src/org/python/core/imp.java
catch (IllegalAccessException e) { throw Py.JavaError(e); }
42
TypeError 33
                  
// in src/org/python/modules/binascii.java
catch (PyException e) { if (e.match(Py.AttributeError) || e.match(Py.ValueError)) throw Py.TypeError(errMsg); throw e; }
// in src/org/python/core/PyObject.java
catch (java.lang.InstantiationException e) { Class<?> sup = c.getSuperclass(); String msg = "Default constructor failed for Java superclass"; if (sup != null) { msg += " " + sup.getName(); } throw Py.TypeError(msg); }
// in src/org/python/core/PyObject.java
catch (NoSuchMethodError nsme) { throw Py.TypeError("constructor requires arguments"); }
// in src/org/python/core/PyObject.java
catch(PyObject.ConversionException e) { throw Py.TypeError("attribute name must be a string"); }
// in src/org/python/core/PyObject.java
catch (PyException pye) { if (pye.match(Py.AttributeError)) { throw Py.TypeError("an integer is required"); } throw pye; }
// in src/org/python/core/PyObject.java
catch (PyException pye) { if (pye.match(Py.AttributeError)) { throw Py.TypeError("an integer is required"); } throw pye; }
// in src/org/python/core/PyObject.java
catch (PyException pye) { if (pye.match(Py.AttributeError)) { throw Py.TypeError("a float is required"); } throw pye; }
// in src/org/python/core/PyStringMap.java
catch(PyException pye) { if (pye.match(Py.TypeError)) { throw Py.TypeError(String.format("cannot convert dictionary update sequence " + "element #%d to a sequence", i)); } throw pye; }
// in src/org/python/core/PyReflectedConstructor.java
catch (InvocationTargetException e) { if (e.getTargetException() instanceof InstantiationException) { Class<?> sup = proxy.getSuperclass(); String msg = "Constructor failed for Java superclass"; if (sup != null) { msg += " " + sup.getName(); } throw Py.TypeError(msg); } else throw Py.JavaError(e); }
// in src/org/python/core/PyDictionary.java
catch(PyException pye) { if (pye.match(Py.TypeError)) { throw Py.TypeError(String.format("cannot convert dictionary update sequence " + "element #%d to a sequence", i)); } throw pye; }
// in src/org/python/core/PyComplex.java
catch (PyException pye) { if (pye.match(Py.AttributeError)) { // __float__ not supported throw Py.TypeError("complex() argument must be a string or a number"); } throw pye; }
// in src/org/python/core/PyComplex.java
catch (PyException pye) { if (pye.match(Py.AttributeError)) { // __float__ not supported throw Py.TypeError("complex() argument must be a string or a number"); } throw pye; }
// in src/org/python/core/PyInstance.java
catch (PyException pye) { if (!pye.match(Py.AttributeError)) { throw pye; } throw Py.TypeError("object cannot be interpreted as an index"); }
// in src/org/python/core/AstList.java
catch (PyException pye) { if (pye.match(Py.TypeError)) { throw Py.TypeError("can only assign an iterable"); } throw pye; }
// in src/org/python/core/PyFloat.java
catch (PyException e) { if (e.match(Py.AttributeError)) { // Translate AttributeError to TypeError // XXX: We are using the same message as CPython, even if // it is not strictly correct (instances of types // that implement the __float__ method are also // valid arguments) throw Py.TypeError("float() argument must be a string or a number"); } throw e; }
// in src/org/python/core/PyArray.java
catch (ClassCastException e) { throw Py.TypeError("Type not compatible with array type"); }
// in src/org/python/core/PyArray.java
catch(ClassCastException e) { throw Py.TypeError("Type not compatible with array type"); }
// in src/org/python/core/PyArray.java
catch(ClassCastException e) { throw Py.TypeError("Type not compatible with array type"); }
// in src/org/python/core/PyArray.java
catch(ClassCastException e) { throw Py.TypeError("Type not compatible with array type"); }
// in src/org/python/core/PyArray.java
catch(ClassCastException e) { throw Py.TypeError("Type not compatible with array type"); }
// in src/org/python/core/PyArray.java
catch(IllegalArgumentException e) { throw Py.TypeError("Slice typecode '" + array.typecode + "' is not compatible with this array (typecode '" + this.typecode + "')"); }
// in src/org/python/core/__builtin__.java
catch (ClassCastException e) { throw Py.TypeError("apply() 3rd argument must be a " + "dictionary with string keys"); }
// in src/org/python/core/__builtin__.java
catch (ClassCastException e) { throw Py.TypeError(String.format("Expected keys() to be a list, not '%s'", retObj.getType().fastGetName())); }
// in src/org/python/core/__builtin__.java
catch (PyException e) { if (e.match(Py.AttributeError)) { throw Py.TypeError("vars() argument must have __dict__ attribute"); } throw e; }
// in src/org/python/core/PyJavaType.java
catch (Exception ex) { throw Py.TypeError("Could not copy Java object"); }
// in src/org/python/core/PyJavaType.java
catch (Exception ex) { throw Py.TypeError("Could not copy Java object"); }
// in src/org/python/core/Py.java
catch (PyException exc) { if (exc.match(Py.TypeError)) { throw Py.TypeError(message); } throw exc; }
// in src/org/python/core/PyInteger.java
catch (PyException pye) { if (!pye.match(Py.AttributeError)) { throw pye; } throw Py.TypeError("int() argument must be a string or a number"); }
// in src/org/python/core/PyLong.java
catch (PyException pye) { if (!pye.match(Py.AttributeError)) { throw pye; } throw Py.TypeError(String.format("long() argument must be a string or a number, " + "not '%.200s'", x.getType().fastGetName())); }
// in src/org/python/core/PyString.java
catch (IndexOutOfBoundsException e) { throw Py.TypeError( "translate() only works for 8-bit character strings"); }
// in src/org/python/core/PyString.java
catch (PyException e) { // XXX: Swallow customs AttributeError throws from __float__ methods // No better alternative for the moment if (e.match(Py.AttributeError)) { throw Py.TypeError("int argument required"); } throw e; }
// in src/org/python/core/PyString.java
catch (PyException pye) { throw !pye.match(Py.TypeError) ? pye : Py.TypeError("float argument required"); }
// in src/org/python/core/PyString.java
catch (PyException e){ if (e.match(Py.AttributeError)) { throw Py.TypeError("%c requires int or char"); } throw e; }
2501
getMessage 20
                  
// in src/com/ziclix/python/sql/DataHandler.java
catch (Exception e) { SQLException cause = null, ex = new SQLException("error setting index [" + index + "]"); if (e instanceof SQLException) { cause = (SQLException) e; } else { cause = new SQLException(e.getMessage()); } ex.setNextException(cause); throw ex; }
// in src/com/ziclix/python/sql/DataHandler.java
catch (Exception e) { SQLException cause = null, ex = new SQLException("error setting index [" + index + "], type [" + type + "]"); if (e instanceof SQLException) { cause = (SQLException) e; } else { cause = new SQLException(e.getMessage()); } ex.setNextException(cause); throw ex; }
// in src/com/ziclix/python/sql/DataHandler.java
catch (Throwable t) { SQLException cause = null; SQLException ex = new SQLException("error setting index [" + index + "], coltype [" + colType + "], datatype [" + dataType + "], datatypename [" + dataTypeName + "]"); if (t instanceof SQLException) { cause = (SQLException)t; } else { cause = new SQLException(t.getMessage()); } ex.setNextException(cause); throw ex; }
// in src/com/ziclix/python/sql/Jython22DataHandler.java
catch (Exception e) { SQLException cause = null, ex = new SQLException("error setting index [" + index + "]"); if (e instanceof SQLException) { cause = (SQLException) e; } else { cause = new SQLException(e.getMessage()); } ex.setNextException(cause); throw ex; }
// in src/com/ziclix/python/sql/Jython22DataHandler.java
catch (Exception e) { SQLException cause = null, ex = new SQLException("error setting index [" + index + "], type [" + type + "]"); if (e instanceof SQLException) { cause = (SQLException) e; } else { cause = new SQLException(e.getMessage()); } ex.setNextException(cause); throw ex; }
// in src/com/ziclix/python/sql/Jython22DataHandler.java
catch (Throwable t) { SQLException cause = null; SQLException ex = new SQLException("error setting index [" + index + "], coltype [" + colType + "], datatype [" + dataType + "], datatypename [" + dataTypeName + "]"); if (t instanceof SQLException) { cause = (SQLException)t; } else { cause = new SQLException(t.getMessage()); } ex.setNextException(cause); throw ex; }
// in src/org/python/compiler/Future.java
catch (ParseException pe) { throw new ParseException(pe.getMessage(), cand); }
// in src/org/python/expose/generate/ExposeTask.java
catch (InvalidExposingException iee) { throw new BuildException(iee.getMessage()); }
// in src/org/python/modules/random/PyRandom.java
catch (IOException e) { throw Py.SystemError("state vector invalid: "+e.getMessage()); }
// in src/org/python/modules/random/PyRandom.java
catch (ClassNotFoundException e) { throw Py.SystemError("state vector invalid: "+e.getMessage()); }
// in src/org/python/modules/random/PyRandom.java
catch (IOException e) { throw Py.SystemError("creation of state vector failed: "+ e.getMessage()); }
// in src/org/python/core/io/FileIO.java
catch (FileNotFoundException fnfe) { if (absPath.isDirectory()) { throw Py.IOError(Errno.EISDIR, name); } if ((writing && !absPath.canWrite()) || fnfe.getMessage().endsWith("(Permission denied)")) { throw Py.IOError(Errno.EACCES, name); } throw Py.IOError(Errno.ENOENT, name); }
// in src/org/python/core/io/FileIO.java
catch (IOException ioe) { // On Solaris and Linux, ftruncate(3C) returns EINVAL if not a regular // file whereas, e.g., open(os.devnull, "w") works. Because we have to // simulate the "w" mode in Java, we suppress the exception. // Likewise Windows returns ERROR_INVALID_FUNCTION in that case and // ERROR_INVALID_HANDLE on ttys. Identifying those by the IOException // message is tedious as their messages are localized, so we suppress them // all =[ if (Platform.IS_WINDOWS || ((Platform.IS_SOLARIS || Platform.IS_LINUX) && Errno.EINVAL.description().equals(ioe.getMessage()))) { return; } throw Py.IOError(ioe); }
// in src/org/python/core/stringlib/MarkupIterator.java
catch (IllegalArgumentException e) { throw Py.ValueError(e.getMessage()); }
// in src/org/python/core/PyInteger.java
catch (IllegalArgumentException e) { throw Py.ValueError(e.getMessage()); }
// in src/org/python/core/PyString.java
catch (IllegalArgumentException e) { throw Py.ValueError(e.getMessage()); }
// in src/org/python/core/PyString.java
catch (IllegalArgumentException e) { throw Py.ValueError(e.getMessage()); }
// in src/org/python/core/imp.java
catch (IOException ioe) { if (!testing) { throw Py.ImportError(ioe.getMessage() + "[name=" + name + ", source=" + sourceName + ", compiled=" + compiledName + "]"); } }
// in src/org/python/core/util/importer.java
catch (IOException ioe) { throw Py.ImportError(ioe.getMessage() + "[path=" + fullSearchPath + "]"); }
// in src/org/python/util/JLineConsole.java
catch (IOException ioe) { if (!fromSuspend(ioe)) { throw Py.IOError(ioe); } // Hopefully an IOException caused by ctrl-z (seems only BSD throws this). // Must reset jline to continue try { reader.getTerminal().initializeTerminal(); } catch (Exception e) { throw Py.IOError(e.getMessage()); } // Don't redisplay the prompt promptString = ""; }
// in src/org/python/util/JLineConsole.java
catch (Exception e) { throw Py.IOError(e.getMessage()); }
28
println 18
                  
// in src/com/xhaus/modjy/ModjyJServlet.java
catch (IOException iox) { System.err.println("IOException: " + iox.toString()); }
// in src/org/python/indexer/demos/StyleApplier.java
catch (RuntimeException x) { System.err.println("Warning: " + x); }
// in src/org/python/indexer/demos/Styler.java
catch (StringIndexOutOfBoundsException sx) { System.out.println("whoops: beg=" + a + ", end=" + b + ", len=" + source.length()); return ""; }
// in src/org/python/indexer/demos/Linker.java
catch (Exception x) { System.err.println("path problem: dest=" + destPath + ", root=" + rootPath + ": " + x); return null; }
// in src/org/python/Version.java
catch (IOException ioe) { System.err.println("There was a problem loading ".concat(versionProperties) .concat(":")); ioe.printStackTrace(); }
// in src/org/python/antlr/BaseParser.java
catch (RecognitionException e) { //I am only throwing ParseExceptions, but "throws RecognitionException" still gets //into the generated code. System.err.println("FIXME: pretty sure this can't happen -- but needs to be checked"); }
// in src/org/python/modules/thread/PyLock.java
catch (InterruptedException e) { System.err.println("Interrupted thread"); }
// in src/org/python/core/PyObject.java
catch (PyException e) { if (e.value.getJavaProxy() != null) { Object t = e.value.__tojava__(Throwable.class); if (t != null && t != Py.NoConversion) { throw (Throwable) t; } } else { ThreadState ts = Py.getThreadState(); if (ts.frame == null) { Py.maybeSystemExit(e); } if (Options.showPythonProxyExceptions) { Py.stderr.println( "Exception in Python proxy returning to Java:"); Py.printException(e); } } throw e; }
// in src/org/python/core/FunctionThread.java
catch (PyException exc) { if (exc.match(Py.SystemExit) || exc.match(_systemrestart.SystemRestart)) { return; } Py.stderr.println("Unhandled exception in thread started by " + func); Py.printException(exc); }
// in src/org/python/core/PySystemState.java
catch (PyException exc) { if (!exc.match(Py.SystemExit)) { Py.println(stderr, Py.newString("Error in sys.exitfunc:")); } Py.printException(exc); }
// in src/org/python/core/PySystemState.java
catch (IOException e) { System.err.println("couldn't open registry file: " + file.toString()); }
// in src/org/python/core/Py.java
catch (PyException exc2) { exc2.normalize(); flushLine(); stderr.println("Error in sys.excepthook:"); displayException(exc2.type, exc2.value, exc2.traceback, file); stderr.println(); stderr.println("Original exception was:"); displayException(exc.type, exc.value, exc.traceback, file); }
// in src/org/python/core/PyBytecode.java
catch (Throwable t) { PyException pye = Py.setException(t, f); why = Why.EXCEPTION; ts.exception = pye; if (debug) { System.err.println("Caught exception:" + pye); } }
// in src/org/python/core/PyGenerator.java
catch (PyException pye) { // PEP 342 specifies that if an exception is raised by close, // we output to stderr and then forget about it; String className = PyException.exceptionClassName(pye.type); int lastDot = className.lastIndexOf('.'); if (lastDot != -1) { className = className.substring(lastDot + 1); } String msg = String.format("Exception %s: %s in %s", className, pye.value.__repr__(), __repr__()); Py.println(Py.getSystemState().stderr, Py.newString(msg)); }
// in src/org/python/util/JLineConsole.java
catch (Exception ex) { System.err.println(ex); }
// in src/org/python/util/jython.java
catch (PyException pye) { if (!pye.match(Py.ImportError)) { System.err.println("error importing site"); Py.printException(pye); System.exit(-1); } }
77
ValueError 15
                  
// in src/org/python/modules/posix/PosixModule.java
catch (ClosedChannelException cce) { // In the rare case it's closed but the rawIO wasn't throw Py.ValueError("I/O operation on closed file"); }
// in src/org/python/modules/cPickle.java
catch(NumberFormatException e) { try { value = Py.newLong(line); } catch(NumberFormatException e2) { throw Py.ValueError("could not convert string to int"); } }
// in src/org/python/modules/cPickle.java
catch(NumberFormatException e2) { throw Py.ValueError("could not convert string to int"); }
// in src/org/python/modules/itertools.java
catch (PyException pyEx) { if (pyEx.match(Py.TypeError)) { throw Py.ValueError(msg); } else { throw pyEx; } }
// in src/org/python/modules/_hashlib.java
catch (NoSuchAlgorithmException nsae) { throw Py.ValueError("unsupported hash type"); }
// in src/org/python/core/PyList.java
catch (ConcurrentModificationException ex) { throw Py.ValueError(message); }
// in src/org/python/core/stringlib/MarkupIterator.java
catch (IllegalArgumentException e) { throw Py.ValueError(e.getMessage()); }
// in src/org/python/core/PyInteger.java
catch (IllegalArgumentException e) { throw Py.ValueError(e.getMessage()); }
// in src/org/python/core/PyString.java
catch (NumberFormatException exc) { throw Py.ValueError("invalid literal for __float__: "+getString()); }
// in src/org/python/core/PyString.java
catch (NumberFormatException exc) { throw Py.ValueError("invalid literal for int() with base " + base + ": " + getString()); }
// in src/org/python/core/PyString.java
catch (StringIndexOutOfBoundsException exc) { throw Py.ValueError("invalid literal for int() with base " + base + ": " + getString()); }
// in src/org/python/core/PyString.java
catch (NumberFormatException exc) { if (this instanceof PyUnicode) { // TODO: here's a basic issue: do we use the BigInteger constructor // above, or add an equivalent to CPython's PyUnicode_EncodeDecimal; // we should note that the current error string does not quite match // CPython regardless of the codec, that's going to require some more work throw Py.UnicodeEncodeError("decimal", "codec can't encode character", 0,0, "invalid decimal Unicode string"); } else { throw Py.ValueError("invalid literal for long() with base " + base + ": " + getString()); } }
// in src/org/python/core/PyString.java
catch (StringIndexOutOfBoundsException exc) { throw Py.ValueError("invalid literal for long() with base " + base + ": " + getString()); }
// in src/org/python/core/PyString.java
catch (IllegalArgumentException e) { throw Py.ValueError(e.getMessage()); }
// in src/org/python/core/PyString.java
catch (IllegalArgumentException e) { throw Py.ValueError(e.getMessage()); }
// in src/org/python/core/PyString.java
catch (StringIndexOutOfBoundsException e) { throw Py.ValueError("incomplete format"); }
146
toString 14
                  
// in src/com/xhaus/modjy/ModjyJServlet.java
catch (PyException pyx) { throw new ServletException("Exception creating modjy servlet: " + pyx.toString(), pyx); }
// in src/com/xhaus/modjy/ModjyJServlet.java
catch (IOException iox) { System.err.println("IOException: " + iox.toString()); }
// in src/org/python/modules/zipimport/zipimporter.java
catch (IOException ioe) { Py.writeDebug("import", "zipimporter.getDataStream exception: " + ioe.toString()); throw zipimport.ZipImportError("zipimport: can not open file: " + archive); }
// in src/org/python/core/PySystemState.java
catch (IOException e) { System.err.println("couldn't open registry file: " + file.toString()); }
// in src/org/python/core/Py.java
catch (PyException pye) { if (!pye.match(TypeError)) { throw pye; } pye.value = Py.newString(String.format("Error when calling the metaclass bases\n " + "%s", pye.value.__str__().toString())); throw pye; }
// in src/org/python/core/codecs.java
catch (PyException ex) { if (ex.match(Py.LookupError)) { // If we couldn't find an encoding, see if we have a builtin if (encoding.equals("utf-8")) { return wrapDecodeResult(PyUnicode_DecodeUTF8(v.toString(), errors)); } else if(encoding.equals("utf-7")) { return wrapDecodeResult(PyUnicode_DecodeUTF7(v.toString(), errors)); } else if(encoding.equals("latin-1")) { return wrapDecodeResult(PyUnicode_DecodeLatin1(v.toString(), v.__len__(), errors)); } } throw ex; }
// in src/org/python/core/codecs.java
catch (PyException ex) { if (ex.match(Py.LookupError)) { // If we couldn't find an encoding, see if we have a builtin if (encoding.equals("utf-8")) { return PyUnicode_EncodeUTF8(v.toString(), errors); } else if(encoding.equals("utf-7")) { return codecs.PyUnicode_EncodeUTF7(v.toString(), false, false, errors); } } throw ex; }
// in src/org/python/core/packagecache/CachedJarsPackageManager.java
catch (IOException ioe) { // silently skip any bad directories warning("skipping bad jar, '" + (jarfile != null ? jarfile.toString() : jarurl.toString()) + "'"); }
// in src/org/python/util/TemplateAntTask.java
catch(IOException e2) { throw new BuildException(e2.toString(), e2); }
// in src/org/python/util/JythoncAntTask.java
catch (Exception e) { // Have to catch this because of the semantics of calling main() String msg = "Exception while calling " + JYTHON_CLASS + ". Details: " + e.toString(); throw new BuildException(msg, e); }
771
format 12
                  
// in src/com/ziclix/python/sql/PyConnection.java
catch (SQLException e) { return String.format("<PyConnection object at %s", Py.idstr(this)); }
// in src/org/python/modules/zipimport/zipimporter.java
catch (IOException ioe) { throw zipimport.ZipImportError(String.format("can't read Zip file: '%s'", archive)); }
// in src/org/python/modules/_hashlib.java
catch (CloneNotSupportedException cnse) { throw Py.RuntimeError(String.format("_hashlib.HASH (%s) internal error", name)); }
// in src/org/python/core/PyStringMap.java
catch(PyException pye) { if (pye.match(Py.TypeError)) { throw Py.TypeError(String.format("cannot convert dictionary update sequence " + "element #%d to a sequence", i)); } throw pye; }
// in src/org/python/core/PyDictionary.java
catch(PyException pye) { if (pye.match(Py.TypeError)) { throw Py.TypeError(String.format("cannot convert dictionary update sequence " + "element #%d to a sequence", i)); } throw pye; }
// in src/org/python/core/PyFrame.java
catch (PyException pye) { if (pye.match(Py.KeyError)) { throw Py.NameError(String.format(NAME_ERROR_MSG, index)); } throw pye; }
// in src/org/python/core/PyFrame.java
catch (PyException pye) { if (pye.match(Py.KeyError)) { throw Py.NameError(String.format(GLOBAL_NAME_ERROR_MSG, index)); } throw pye; }
// in src/org/python/core/__builtin__.java
catch (ClassCastException e) { throw Py.TypeError(String.format("Expected keys() to be a list, not '%s'", retObj.getType().fastGetName())); }
// in src/org/python/core/Py.java
catch (PyException pye) { if (!pye.match(TypeError)) { throw pye; } pye.value = Py.newString(String.format("Error when calling the metaclass bases\n " + "%s", pye.value.__str__().toString())); throw pye; }
// in src/org/python/core/PyBytecode.java
catch (PyException pye) { if (pye.match(Py.AttributeError)) { throw Py.ImportError(String.format("cannot import name %.230s", name)); } else { throw pye; } }
// in src/org/python/core/PyLong.java
catch (PyException pye) { if (!pye.match(Py.AttributeError)) { throw pye; } throw Py.TypeError(String.format("long() argument must be a string or a number, " + "not '%.200s'", x.getType().fastGetName())); }
// in src/org/python/core/PyGenerator.java
catch (PyException pye) { // PEP 342 specifies that if an exception is raised by close, // we output to stderr and then forget about it; String className = PyException.exceptionClassName(pye.type); int lastDot = className.lastIndexOf('.'); if (lastDot != -1) { className = className.substring(lastDot + 1); } String msg = String.format("Exception %s: %s in %s", className, pye.value.__repr__(), __repr__()); Py.println(Py.getSystemState().stderr, Py.newString(msg)); }
614
printException 10
                  
// in src/org/python/core/PyObject.java
catch (PyException e) { if (e.value.getJavaProxy() != null) { Object t = e.value.__tojava__(Throwable.class); if (t != null && t != Py.NoConversion) { throw (Throwable) t; } } else { ThreadState ts = Py.getThreadState(); if (ts.frame == null) { Py.maybeSystemExit(e); } if (Options.showPythonProxyExceptions) { Py.stderr.println( "Exception in Python proxy returning to Java:"); Py.printException(e); } } throw e; }
// in src/org/python/core/FunctionThread.java
catch (PyException exc) { if (exc.match(Py.SystemExit) || exc.match(_systemrestart.SystemRestart)) { return; } Py.stderr.println("Unhandled exception in thread started by " + func); Py.printException(exc); }
// in src/org/python/core/PySystemState.java
catch (PyException exc) { if (!exc.match(Py.SystemExit)) { Py.println(stderr, Py.newString("Error in sys.exitfunc:")); } Py.printException(exc); }
// in src/org/python/util/jython.java
catch (PyException pye) { if (!pye.match(Py.ImportError)) { System.err.println("error importing site"); Py.printException(pye); System.exit(-1); } }
// in src/org/python/util/jython.java
catch (Throwable t) { Py.printException(t); System.exit(-1); }
// in src/org/python/util/jython.java
catch (Throwable t) { Py.printException(t); }
// in src/org/python/util/jython.java
catch (Throwable t) { if (t instanceof PyException && ((PyException)t).match(_systemrestart.SystemRestart)) { // Shutdown this instance... shouldRestart = true; shutdownInterpreter(); interp.cleanup(); // ..reset the state... Py.setSystemState(new PySystemState()); // ...and start again return; } else { Py.printException(t); interp.cleanup(); System.exit(-1); } }
// in src/org/python/util/jython.java
catch (Throwable t) { Py.printException(t); System.exit(1); }
// in src/org/python/util/jython.java
catch (Throwable t) { Py.printException(t); interp.cleanup(); System.exit(-1); }
// in src/org/python/util/jython.java
catch (Throwable t) { Py.printException(t); }
14
getString 9
                  
// in src/com/ziclix/python/sql/Fetch.java
catch (AbstractMethodError e) { throw zxJDBC.makeException(zxJDBC.NotSupportedError, zxJDBC.getString("nodynamiccursors")); }
// in src/com/ziclix/python/sql/Fetch.java
catch (AbstractMethodError e) { throw zxJDBC.makeException(zxJDBC.NotSupportedError, zxJDBC.getString("nodynamiccursors")); }
// in src/com/ziclix/python/sql/PyStatement.java
catch (PyException e) { throw zxJDBC.makeException(zxJDBC.ProgrammingError, zxJDBC.getString("bindingValue")); }
// in src/com/ziclix/python/sql/PyCursor.java
catch (AbstractMethodError e) { throw zxJDBC.makeException(zxJDBC.NotSupportedError, zxJDBC.getString("nodynamiccursors")); }
// in src/org/python/core/PyString.java
catch (NumberFormatException exc) { throw Py.ValueError("invalid literal for __float__: "+getString()); }
// in src/org/python/core/PyString.java
catch (NumberFormatException exc) { throw Py.ValueError("invalid literal for int() with base " + base + ": " + getString()); }
// in src/org/python/core/PyString.java
catch (StringIndexOutOfBoundsException exc) { throw Py.ValueError("invalid literal for int() with base " + base + ": " + getString()); }
// in src/org/python/core/PyString.java
catch (NumberFormatException exc) { if (this instanceof PyUnicode) { // TODO: here's a basic issue: do we use the BigInteger constructor // above, or add an equivalent to CPython's PyUnicode_EncodeDecimal; // we should note that the current error string does not quite match // CPython regardless of the codec, that's going to require some more work throw Py.UnicodeEncodeError("decimal", "codec can't encode character", 0,0, "invalid decimal Unicode string"); } else { throw Py.ValueError("invalid literal for long() with base " + base + ": " + getString()); } }
// in src/org/python/core/PyString.java
catch (StringIndexOutOfBoundsException exc) { throw Py.ValueError("invalid literal for long() with base " + base + ": " + getString()); }
304
printStackTrace 9
                  
// in src/org/python/Version.java
catch (IOException ioe) { System.err.println("There was a problem loading ".concat(versionProperties) .concat(":")); ioe.printStackTrace(); }
// in src/org/python/antlr/AnalyzingParser.java
catch (Exception x) { x.printStackTrace(); }
// in src/org/python/core/PySystemState.java
catch (UnsupportedCharsetException e) { Py.writeWarning("initializer", "Unable to load the UTF-8 charset to read an initializer definition"); e.printStackTrace(System.err); }
// in src/org/python/core/PySystemState.java
catch (Exception e) { Py.writeWarning("initializer", "Unexpected exception thrown while trying to use initializer service"); e.printStackTrace(System.err); }
// in src/org/python/core/PySystemState.java
catch (IOException e) { Py.writeWarning("initializer", "Failed reading '" + INITIALIZER_SERVICE + "' from " + initializerClassLoader); e.printStackTrace(System.err); return false; }
// in src/org/python/core/PySystemState.java
catch (Exception e) { Py.writeWarning("initializer", "Failed initializing with class '" + className + "', continuing"); e.printStackTrace(System.err); return false; }
// in src/org/python/core/Py.java
catch (Throwable t) { t.printStackTrace(); }
// in src/org/python/util/JycompileAntTask.java
catch (PyException pye) { pye.printStackTrace(); throw new BuildException("Compile failed; see the compiler error output for details."); }
// in src/org/python/util/JLineConsole.java
catch (FileNotFoundException fnfe) { // Shouldn't really ever happen fnfe.printStackTrace(); }
16
fixParseError
8
                  
// in src/org/python/compiler/ScopesCompiler.java
catch (Throwable t) { throw ParserFacade.fixParseError(null, t, code_compiler.getFilename()); }
// in src/org/python/core/CompilerFacade.java
catch (Throwable t) { throw ParserFacade.fixParseError(null, t, filename); }
// in src/org/python/core/ParserFacade.java
catch (Throwable t) { if (bufReader == null) throw Py.JavaError(t); // can't do any more try { // then, try parsing as a module bufReader.reset(); return parse(bufReader, CompileMode.exec, filename, cflags); } catch (Throwable tt) { throw fixParseError(bufReader, tt, filename); } }
// in src/org/python/core/ParserFacade.java
catch (Throwable tt) { throw fixParseError(bufReader, tt, filename); }
// in src/org/python/core/ParserFacade.java
catch (Throwable t) { throw fixParseError(bufReader, t, filename); }
// in src/org/python/core/ParserFacade.java
catch (Throwable t) { throw fixParseError(bufReader, t, filename); }
// in src/org/python/core/ParserFacade.java
catch (Throwable t) { throw fixParseError(bufReader, t, filename); }
// in src/org/python/core/ParserFacade.java
catch (Throwable t) { PyException p = fixParseError(reader, t, filename); if (reader != null && validPartialSentence(reader, kind, filename)) { return null; } throw p; }
// in src/org/python/core/imp.java
catch(Throwable t) { throw ParserFacade.fixParseError(null, t, filename); }
8
equals 7
                  
// in src/org/python/core/ContextGuard.java
catch(PyException e) { if (e.equals(exception)) { return false; } else { throw e; } }
// in src/org/python/core/io/FileIO.java
catch (IOException ioe) { // On Solaris and Linux, ftruncate(3C) returns EINVAL if not a regular // file whereas, e.g., open(os.devnull, "w") works. Because we have to // simulate the "w" mode in Java, we suppress the exception. // Likewise Windows returns ERROR_INVALID_FUNCTION in that case and // ERROR_INVALID_HANDLE on ttys. Identifying those by the IOException // message is tedious as their messages are localized, so we suppress them // all =[ if (Platform.IS_WINDOWS || ((Platform.IS_SOLARIS || Platform.IS_LINUX) && Errno.EINVAL.description().equals(ioe.getMessage()))) { return; } throw Py.IOError(ioe); }
// in src/org/python/core/codecs.java
catch (PyException ex) { if (ex.match(Py.LookupError)) { // If we couldn't find an encoding, see if we have a builtin if (encoding.equals("utf-8")) { return wrapDecodeResult(PyUnicode_DecodeUTF8(v.toString(), errors)); } else if(encoding.equals("utf-7")) { return wrapDecodeResult(PyUnicode_DecodeUTF7(v.toString(), errors)); } else if(encoding.equals("latin-1")) { return wrapDecodeResult(PyUnicode_DecodeLatin1(v.toString(), v.__len__(), errors)); } } throw ex; }
// in src/org/python/core/codecs.java
catch (PyException ex) { if (ex.match(Py.LookupError)) { // If we couldn't find an encoding, see if we have a builtin if (encoding.equals("utf-8")) { return PyUnicode_EncodeUTF8(v.toString(), errors); } else if(encoding.equals("utf-7")) { return codecs.PyUnicode_EncodeUTF7(v.toString(), false, false, errors); } } throw ex; }
332
close 6
                  
// in src/com/ziclix/python/sql/pipe/Pipe.java
catch (InterruptedException e) { queue.close(); throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/pipe/Pipe.java
catch (InterruptedException e) { queue.close(); throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/pipe/Pipe.java
catch (Throwable e) { this.exception = e.fillInStackTrace(); this.queue.close(); }
// in src/com/ziclix/python/sql/Procedure.java
catch (SQLException e) { if (statement != null) { try { statement.close(); } catch (Exception ex) { } } throw e; }
// in src/com/ziclix/python/sql/PyCursor.java
catch (Throwable t) { if (statement != null) { statement.close(); } throw zxJDBC.makeException(t); }
// in src/com/ziclix/python/sql/PyCursor.java
catch (Throwable t) { if (statement != null && !(sql instanceof PyStatement)) { // only close static, single-use statements statement.close(); } throw zxJDBC.makeException(zxJDBC.Error, t, rowIndex); }
90
scriptException
6
                  
// in src/org/python/jsr223/PyScriptEngine.java
catch (PyException pye) { throw scriptException(pye); }
// in src/org/python/jsr223/PyScriptEngine.java
catch (PyException pye) { throw scriptException(pye); }
// in src/org/python/jsr223/PyScriptEngine.java
catch (PyException pye) { throw scriptException(pye); }
// in src/org/python/jsr223/PyScriptEngine.java
catch (PyException pye) { throw scriptException(pye); }
// in src/org/python/jsr223/PyScriptEngine.java
catch (PyException pye) { throw scriptException(pye); }
// in src/org/python/jsr223/PyScriptEngine.java
catch (PyException pye) { throw scriptException(pye); }
6
setNextException
6
                  
// in src/com/ziclix/python/sql/DataHandler.java
catch (Exception e) { SQLException cause = null, ex = new SQLException("error setting index [" + index + "]"); if (e instanceof SQLException) { cause = (SQLException) e; } else { cause = new SQLException(e.getMessage()); } ex.setNextException(cause); throw ex; }
// in src/com/ziclix/python/sql/DataHandler.java
catch (Exception e) { SQLException cause = null, ex = new SQLException("error setting index [" + index + "], type [" + type + "]"); if (e instanceof SQLException) { cause = (SQLException) e; } else { cause = new SQLException(e.getMessage()); } ex.setNextException(cause); throw ex; }
// in src/com/ziclix/python/sql/DataHandler.java
catch (Throwable t) { SQLException cause = null; SQLException ex = new SQLException("error setting index [" + index + "], coltype [" + colType + "], datatype [" + dataType + "], datatypename [" + dataTypeName + "]"); if (t instanceof SQLException) { cause = (SQLException)t; } else { cause = new SQLException(t.getMessage()); } ex.setNextException(cause); throw ex; }
// in src/com/ziclix/python/sql/Jython22DataHandler.java
catch (Exception e) { SQLException cause = null, ex = new SQLException("error setting index [" + index + "]"); if (e instanceof SQLException) { cause = (SQLException) e; } else { cause = new SQLException(e.getMessage()); } ex.setNextException(cause); throw ex; }
// in src/com/ziclix/python/sql/Jython22DataHandler.java
catch (Exception e) { SQLException cause = null, ex = new SQLException("error setting index [" + index + "], type [" + type + "]"); if (e instanceof SQLException) { cause = (SQLException) e; } else { cause = new SQLException(e.getMessage()); } ex.setNextException(cause); throw ex; }
// in src/com/ziclix/python/sql/Jython22DataHandler.java
catch (Throwable t) { SQLException cause = null; SQLException ex = new SQLException("error setting index [" + index + "], coltype [" + colType + "], datatype [" + dataType + "], datatypename [" + dataTypeName + "]"); if (t instanceof SQLException) { cause = (SQLException)t; } else { cause = new SQLException(t.getMessage()); } ex.setNextException(cause); throw ex; }
6
warning 6
                  
// in src/org/python/core/packagecache/PathPackageManager.java
catch (IOException e) { warning("skipping bad directory, '" + dir + "'"); }
// in src/org/python/core/packagecache/CachedJarsPackageManager.java
catch (IOException ioe) { // silently skip any bad directories warning("skipping bad jar, '" + (jarfile != null ? jarfile.toString() : jarurl.toString()) + "'"); }
// in src/org/python/core/packagecache/CachedJarsPackageManager.java
catch (IOException ioe) { warning("can't write cache file for '" + jarcanon + "'"); }
// in src/org/python/core/packagecache/CachedJarsPackageManager.java
catch (IOException ioe) { warning("invalid index file"); }
// in src/org/python/core/packagecache/CachedJarsPackageManager.java
catch (IOException ioe) { warning("can't write index file"); }
// in src/org/python/core/packagecache/CachedJarsPackageManager.java
catch(AccessControlException ace) { warning("The java security manager isn't allowing access to the package cache dir, '" + aCachedir1 + "'"); return false; }
42
OSError 5
                  
// in src/org/python/modules/posix/PosixModule.java
catch (PyException pye) { if (!pye.match(Py.IOError)) { throw pye; } throw Py.OSError(Errno.EINVAL); }
// in src/org/python/modules/posix/PosixModule.java
catch (IOException ioe) { throw Py.OSError(ioe); }
// in src/org/python/modules/posix/PosixModule.java
catch (IOException ioe) { throw Py.OSError(ioe); }
// in src/org/python/modules/posix/PosixModule.java
catch (FileNotFoundException fnfe) { throw Py.OSError(file.isDirectory() ? Errno.EISDIR : Errno.ENOENT, path); }
// in src/org/python/modules/posix/PosixModule.java
catch (IOException ioe) { throw Py.OSError(ioe); }
22
exit 5
                  
// in src/org/python/util/jython.java
catch (PyException pye) { if (!pye.match(Py.ImportError)) { System.err.println("error importing site"); Py.printException(pye); System.exit(-1); } }
// in src/org/python/util/jython.java
catch (Throwable t) { Py.printException(t); System.exit(-1); }
// in src/org/python/util/jython.java
catch (Throwable t) { if (t instanceof PyException && ((PyException)t).match(_systemrestart.SystemRestart)) { // Shutdown this instance... shouldRestart = true; shutdownInterpreter(); interp.cleanup(); // ..reset the state... Py.setSystemState(new PySystemState()); // ...and start again return; } else { Py.printException(t); interp.cleanup(); System.exit(-1); } }
// in src/org/python/util/jython.java
catch (Throwable t) { Py.printException(t); System.exit(1); }
// in src/org/python/util/jython.java
catch (Throwable t) { Py.printException(t); interp.cleanup(); System.exit(-1); }
17
writeDebug 5
                  
// in src/org/python/modules/zipimport/zipimporter.java
catch (IOException ioe) { Py.writeDebug("import", "zipimporter.getDataStream exception: " + ioe.toString()); throw zipimport.ZipImportError("zipimport: can not open file: " + archive); }
// in src/org/python/core/PySystemState.java
catch (SecurityException se) { Py.writeDebug("PySystemState", "Can't register cleanup closer hook"); return null; }
// in src/org/python/core/imp.java
catch(IOException exc) { // If we can't write the cache file, just log and continue Py.writeDebug(IMPORT_LOG, "Unable to write to source cache file '" + compiledFilename + "' due to " + exc); return null; }
// in src/org/python/core/imp.java
catch(SecurityException exc) { // If we can't write the cache file, just log and continue Py.writeDebug(IMPORT_LOG, "Unable to write to source cache file '" + compiledFilename + "' due to " + exc); return null; }
// in src/org/python/core/imp.java
catch(IOException e) { Py.writeDebug(IMPORT_LOG, "Unable to close source cache file '" + compiledFilename + "' due to " + e); }
26
writeWarning 5
                  
// in src/org/python/core/PySystemState.java
catch (UnsupportedCharsetException e) { Py.writeWarning("initializer", "Unable to load the UTF-8 charset to read an initializer definition"); e.printStackTrace(System.err); }
// in src/org/python/core/PySystemState.java
catch (Exception e) { Py.writeWarning("initializer", "Unexpected exception thrown while trying to use initializer service"); e.printStackTrace(System.err); }
// in src/org/python/core/PySystemState.java
catch (IOException e) { Py.writeWarning("initializer", "Failed reading '" + INITIALIZER_SERVICE + "' from " + initializerClassLoader); e.printStackTrace(System.err); return false; }
// in src/org/python/core/PySystemState.java
catch (ClassNotFoundException e) { Py.writeWarning("initializer", "Specified initializer class '" + className + "' not found, continuing"); return false; }
// in src/org/python/core/PySystemState.java
catch (Exception e) { Py.writeWarning("initializer", "Failed initializing with class '" + className + "', continuing"); e.printStackTrace(System.err); return false; }
10
ImportError 4
                  
// in src/org/python/core/PyBytecode.java
catch (PyException pye) { if (pye.match(Py.AttributeError)) { throw Py.ImportError(String.format("cannot import name %.230s", name)); } else { throw pye; } }
// in src/org/python/core/imp.java
catch (IOException ioe) { if (!testing) { throw Py.ImportError(ioe.getMessage() + "[name=" + name + ", source=" + sourceName + ", compiled=" + compiledName + "]"); } }
// in src/org/python/core/imp.java
catch (NoClassDefFoundError e) { throw Py.ImportError("Cannot import " + name + ", missing class " + c.getName()); }
// in src/org/python/core/util/importer.java
catch (IOException ioe) { throw Py.ImportError(ioe.getMessage() + "[path=" + fullSearchPath + "]"); }
17
SystemError 4
                  
// in src/org/python/modules/random/PyRandom.java
catch (IOException e) { throw Py.SystemError("state vector invalid: "+e.getMessage()); }
// in src/org/python/modules/random/PyRandom.java
catch (ClassNotFoundException e) { throw Py.SystemError("state vector invalid: "+e.getMessage()); }
// in src/org/python/modules/random/PyRandom.java
catch (IOException e) { throw Py.SystemError("creation of state vector failed: "+ e.getMessage()); }
// in src/org/python/core/util/StringUtil.java
catch(UnsupportedEncodingException uee) { // This JVM is whacked, it doesn't even have iso-8859-1 throw Py.SystemError("Java couldn't find the ISO-8859-1 encoding"); }
14
badFD 4
                  
// in src/org/python/modules/posix/PosixModule.java
catch (PyException pye) { throw badFD(); }
// in src/org/python/modules/posix/PosixModule.java
catch (PyException pye) { throw badFD(); }
// in src/org/python/modules/posix/PosixModule.java
catch (PyException pye) { throw badFD(); }
// in src/org/python/modules/posix/PosixModule.java
catch (PyException pye) { throw badFD(); }
5
getName 4
                  
// in src/org/python/core/PyObject.java
catch (java.lang.InstantiationException e) { Class<?> sup = c.getSuperclass(); String msg = "Default constructor failed for Java superclass"; if (sup != null) { msg += " " + sup.getName(); } throw Py.TypeError(msg); }
// in src/org/python/core/PyReflectedConstructor.java
catch (InvocationTargetException e) { if (e.getTargetException() instanceof InstantiationException) { Class<?> sup = proxy.getSuperclass(); String msg = "Constructor failed for Java superclass"; if (sup != null) { msg += " " + sup.getName(); } throw Py.TypeError(msg); } else throw Py.JavaError(e); }
// in src/org/python/core/AbstractArray.java
catch (ArrayStoreException e) { throw new IllegalArgumentException("'ofArrayType' must be compatible with existing array type of " + getArray().getClass().getName() + "\tsee java.lang.Class.getName()."); }
// in src/org/python/core/imp.java
catch (NoClassDefFoundError e) { throw Py.ImportError("Cannot import " + name + ", missing class " + c.getName()); }
399
traceException 4
                  
// in src/org/python/core/PyTableCode.java
catch (Throwable t) { // Convert exceptions that occured in Java code to PyExceptions PyException pye = Py.JavaError(t); pye.tracebackHere(frame); frame.f_lasti = -1; if (frame.tracefunc != null) { frame.tracefunc.traceException(frame, pye); } if (ts.profilefunc != null) { ts.profilefunc.traceException(frame, pye); } // Rethrow the exception to the next stack frame ts.exception = previous_exception; ts.frame = ts.frame.f_back; throw pye; }
// in src/org/python/core/PyBaseCode.java
catch (Throwable t) { // Convert exceptions that occured in Java code to PyExceptions PyException pye = Py.JavaError(t); pye.tracebackHere(frame); frame.f_lasti = -1; if (frame.tracefunc != null) { frame.tracefunc.traceException(frame, pye); } if (ts.profilefunc != null) { ts.profilefunc.traceException(frame, pye); } // Rethrow the exception to the next stack frame ts.exception = previous_exception; ts.frame = ts.frame.f_back; throw pye; }
5
AttributeError 3
                  
// in src/org/python/core/PySystemState.java
catch (PyException pye) { // KeyError if (ret == null) { throw Py.AttributeError(name); } }
// in src/org/python/core/PyInstance.java
catch (PyException exc) { if (exc.match(Py.KeyError)) throw Py.AttributeError("class " + instclass.__name__ + " has no attribute '" + name + "'"); }
// in src/org/python/core/PyBeanEventProperty.java
catch (NoSuchFieldException exc) { throw Py.AttributeError("Internal bean event error: " + __name__); }
31
ZipImportError 3
                  
// in src/org/python/modules/zipimport/zipimporter.java
catch (IOException ioe) { throw zipimport.ZipImportError("zipimport: can not open file: " + archive); }
// in src/org/python/modules/zipimport/zipimporter.java
catch (IOException ioe) { Py.writeDebug("import", "zipimporter.getDataStream exception: " + ioe.toString()); throw zipimport.ZipImportError("zipimport: can not open file: " + archive); }
// in src/org/python/modules/zipimport/zipimporter.java
catch (IOException ioe) { throw zipimport.ZipImportError(String.format("can't read Zip file: '%s'", archive)); }
8
asFrozen
3
                  
// in src/org/python/core/PySet.java
catch (PyException e) { PyObject frozen = asFrozen(e, o); b = _set.remove(frozen); }
// in src/org/python/core/PySet.java
catch (PyException e) { PyObject frozen = asFrozen(e, o); _set.remove(frozen); }
// in src/org/python/core/BaseSet.java
catch (PyException pye) { PyFrozenSet frozen = asFrozen(pye, other); return _set.contains(frozen); }
3
cleanup 3
                  
// in src/org/python/util/jython.java
catch (Throwable t) { if (t instanceof PyException && ((PyException)t).match(_systemrestart.SystemRestart)) { // Shutdown this instance... shouldRestart = true; shutdownInterpreter(); interp.cleanup(); // ..reset the state... Py.setSystemState(new PySystemState()); // ...and start again return; } else { Py.printException(t); interp.cleanup(); System.exit(-1); } }
// in src/org/python/util/jython.java
catch (Throwable t) { Py.printException(t); interp.cleanup(); System.exit(-1); }
14
getPyObject 3
                  
// in src/com/ziclix/python/sql/handler/InformixDataHandler.java
catch (SQLException e) { obj = super.getPyObject(set, col, type); }
// in src/com/ziclix/python/sql/handler/PostgresqlDataHandler.java
catch (SQLException e) { obj = super.getPyObject(set, col, Types.VARCHAR); }
// in src/com/ziclix/python/sql/JDBC20DataHandler.java
catch (SQLException e) { obj = super.getPyObject(set, col, type); }
225
newString 3
                  
// in src/org/python/core/PySystemState.java
catch (PyException exc) { if (!exc.match(Py.SystemExit)) { Py.println(stderr, Py.newString("Error in sys.exitfunc:")); } Py.printException(exc); }
// in src/org/python/core/Py.java
catch (PyException pye) { if (!pye.match(TypeError)) { throw pye; } pye.value = Py.newString(String.format("Error when calling the metaclass bases\n " + "%s", pye.value.__str__().toString())); throw pye; }
// in src/org/python/core/PyGenerator.java
catch (PyException pye) { // PEP 342 specifies that if an exception is raised by close, // we output to stderr and then forget about it; String className = PyException.exceptionClassName(pye.type); int lastDot = className.lastIndexOf('.'); if (lastDot != -1) { className = className.substring(lastDot + 1); } String msg = String.format("Exception %s: %s in %s", className, pye.value.__repr__(), __repr__()); Py.println(Py.getSystemState().stderr, Py.newString(msg)); }
143
setSize 3
                  
// in src/org/python/core/PyArray.java
catch (PyException e) { delegate.setSize(afterLast); throw new PyException(e.type, e.value); }
// in src/org/python/core/PyArray.java
catch(PyException e) { // trap any exception - any error invalidates the whole list delegate.setSize(size); // re-throw throw new PyException(e.type, e.value); }
// in src/org/python/core/PyArray.java
catch(IOException e) { // discard anything successfully loaded delegate.setSize(origsize); throw Py.IOError(e); }
5
showexception
3
                  
// in src/org/python/util/InteractiveInterpreter.java
catch (PyException exc) { if (exc.match(Py.SyntaxError)) { // Case 1 showexception(exc); return false; } else if (exc.match(Py.ValueError) || exc.match(Py.OverflowError)) { // Should not print the stack trace, just the error. showexception(exc); return false; } else { throw exc; } }
// in src/org/python/util/InteractiveInterpreter.java
catch (PyException exc) { if (exc.match(Py.SystemExit)) throw exc; showexception(exc); }
3
wrapDecodeResult 3
                  
// in src/org/python/core/codecs.java
catch (PyException ex) { if (ex.match(Py.LookupError)) { // If we couldn't find an encoding, see if we have a builtin if (encoding.equals("utf-8")) { return wrapDecodeResult(PyUnicode_DecodeUTF8(v.toString(), errors)); } else if(encoding.equals("utf-7")) { return wrapDecodeResult(PyUnicode_DecodeUTF7(v.toString(), errors)); } else if(encoding.equals("latin-1")) { return wrapDecodeResult(PyUnicode_DecodeLatin1(v.toString(), v.__len__(), errors)); } } throw ex; }
4
writeUnraisable
3
                  
// in src/org/python/modules/_weakref/AbstractReference.java
catch (Exception exc) { Py.writeUnraisable(exc, callback); }
// in src/org/python/core/PyFinalizableInstance.java
catch (PyException exc) { // Try to get the right method description. PyObject method = instclass.__del__; try { method = __findattr__("__del__"); } catch (PyException e) { // nothing we can do } Py.writeUnraisable(exc, method); }
// in src/org/python/core/PyException.java
catch (PyException pye) { // This function must not fail, so print the error here Py.writeUnraisable(pye, type); return false; }
3
EOFError 2
                  
// in src/org/python/modules/_marshal.java
catch (StringIndexOutOfBoundsException e) { // convert from our PyIOFile abstraction to what marshal in CPython returns // (although it's really just looking for no bombing) throw Py.EOFError("EOF read where object expected"); }
// in src/org/python/core/PyArray.java
catch(EOFException e) { // stubbed catch for fromStream throws throw Py.EOFError("not enough items in string"); }
5
NameError 2
                  
// in src/org/python/core/PyFrame.java
catch (PyException pye) { if (pye.match(Py.KeyError)) { throw Py.NameError(String.format(NAME_ERROR_MSG, index)); } throw pye; }
// in src/org/python/core/PyFrame.java
catch (PyException pye) { if (pye.match(Py.KeyError)) { throw Py.NameError(String.format(GLOBAL_NAME_ERROR_MSG, index)); } throw pye; }
7
PyString 2
                  
// in src/org/python/modules/time/Time.java
catch (ArrayIndexOutOfBoundsException e) { throw new PyException(Py.ValueError, new PyString("day of week out of range (0-6)")); }
// in src/org/python/modules/time/Time.java
catch (ArrayIndexOutOfBoundsException e) { throw new PyException(Py.ValueError, new PyString("month out of range (1-12)")); }
846
RuntimeError 2
                  
// in src/org/python/modules/imp.java
catch(IllegalMonitorStateException e){ throw Py.RuntimeError("not holding the import lock"); }
// in src/org/python/modules/_hashlib.java
catch (CloneNotSupportedException cnse) { throw Py.RuntimeError(String.format("_hashlib.HASH (%s) internal error", name)); }
176
__getitem__ 2
                  
// in src/com/ziclix/python/sql/pipe/db/DBSink.java
catch (Exception e) { // either a KeyError or this.bindings is None or null this.indexedBindings.__setitem__(pyIndex, entry.__getitem__(1)); }
// in src/com/ziclix/python/sql/pipe/db/DBSink.java
catch (Exception e) { // either a KeyError or this.bindings is None or null this.indexedBindings.__setitem__(pyIndex, entry.__getitem__(1)); }
365
__repr__ 2
                  
// in src/org/python/core/PyGenerator.java
catch (PyException pye) { // PEP 342 specifies that if an exception is raised by close, // we output to stderr and then forget about it; String className = PyException.exceptionClassName(pye.type); int lastDot = className.lastIndexOf('.'); if (lastDot != -1) { className = className.substring(lastDot + 1); } String msg = String.format("Exception %s: %s in %s", className, pye.value.__repr__(), __repr__()); Py.println(Py.getSystemState().stderr, Py.newString(msg)); }
154
__setitem__ 2
                  
// in src/com/ziclix/python/sql/pipe/db/DBSink.java
catch (Exception e) { // either a KeyError or this.bindings is None or null this.indexedBindings.__setitem__(pyIndex, entry.__getitem__(1)); }
// in src/com/ziclix/python/sql/pipe/db/DBSink.java
catch (Exception e) { // either a KeyError or this.bindings is None or null this.indexedBindings.__setitem__(pyIndex, entry.__getitem__(1)); }
884
__tojava__ 2
                  
// in src/org/python/core/PyObject.java
catch (PyException e) { if (e.value.getJavaProxy() != null) { Object t = e.value.__tojava__(Throwable.class); if (t != null && t != Py.NoConversion) { throw (Throwable) t; } } else { ThreadState ts = Py.getThreadState(); if (ts.frame == null) { Py.maybeSystemExit(e); } if (Options.showPythonProxyExceptions) { Py.stderr.println( "Exception in Python proxy returning to Java:"); Py.printException(e); } } throw e; }
// in src/org/python/util/PythonObjectInputStream.java
catch (ClassNotFoundException exc) { PyObject m = importModule(clsName); Object cls = m.__tojava__(Class.class); if (cls != null && cls != Py.NoConversion) { return (Class<?>)cls; } throw exc; }
392
atol 2
                  
// in src/org/python/core/PyInteger.java
catch (PyException pye) { if (pye.match(Py.OverflowError)) { return ((PyString) x).atol(base); } throw pye; }
// in src/org/python/core/PyString.java
catch (PyException e) { if (e.match(Py.OverflowError)) { return atol(10); } throw e; }
6
concat 2
                  
// in src/org/python/Version.java
catch (IOException ioe) { System.err.println("There was a problem loading ".concat(versionProperties) .concat(":")); ioe.printStackTrace(); }
12
displayException 2
                  
// in src/org/python/core/Py.java
catch (PyException exc2) { exc2.normalize(); flushLine(); stderr.println("Error in sys.excepthook:"); displayException(exc2.type, exc2.value, exc2.traceback, file); stderr.println(); stderr.println("Original exception was:"); displayException(exc.type, exc.value, exc.traceback, file); }
5
fastGetName 2
                  
// in src/org/python/core/__builtin__.java
catch (ClassCastException e) { throw Py.TypeError(String.format("Expected keys() to be a list, not '%s'", retObj.getType().fastGetName())); }
// in src/org/python/core/PyLong.java
catch (PyException pye) { if (!pye.match(Py.AttributeError)) { throw pye; } throw Py.TypeError(String.format("long() argument must be a string or a number, " + "not '%.200s'", x.getType().fastGetName())); }
1310
fine 2
                  
// in src/org/python/indexer/AstCache.java
catch (IOException iox) { fine(filename + ": " + iox); return null; }
// in src/org/python/indexer/AstCache.java
catch (Exception x) { fine("parse for " + filename + " failed: " + x); }
6
getAbsoluteFile
2
                  
// in src/org/python/core/PySystemState.java
catch (IOException ioe) { executableFile = executableFile.getAbsoluteFile(); }
// in src/org/python/util/jython.java
catch (IOException ioe) { path = new File(opts.filename).getAbsoluteFile().getParent(); }
2
getSuperclass 2
                  
// in src/org/python/core/PyObject.java
catch (java.lang.InstantiationException e) { Class<?> sup = c.getSuperclass(); String msg = "Default constructor failed for Java superclass"; if (sup != null) { msg += " " + sup.getName(); } throw Py.TypeError(msg); }
// in src/org/python/core/PyReflectedConstructor.java
catch (InvocationTargetException e) { if (e.getTargetException() instanceof InstantiationException) { Class<?> sup = proxy.getSuperclass(); String msg = "Constructor failed for Java superclass"; if (sup != null) { msg += " " + sup.getName(); } throw Py.TypeError(msg); } else throw Py.JavaError(e); }
12
getSystemState 2
                  
// in src/org/python/core/Py.java
catch (PyException e) { Py.getSystemState().callExitFunc(); if (e.match(Py.SystemExit)) { return; } throw e; }
// in src/org/python/core/PyGenerator.java
catch (PyException pye) { // PEP 342 specifies that if an exception is raised by close, // we output to stderr and then forget about it; String className = PyException.exceptionClassName(pye.type); int lastDot = className.lastIndexOf('.'); if (lastDot != -1) { className = className.substring(lastDot + 1); } String msg = String.format("Exception %s: %s in %s", className, pye.value.__repr__(), __repr__()); Py.println(Py.getSystemState().stderr, Py.newString(msg)); }
55
getType 2
                  
// in src/org/python/core/__builtin__.java
catch (ClassCastException e) { throw Py.TypeError(String.format("Expected keys() to be a list, not '%s'", retObj.getType().fastGetName())); }
// in src/org/python/core/PyLong.java
catch (PyException pye) { if (!pye.match(Py.AttributeError)) { throw pye; } throw Py.TypeError(String.format("long() argument must be a string or a number, " + "not '%.200s'", x.getType().fastGetName())); }
11885
handleException 2
                  
// in src/org/python/indexer/Indexer.java
catch (StackOverflowError soe) { handleException("Error loading " + path, soe); return null; }
// in src/org/python/indexer/ast/BindingFinder.java
catch (Exception x) { Indexer.idx.handleException("error binding names for " + n, x); }
3
handleExceptionInResolve
2
                  
// in src/org/python/indexer/ast/NNode.java
catch (Exception x) { return handleExceptionInResolve(n, x); }
// in src/org/python/indexer/ast/NNode.java
catch (StackOverflowError soe) { String msg = "Unable to resolve: " + n + " in " + n.getFile() + " (stack overflow)"; Indexer.idx.warn(msg); return handleExceptionInResolve(n, soe); }
2
isDirectory 2
                  
// in src/org/python/modules/posix/PosixModule.java
catch (FileNotFoundException fnfe) { throw Py.OSError(file.isDirectory() ? Errno.EISDIR : Errno.ENOENT, path); }
// in src/org/python/core/io/FileIO.java
catch (FileNotFoundException fnfe) { if (absPath.isDirectory()) { throw Py.IOError(Errno.EISDIR, name); } if ((writing && !absPath.canWrite()) || fnfe.getMessage().endsWith("(Permission denied)")) { throw Py.IOError(Errno.EACCES, name); } throw Py.IOError(Errno.ENOENT, name); }
21
next 2
                  
// in src/org/python/core/PyType.java
catch (PyException t) { for (Iterator<Object> it = savedSubMros.iterator(); it.hasNext();) { PyType subtype = (PyType)it.next(); PyObject[] subtypeSavedMro = (PyObject[])it.next(); subtype.mro = subtypeSavedMro; } bases = savedBases; base = savedBase; mro = savedMro; throw t; }
108
noAttributeError 2
                  
// in src/org/python/core/PyObject.java
catch (PyException exc) { if (exc.match(Py.KeyError)) { noAttributeError(name); } else { throw exc; } }
// in src/org/python/core/PyClass.java
catch (PyException pye) { noAttributeError(name); }
14
put 2
                  
// in src/com/ziclix/python/sql/handler/RowIdHandler.java
catch (Throwable t) { ROWIDS.put(c, CHECKED); }
// in src/org/python/core/io/LineBufferedWriter.java
catch (BufferOverflowException boe) { // buffer is full; we *must* flush flush(); buffer.put(next); }
203
remove 2
                  
// in src/org/python/core/PySet.java
catch (PyException e) { PyObject frozen = asFrozen(e, o); b = _set.remove(frozen); }
// in src/org/python/core/PySet.java
catch (PyException e) { PyObject frozen = asFrozen(e, o); _set.remove(frozen); }
79
severe
2
                  
// in src/org/python/indexer/AstCache.java
catch (Exception x) { severe("Failed to clear disk cache: " + x); return false; }
// in src/org/python/indexer/AstCache.java
catch (Exception x) { severe("Failed to deserialize " + sourcePath + ": " + x); return null; }
2
tracebackHere 2
                  
// in src/org/python/core/PyTableCode.java
catch (Throwable t) { // Convert exceptions that occured in Java code to PyExceptions PyException pye = Py.JavaError(t); pye.tracebackHere(frame); frame.f_lasti = -1; if (frame.tracefunc != null) { frame.tracefunc.traceException(frame, pye); } if (ts.profilefunc != null) { ts.profilefunc.traceException(frame, pye); } // Rethrow the exception to the next stack frame ts.exception = previous_exception; ts.frame = ts.frame.f_back; throw pye; }
// in src/org/python/core/PyBaseCode.java
catch (Throwable t) { // Convert exceptions that occured in Java code to PyExceptions PyException pye = Py.JavaError(t); pye.tracebackHere(frame); frame.f_lasti = -1; if (frame.tracefunc != null) { frame.tracefunc.traceException(frame, pye); } if (ts.profilefunc != null) { ts.profilefunc.traceException(frame, pye); } // Rethrow the exception to the next stack frame ts.exception = previous_exception; ts.frame = ts.frame.f_back; throw pye; }
5
File 1
                  
// in src/org/python/util/jython.java
catch (IOException ioe) { path = new File(opts.filename).getAbsoluteFile().getParent(); }
107
KeyError 1
                  
// in src/org/python/modules/_collections/PyDefaultDict.java
catch (Exception ex) { throw Py.KeyError(key); }
20
Properties 1
                  
// in src/org/python/core/PySystemState.java
catch (AccessControlException ace) { return new Properties(); }
11
PySystemState 1
                  
// in src/org/python/util/jython.java
catch (Throwable t) { if (t instanceof PyException && ((PyException)t).match(_systemrestart.SystemRestart)) { // Shutdown this instance... shouldRestart = true; shutdownInterpreter(); interp.cleanup(); // ..reset the state... Py.setSystemState(new PySystemState()); // ...and start again return; } else { Py.printException(t); interp.cleanup(); System.exit(-1); } }
46
PyUnicode_DecodeLatin1 1
                  
// in src/org/python/core/codecs.java
catch (PyException ex) { if (ex.match(Py.LookupError)) { // If we couldn't find an encoding, see if we have a builtin if (encoding.equals("utf-8")) { return wrapDecodeResult(PyUnicode_DecodeUTF8(v.toString(), errors)); } else if(encoding.equals("utf-7")) { return wrapDecodeResult(PyUnicode_DecodeUTF7(v.toString(), errors)); } else if(encoding.equals("latin-1")) { return wrapDecodeResult(PyUnicode_DecodeLatin1(v.toString(), v.__len__(), errors)); } } throw ex; }
2
PyUnicode_DecodeUTF7 1
                  
// in src/org/python/core/codecs.java
catch (PyException ex) { if (ex.match(Py.LookupError)) { // If we couldn't find an encoding, see if we have a builtin if (encoding.equals("utf-8")) { return wrapDecodeResult(PyUnicode_DecodeUTF8(v.toString(), errors)); } else if(encoding.equals("utf-7")) { return wrapDecodeResult(PyUnicode_DecodeUTF7(v.toString(), errors)); } else if(encoding.equals("latin-1")) { return wrapDecodeResult(PyUnicode_DecodeLatin1(v.toString(), v.__len__(), errors)); } } throw ex; }
2
PyUnicode_DecodeUTF8 1
                  
// in src/org/python/core/codecs.java
catch (PyException ex) { if (ex.match(Py.LookupError)) { // If we couldn't find an encoding, see if we have a builtin if (encoding.equals("utf-8")) { return wrapDecodeResult(PyUnicode_DecodeUTF8(v.toString(), errors)); } else if(encoding.equals("utf-7")) { return wrapDecodeResult(PyUnicode_DecodeUTF7(v.toString(), errors)); } else if(encoding.equals("latin-1")) { return wrapDecodeResult(PyUnicode_DecodeLatin1(v.toString(), v.__len__(), errors)); } } throw ex; }
2
PyUnicode_EncodeUTF7 1
                  
// in src/org/python/core/codecs.java
catch (PyException ex) { if (ex.match(Py.LookupError)) { // If we couldn't find an encoding, see if we have a builtin if (encoding.equals("utf-8")) { return PyUnicode_EncodeUTF8(v.toString(), errors); } else if(encoding.equals("utf-7")) { return codecs.PyUnicode_EncodeUTF7(v.toString(), false, false, errors); } } throw ex; }
2
PyUnicode_EncodeUTF8 1
                  
// in src/org/python/core/codecs.java
catch (PyException ex) { if (ex.match(Py.LookupError)) { // If we couldn't find an encoding, see if we have a builtin if (encoding.equals("utf-8")) { return PyUnicode_EncodeUTF8(v.toString(), errors); } else if(encoding.equals("utf-7")) { return codecs.PyUnicode_EncodeUTF7(v.toString(), false, false, errors); } } throw ex; }
3
ScriptException 1
                  
// in src/org/python/jsr223/PyScriptEngine.java
catch (Exception ee) { se = new ScriptException(pye); }
4
StructError 1
                  
// in src/org/python/modules/struct.java
catch (PyException ex) { throw StructError("required argument is not an integer"); }
19
UnicodeEncodeError 1
                  
// in src/org/python/core/PyString.java
catch (NumberFormatException exc) { if (this instanceof PyUnicode) { // TODO: here's a basic issue: do we use the BigInteger constructor // above, or add an equivalent to CPython's PyUnicode_EncodeDecimal; // we should note that the current error string does not quite match // CPython regardless of the codec, that's going to require some more work throw Py.UnicodeEncodeError("decimal", "codec can't encode character", 0,0, "invalid decimal Unicode string"); } else { throw Py.ValueError("invalid literal for long() with base " + base + ": " + getString()); } }
7
__findattr__ 1
                  
// in src/org/python/core/PyFinalizableInstance.java
catch (PyException exc) { // Try to get the right method description. PyObject method = instclass.__del__; try { method = __findattr__("__del__"); } catch (PyException e) { // nothing we can do } Py.writeUnraisable(exc, method); }
132
__len__ 1
                  
// in src/org/python/core/codecs.java
catch (PyException ex) { if (ex.match(Py.LookupError)) { // If we couldn't find an encoding, see if we have a builtin if (encoding.equals("utf-8")) { return wrapDecodeResult(PyUnicode_DecodeUTF8(v.toString(), errors)); } else if(encoding.equals("utf-7")) { return wrapDecodeResult(PyUnicode_DecodeUTF7(v.toString(), errors)); } else if(encoding.equals("latin-1")) { return wrapDecodeResult(PyUnicode_DecodeLatin1(v.toString(), v.__len__(), errors)); } } throw ex; }
277
__str__ 1
                  
// in src/org/python/core/Py.java
catch (PyException pye) { if (!pye.match(TypeError)) { throw pye; } pye.value = Py.newString(String.format("Error when calling the metaclass bases\n " + "%s", pye.value.__str__().toString())); throw pye; }
163
_jthrow
1
                  
// in src/org/python/core/PyObject.java
catch (Throwable t) { _jthrow(t); return null; }
1
callExitFunc 1
                  
// in src/org/python/core/Py.java
catch (PyException e) { Py.getSystemState().callExitFunc(); if (e.match(Py.SystemExit)) { return; } throw e; }
4
canWrite 1
                  
// in src/org/python/core/io/FileIO.java
catch (FileNotFoundException fnfe) { if (absPath.isDirectory()) { throw Py.IOError(Errno.EISDIR, name); } if ((writing && !absPath.canWrite()) || fnfe.getMessage().endsWith("(Permission denied)")) { throw Py.IOError(Errno.EACCES, name); } throw Py.IOError(Errno.ENOENT, name); }
3
clear 1
                  
// in src/org/python/indexer/Indexer.java
catch (OutOfMemoryError e) { if (astCache != null) { astCache.clear(); } System.gc(); return null; }
82
contains 1
                  
// in src/org/python/core/BaseSet.java
catch (PyException pye) { PyFrozenSet frozen = asFrozen(pye, other); return _set.contains(frozen); }
65
description 1
                  
// in src/org/python/core/io/FileIO.java
catch (IOException ioe) { // On Solaris and Linux, ftruncate(3C) returns EINVAL if not a regular // file whereas, e.g., open(os.devnull, "w") works. Because we have to // simulate the "w" mode in Java, we suppress the exception. // Likewise Windows returns ERROR_INVALID_FUNCTION in that case and // ERROR_INVALID_HANDLE on ttys. Identifying those by the IOException // message is tedious as their messages are localized, so we suppress them // all =[ if (Platform.IS_WINDOWS || ((Platform.IS_SOLARIS || Platform.IS_LINUX) && Errno.EINVAL.description().equals(ioe.getMessage()))) { return; } throw Py.IOError(ioe); }
7
endsWith 1
                  
// in src/org/python/core/io/FileIO.java
catch (FileNotFoundException fnfe) { if (absPath.isDirectory()) { throw Py.IOError(Errno.EISDIR, name); } if ((writing && !absPath.canWrite()) || fnfe.getMessage().endsWith("(Permission denied)")) { throw Py.IOError(Errno.EACCES, name); } throw Py.IOError(Errno.ENOENT, name); }
44
exceptionClassName 1
                  
// in src/org/python/core/PyGenerator.java
catch (PyException pye) { // PEP 342 specifies that if an exception is raised by close, // we output to stderr and then forget about it; String className = PyException.exceptionClassName(pye.type); int lastDot = className.lastIndexOf('.'); if (lastDot != -1) { className = className.substring(lastDot + 1); } String msg = String.format("Exception %s: %s in %s", className, pye.value.__repr__(), __repr__()); Py.println(Py.getSystemState().stderr, Py.newString(msg)); }
2
fillInStackTrace 1
                  
// in src/com/ziclix/python/sql/pipe/Pipe.java
catch (Throwable e) { this.exception = e.fillInStackTrace(); this.queue.close(); }
2
flush 1
                  
// in src/org/python/core/io/LineBufferedWriter.java
catch (BufferOverflowException boe) { // buffer is full; we *must* flush flush(); buffer.put(next); }
29
flushLine 1
                  
// in src/org/python/core/Py.java
catch (PyException exc2) { exc2.normalize(); flushLine(); stderr.println("Error in sys.excepthook:"); displayException(exc2.type, exc2.value, exc2.traceback, file); stderr.println(); stderr.println("Original exception was:"); displayException(exc.type, exc.value, exc.traceback, file); }
8
fromSuspend
1
                  
// in src/org/python/util/JLineConsole.java
catch (IOException ioe) { if (!fromSuspend(ioe)) { throw Py.IOError(ioe); } // Hopefully an IOException caused by ctrl-z (seems only BSD throws this). // Must reset jline to continue try { reader.getTerminal().initializeTerminal(); } catch (Exception e) { throw Py.IOError(e.getMessage()); } // Don't redisplay the prompt promptString = ""; }
1
gc 1
                  
// in src/org/python/indexer/Indexer.java
catch (OutOfMemoryError e) { if (astCache != null) { astCache.clear(); } System.gc(); return null; }
2
get 1
                  
// in src/com/ziclix/python/sql/connect/Connectx.java
catch (NoSuchMethodException e) { Class<?> primitive = null; try { Field f = valueClass.getField("TYPE"); primitive = (Class<?>) f.get(valueClass); } catch (NoSuchFieldException ex) { } catch (IllegalAccessException ex) { } catch (ClassCastException ex) { } if (primitive != null && primitive.isPrimitive()) { return getMethod(srcClass, methodName, primitive); } }
383
getAbsolutePath 1
                  
// in src/org/python/core/PySystemState.java
catch (IOException ioe) { return rootFile.getAbsolutePath(); }
28
getArray 1
                  
// in src/org/python/core/AbstractArray.java
catch (ArrayStoreException e) { throw new IllegalArgumentException("'ofArrayType' must be compatible with existing array type of " + getArray().getClass().getName() + "\tsee java.lang.Class.getName()."); }
163
getBigDecimal 1
                  
// in src/com/ziclix/python/sql/Jython22DataHandler.java
catch (Throwable t) { bd = set.getBigDecimal(col, 10); }
8
getClass 1
                  
// in src/org/python/core/AbstractArray.java
catch (ArrayStoreException e) { throw new IllegalArgumentException("'ofArrayType' must be compatible with existing array type of " + getArray().getClass().getName() + "\tsee java.lang.Class.getName()."); }
278
getField 1
                  
// in src/com/ziclix/python/sql/connect/Connectx.java
catch (NoSuchMethodException e) { Class<?> primitive = null; try { Field f = valueClass.getField("TYPE"); primitive = (Class<?>) f.get(valueClass); } catch (NoSuchFieldException ex) { } catch (IllegalAccessException ex) { } catch (ClassCastException ex) { } if (primitive != null && primitive.isPrimitive()) { return getMethod(srcClass, methodName, primitive); } }
8
getFile 1
                  
// in src/org/python/indexer/ast/NNode.java
catch (StackOverflowError soe) { String msg = "Unable to resolve: " + n + " in " + n.getFile() + " (stack overflow)"; Indexer.idx.warn(msg); return handleExceptionInResolve(n, soe); }
35
getFilename
1
                  
// in src/org/python/compiler/ScopesCompiler.java
catch (Throwable t) { throw ParserFacade.fixParseError(null, t, code_compiler.getFilename()); }
1
getJavaProxy 1
                  
// in src/org/python/core/PyObject.java
catch (PyException e) { if (e.value.getJavaProxy() != null) { Object t = e.value.__tojava__(Throwable.class); if (t != null && t != Py.NoConversion) { throw (Throwable) t; } } else { ThreadState ts = Py.getThreadState(); if (ts.frame == null) { Py.maybeSystemExit(e); } if (Options.showPythonProxyExceptions) { Py.stderr.println( "Exception in Python proxy returning to Java:"); Py.printException(e); } } throw e; }
31
getMethod 1
                  
// in src/com/ziclix/python/sql/connect/Connectx.java
catch (NoSuchMethodException e) { Class<?> primitive = null; try { Field f = valueClass.getField("TYPE"); primitive = (Class<?>) f.get(valueClass); } catch (NoSuchFieldException ex) { } catch (IllegalAccessException ex) { } catch (ClassCastException ex) { } if (primitive != null && primitive.isPrimitive()) { return getMethod(srcClass, methodName, primitive); } }
19
getParent 1
                  
// in src/org/python/util/jython.java
catch (IOException ioe) { path = new File(opts.filename).getAbsoluteFile().getParent(); }
17
getTargetException 1
                  
// in src/org/python/core/PyReflectedConstructor.java
catch (InvocationTargetException e) { if (e.getTargetException() instanceof InstantiationException) { Class<?> sup = proxy.getSuperclass(); String msg = "Constructor failed for Java superclass"; if (sup != null) { msg += " " + sup.getName(); } throw Py.TypeError(msg); } else throw Py.JavaError(e); }
2
getTerminal 1
                  
// in src/org/python/util/JLineConsole.java
catch (IOException ioe) { if (!fromSuspend(ioe)) { throw Py.IOError(ioe); } // Hopefully an IOException caused by ctrl-z (seems only BSD throws this). // Must reset jline to continue try { reader.getTerminal().initializeTerminal(); } catch (Exception e) { throw Py.IOError(e.getMessage()); } // Don't redisplay the prompt promptString = ""; }
2
getThreadState 1
                  
// in src/org/python/core/PyObject.java
catch (PyException e) { if (e.value.getJavaProxy() != null) { Object t = e.value.__tojava__(Throwable.class); if (t != null && t != Py.NoConversion) { throw (Throwable) t; } } else { ThreadState ts = Py.getThreadState(); if (ts.frame == null) { Py.maybeSystemExit(e); } if (Options.showPythonProxyExceptions) { Py.stderr.println( "Exception in Python proxy returning to Java:"); Py.printException(e); } } throw e; }
207
handleRangeLongs
1
                  
// in src/org/python/core/__builtin__.java
catch (PyException pye) { return handleRangeLongs(start, stop, step); }
1
hasNext 1
                  
// in src/org/python/core/PyType.java
catch (PyException t) { for (Iterator<Object> it = savedSubMros.iterator(); it.hasNext();) { PyType subtype = (PyType)it.next(); PyObject[] subtypeSavedMro = (PyObject[])it.next(); subtype.mro = subtypeSavedMro; } bases = savedBases; base = savedBase; mro = savedMro; throw t; }
90
idstr 1
                  
// in src/com/ziclix/python/sql/PyConnection.java
catch (SQLException e) { return String.format("<PyConnection object at %s", Py.idstr(this)); }
30
importModule 1
                  
// in src/org/python/util/PythonObjectInputStream.java
catch (ClassNotFoundException exc) { PyObject m = importModule(clsName); Object cls = m.__tojava__(Class.class); if (cls != null && cls != Py.NoConversion) { return (Class<?>)cls; } throw exc; }
4
initCause 1
                  
// in src/org/python/core/AnnotationReader.java
catch (ArrayIndexOutOfBoundsException e) { IOException ioe = new IOException("Malformed bytecode: not enough data"); ioe.initCause(e);// IOException didn't grow a constructor that could take a cause till // 1.6, so do it the old fashioned way throw ioe; }
3
initializeTerminal
1
                  
// in src/org/python/util/JLineConsole.java
catch (IOException ioe) { if (!fromSuspend(ioe)) { throw Py.IOError(ioe); } // Hopefully an IOException caused by ctrl-z (seems only BSD throws this). // Must reset jline to continue try { reader.getTerminal().initializeTerminal(); } catch (Exception e) { throw Py.IOError(e.getMessage()); } // Don't redisplay the prompt promptString = ""; }
1
isPrimitive 1
                  
// in src/com/ziclix/python/sql/connect/Connectx.java
catch (NoSuchMethodException e) { Class<?> primitive = null; try { Field f = valueClass.getField("TYPE"); primitive = (Class<?>) f.get(valueClass); } catch (NoSuchFieldException ex) { } catch (IllegalAccessException ex) { } catch (ClassCastException ex) { } if (primitive != null && primitive.isPrimitive()) { return getMethod(srcClass, methodName, primitive); } }
15
iterator 1
                  
// in src/org/python/core/PyType.java
catch (PyException t) { for (Iterator<Object> it = savedSubMros.iterator(); it.hasNext();) { PyType subtype = (PyType)it.next(); PyObject[] subtypeSavedMro = (PyObject[])it.next(); subtype.mro = subtypeSavedMro; } bases = savedBases; base = savedBase; mro = savedMro; throw t; }
61
lastIndexOf 1
                  
// in src/org/python/core/PyGenerator.java
catch (PyException pye) { // PEP 342 specifies that if an exception is raised by close, // we output to stderr and then forget about it; String className = PyException.exceptionClassName(pye.type); int lastDot = className.lastIndexOf('.'); if (lastDot != -1) { className = className.substring(lastDot + 1); } String msg = String.format("Exception %s: %s in %s", className, pye.value.__repr__(), __repr__()); Py.println(Py.getSystemState().stderr, Py.newString(msg)); }
40
length 1
                  
// in src/org/python/indexer/demos/Styler.java
catch (StringIndexOutOfBoundsException sx) { System.out.println("whoops: beg=" + a + ", end=" + b + ", len=" + source.length()); return ""; }
393
maybeSystemExit 1
                  
// in src/org/python/core/PyObject.java
catch (PyException e) { if (e.value.getJavaProxy() != null) { Object t = e.value.__tojava__(Throwable.class); if (t != null && t != Py.NoConversion) { throw (Throwable) t; } } else { ThreadState ts = Py.getThreadState(); if (ts.frame == null) { Py.maybeSystemExit(e); } if (Options.showPythonProxyExceptions) { Py.stderr.println( "Exception in Python proxy returning to Java:"); Py.printException(e); } } throw e; }
2
newLong 1
                  
// in src/org/python/modules/cPickle.java
catch(NumberFormatException e) { try { value = Py.newLong(line); } catch(NumberFormatException e2) { throw Py.ValueError("could not convert string to int"); } }
48
normalize 1
                  
// in src/org/python/core/Py.java
catch (PyException exc2) { exc2.normalize(); flushLine(); stderr.println("Error in sys.excepthook:"); displayException(exc2.type, exc2.value, exc2.traceback, file); stderr.println(); stderr.println("Original exception was:"); displayException(exc.type, exc.value, exc.traceback, file); }
15
parse 1
                  
// in src/org/python/core/ParserFacade.java
catch (Throwable t) { if (bufReader == null) throw Py.JavaError(t); // can't do any more try { // then, try parsing as a module bufReader.reset(); return parse(bufReader, CompileMode.exec, filename, cflags); } catch (Throwable tt) { throw fixParseError(bufReader, tt, filename); } }
20
removeModule
1
                  
// in src/org/python/core/imp.java
catch (RuntimeException t) { removeModule(name); throw t; }
1
reset 1
                  
// in src/org/python/core/ParserFacade.java
catch (Throwable t) { if (bufReader == null) throw Py.JavaError(t); // can't do any more try { // then, try parsing as a module bufReader.reset(); return parse(bufReader, CompileMode.exec, filename, cflags); } catch (Throwable tt) { throw fixParseError(bufReader, tt, filename); } }
8
setException 1
                  
// in src/org/python/core/PyBytecode.java
catch (Throwable t) { PyException pye = Py.setException(t, f); why = Why.EXCEPTION; ts.exception = pye; if (debug) { System.err.println("Caught exception:" + pye); } }
2
setSystemState 1
                  
// in src/org/python/util/jython.java
catch (Throwable t) { if (t instanceof PyException && ((PyException)t).match(_systemrestart.SystemRestart)) { // Shutdown this instance... shouldRestart = true; shutdownInterpreter(); interp.cleanup(); // ..reset the state... Py.setSystemState(new PySystemState()); // ...and start again return; } else { Py.printException(t); interp.cleanup(); System.exit(-1); } }
15
shutdownInterpreter
1
                  
// in src/org/python/util/jython.java
catch (Throwable t) { if (t instanceof PyException && ((PyException)t).match(_systemrestart.SystemRestart)) { // Shutdown this instance... shouldRestart = true; shutdownInterpreter(); interp.cleanup(); // ..reset the state... Py.setSystemState(new PySystemState()); // ...and start again return; } else { Py.printException(t); interp.cleanup(); System.exit(-1); } }
1
substring 1
                  
// in src/org/python/core/PyGenerator.java
catch (PyException pye) { // PEP 342 specifies that if an exception is raised by close, // we output to stderr and then forget about it; String className = PyException.exceptionClassName(pye.type); int lastDot = className.lastIndexOf('.'); if (lastDot != -1) { className = className.substring(lastDot + 1); } String msg = String.format("Exception %s: %s in %s", className, pye.value.__repr__(), __repr__()); Py.println(Py.getSystemState().stderr, Py.newString(msg)); }
175
throwValueError 1
                  
// in src/org/python/modules/time/Time.java
catch (ParseException e) { throwValueError("time data did not match format: data=" + data_string + " fmt=" + format); }
4
validPartialSentence
1
                  
// in src/org/python/core/ParserFacade.java
catch (Throwable t) { PyException p = fixParseError(reader, t, filename); if (reader != null && validPartialSentence(reader, kind, filename)) { return null; } throw p; }
1
warn 1
                  
// in src/org/python/indexer/ast/NNode.java
catch (StackOverflowError soe) { String msg = "Unable to resolve: " + n + " in " + n.getFile() + " (stack overflow)"; Indexer.idx.warn(msg); return handleExceptionInResolve(n, soe); }
5
write 1
                  
// in src/org/python/util/InteractiveConsole.java
catch(PyException exc) { if(!exc.match(Py.EOFError)) throw exc; write("\n"); break; }
190
writeComment 1
                  
// in src/com/ziclix/python/sql/zxJDBC.java
catch (Throwable t) { Py.writeComment("zxJDBC", "failed to load connector [" + name + "] using class [" + className + "]"); }
13
Method Nbr Nbr total
close 32
                  
// in src/com/ziclix/python/sql/Fetch.java
finally { try { resultSet.close(); } catch (Throwable e) { } }
// in src/com/ziclix/python/sql/DataHandler.java
finally { try { stream.close(); } catch (IOException ioe) { throw zxJDBC.makeException(ioe); } }
// in src/com/ziclix/python/sql/DataHandler.java
finally { try { reader.close(); } catch (IOException ioe) { throw zxJDBC.makeException(ioe); } }
// in src/com/ziclix/python/sql/Jython22DataHandler.java
finally { try { longvarchar.close(); } catch (Throwable t) {} }
// in src/com/ziclix/python/sql/connect/Lookup.java
finally { if (context != null) { try { context.close(); } catch (NamingException e) { // ok } } }
// in src/com/ziclix/python/sql/pipe/db/DBSink.java
finally { this.cursor.close(); }
// in src/com/ziclix/python/sql/Procedure.java
finally { pec.close(); }
// in src/org/python/indexer/Util.java
finally { if (out != null) { out.close(); } }
// in src/org/python/indexer/Util.java
finally { if (is != null) { is.close(); } }
// in src/org/python/indexer/AstCache.java
finally { if (oos != null) { oos.close(); } else if (fos != null) { fos.close(); } }
// in src/org/python/indexer/AstCache.java
finally { if (ois != null) { ois.close(); } else if (fis != null) { fis.close(); } }
// in src/org/python/expose/generate/ExposeTask.java
finally { if (out != null) { try { out.close(); } catch (IOException e) { // Le sigh... } } }
// in src/org/python/Version.java
finally { try { in.close(); } catch (IOException ioe) { // ok } }
// in src/org/python/modules/zipimport/zipimporter.java
finally { zipBundle.close(); }
// in src/org/python/modules/zipimport/zipimporter.java
finally { try { zipFile.close(); } catch (IOException ioe) { throw Py.IOError(ioe); } }
// in src/org/python/core/SyspathJavaLoader.java
finally { try { input.close(); } catch (IOException e) { // Nothing to do } }
// in src/org/python/core/PySystemState.java
finally { fp.close(); }
// in src/org/python/core/PySystemState.java
finally { if (jarFile != null) { try { jarFile.close(); } catch (IOException e) { } } }
// in src/org/python/core/__builtin__.java
finally { try { file.close(); } catch (IOException e) { throw Py.IOError(e); } }
// in src/org/python/core/ParserFacade.java
finally { close(bufReader); }
// in src/org/python/core/ParserFacade.java
finally { close(bufReader); }
// in src/org/python/core/ParserFacade.java
finally { close(bufReader); }
// in src/org/python/core/ParserFacade.java
finally { close(bufReader); }
// in src/org/python/core/ParserFacade.java
finally { close(reader); }
// in src/org/python/core/imp.java
finally { try { fp.close(); } catch(IOException e) { throw Py.IOError(e); } }
// in src/org/python/core/imp.java
finally { if(fop != null) { try { fop.close(); } catch(IOException e) { Py.writeDebug(IMPORT_LOG, "Unable to close source cache file '" + compiledFilename + "' due to " + e); } } }
// in src/org/python/core/imp.java
finally { fp.close(); }
// in src/org/python/core/util/importer.java
finally { bundle.close(); }
// in src/org/python/util/jython.java
finally { file.close(); }
// in src/org/python/util/jython.java
finally { file.close(); }
90
delete_token
7
                  
// in src/org/python/core/PyObject.java
finally { delete_token(ts, token); ts.compareStateNesting--; }
// in src/org/python/core/PyObject.java
finally { delete_token(ts, token); ts.compareStateNesting--; }
// in src/org/python/core/PyObject.java
finally { delete_token(ts, token); ts.compareStateNesting--; }
// in src/org/python/core/PyObject.java
finally { delete_token(ts, token); ts.compareStateNesting--; }
// in src/org/python/core/PyObject.java
finally { delete_token(ts, token); ts.compareStateNesting--; }
// in src/org/python/core/PyObject.java
finally { delete_token(ts, token); ts.compareStateNesting--; }
// in src/org/python/core/PyObject.java
finally { delete_token(ts, token); ts.compareStateNesting--; }
7
IOError 3
                  
// in src/org/python/modules/zipimport/zipimporter.java
finally { try { zipFile.close(); } catch (IOException ioe) { throw Py.IOError(ioe); } }
// in src/org/python/core/__builtin__.java
finally { try { file.close(); } catch (IOException e) { throw Py.IOError(e); } }
// in src/org/python/core/imp.java
finally { try { fp.close(); } catch(IOException e) { throw Py.IOError(e); } }
57
leaveRecursiveCall
3
                  
// in src/org/python/core/Py.java
finally { threadState.leaveRecursiveCall(); }
// in src/org/python/core/Py.java
finally { threadState.leaveRecursiveCall(); }
// in src/org/python/core/Py.java
finally { threadState.leaveRecursiveCall(); }
3
end 2
                  
// in src/com/ziclix/python/sql/pipe/Pipe.java
finally { try { this.queue.enqueue(Py.None); } finally { this.source.end(); } }
// in src/com/ziclix/python/sql/pipe/Pipe.java
finally { this.source.end(); }
// in src/com/ziclix/python/sql/pipe/Pipe.java
finally { this.sink.end(); }
25
finalize 2
                  
// in src/org/python/modules/jffi/AllocatedNativeMemory.java
finally { super.finalize(); }
// in src/org/python/core/PyGenerator.java
finally { super.finalize(); }
3
isAccessible
2
                  
// in src/org/python/core/io/StreamIO.java
finally { if (inField != null && inField.isAccessible()) { inField.setAccessible(false); } }
// in src/org/python/core/io/StreamIO.java
finally { if (outField != null && outField.isAccessible()) { outField.setAccessible(false); } }
2
makeException 2
                  
// in src/com/ziclix/python/sql/DataHandler.java
finally { try { stream.close(); } catch (IOException ioe) { throw zxJDBC.makeException(ioe); } }
// in src/com/ziclix/python/sql/DataHandler.java
finally { try { reader.close(); } catch (IOException ioe) { throw zxJDBC.makeException(ioe); } }
106
popInitializingProxy
2
                  
// in src/org/python/core/PyObject.java
finally { ts.popInitializingProxy(); }
// in src/org/python/core/PyReflectedConstructor.java
finally { ts.popInitializingProxy(); }
2
put 2
                  
// in src/org/python/indexer/AstCache.java
finally { cache.put(path, mod); // may be null }
// in src/org/python/indexer/AstCache.java
finally { cache.put(path, mod); // may be null }
203
setAccessible 2
                  
// in src/org/python/core/io/StreamIO.java
finally { if (inField != null && inField.isAccessible()) { inField.setAccessible(false); } }
// in src/org/python/core/io/StreamIO.java
finally { if (outField != null && outField.isAccessible()) { outField.setAccessible(false); } }
9
setNameBindingPhase 2
                  
// in src/org/python/indexer/ast/NBody.java
finally { scope.setNameBindingPhase(false); }
// in src/org/python/indexer/ast/NLambda.java
finally { funcTable.setNameBindingPhase(false); }
4
addWarningListener
1
                  
// in src/com/ziclix/python/sql/PyCursor.java
finally { this.fetch = Fetch.newFetch(this.datahandler, this.dynamicFetch); this.fetch.addWarningListener(this); }
1
enqueue 1
                  
// in src/com/ziclix/python/sql/pipe/Pipe.java
finally { try { this.queue.enqueue(Py.None); } finally { this.source.end(); } }
4
newFetch
1
                  
// in src/com/ziclix/python/sql/PyCursor.java
finally { this.fetch = Fetch.newFetch(this.datahandler, this.dynamicFetch); this.fetch.addWarningListener(this); }
1
remove 1
                  
// in src/org/python/indexer/Scope.java
finally { looked.remove(this); }
79
unlock 1
                  
// in src/org/python/core/imp.java
finally { importLock.unlock(); }
5
writeDebug 1
                  
// in src/org/python/core/imp.java
finally { if(fop != null) { try { fop.close(); } catch(IOException e) { Py.writeDebug(IMPORT_LOG, "Unable to close source cache file '" + compiledFilename + "' due to " + e); } } }
26

Reference Table

This table concatenates the results of the previous tables.

Checked/Runtime Type Exception Thrown Thrown from Catch Declared Caught directly Caught
with Thrown
Caught
with Thrown Runtime
unknown (Lib) . 0 0 0 0 0 0
unknown (Lib) AbstractMethodError 0 0 0 3
            
// in src/com/ziclix/python/sql/Fetch.java
catch (AbstractMethodError e) { throw zxJDBC.makeException(zxJDBC.NotSupportedError, zxJDBC.getString("nodynamiccursors")); }
// in src/com/ziclix/python/sql/Fetch.java
catch (AbstractMethodError e) { throw zxJDBC.makeException(zxJDBC.NotSupportedError, zxJDBC.getString("nodynamiccursors")); }
// in src/com/ziclix/python/sql/PyCursor.java
catch (AbstractMethodError e) { throw zxJDBC.makeException(zxJDBC.NotSupportedError, zxJDBC.getString("nodynamiccursors")); }
3
            
// in src/com/ziclix/python/sql/Fetch.java
catch (AbstractMethodError e) { throw zxJDBC.makeException(zxJDBC.NotSupportedError, zxJDBC.getString("nodynamiccursors")); }
// in src/com/ziclix/python/sql/Fetch.java
catch (AbstractMethodError e) { throw zxJDBC.makeException(zxJDBC.NotSupportedError, zxJDBC.getString("nodynamiccursors")); }
// in src/com/ziclix/python/sql/PyCursor.java
catch (AbstractMethodError e) { throw zxJDBC.makeException(zxJDBC.NotSupportedError, zxJDBC.getString("nodynamiccursors")); }
0
unknown (Lib) AccessControlException 0 0 0 2
            
// in src/org/python/core/PySystemState.java
catch (AccessControlException ace) { return new Properties(); }
// in src/org/python/core/packagecache/CachedJarsPackageManager.java
catch(AccessControlException ace) { warning("The java security manager isn't allowing access to the package cache dir, '" + aCachedir1 + "'"); return false; }
0 0
unknown (Lib) ArrayIndexOutOfBoundsException 3
            
// in src/org/python/core/AbstractArray.java
protected void clearRange(int start, int stop) { if (start < stop && start >= 0 && stop <= this.size) { clearRangeInternal(start, stop); } else { if (start == stop && start >= 0 && stop <= this.size) { return; } throw new ArrayIndexOutOfBoundsException("start and stop must follow: 0 <= start <= stop <= " + (this.size) + ", but found start= " + start + " and stop=" + stop); } }
// in src/org/python/core/AbstractArray.java
protected void makeInsertSpace(int index, int length) { this.modCountIncr = 0; if (index >= 0 && index <= this.size) { int toCopy = this.size - index; this.size = this.size + length; // First increase array size if needed if (this.size > this.capacity) { ensureCapacity(this.size); } if (index < this.size - 1) { this.modCountIncr = 1; Object array = getArray(); System.arraycopy(array, index, array, index + length, toCopy); } } else { throw new ArrayIndexOutOfBoundsException("Index must be between 0 and " + this.size + ", but was " + index); } }
// in src/org/python/core/AbstractArray.java
public void replaceSubArray(int thisStart, int thisStop, Object srcArray, int srcStart, int srcStop) { this.modCountIncr = 0; if (!srcArray.getClass().isArray()) { throw new IllegalArgumentException("'array' must be an array type"); } int replacedLen = thisStop - thisStart; if (thisStart < 0 || replacedLen < 0 || thisStop > this.size) { String message = null; if (thisStart < 0) { message = "thisStart < 0 (thisStart = " + thisStart + ")"; } else if (replacedLen < 0) { message = "thisStart > thistStop (thisStart = " + thisStart + ", thisStop = " + thisStop + ")"; } else if (thisStop > this.size) { message = "thisStop > size (thisStop = " + thisStop + ", size = " + this.size + ")"; } else { throw new InternalError("Incorrect validation logic"); } throw new ArrayIndexOutOfBoundsException(message); } int srcLen = Array.getLength(srcArray); int replacementLen = srcStop - srcStart; if (srcStart < 0 || replacementLen < 0 || srcStop > srcLen) { String message = null; if (srcStart < 0) { message = "srcStart < 0 (srcStart = " + srcStart +")"; } else if (replacementLen < 0) { message = "srcStart > srcStop (srcStart = " + srcStart + ", srcStop = " + srcStop + ")"; } else if (srcStop > srcLen) { message = "srcStop > srcArray length (srcStop = " + srcStop + ", srcArray length = " +srcLen + ")"; } else { throw new InternalError("Incorrect validation logic"); } throw new IllegalArgumentException("start, stop and array must follow:\n\t" + "0 <= start <= stop <= array length\nBut found\n\t" + message); } int lengthChange = replacementLen - replacedLen; // Adjust array size if needed. if (lengthChange < 0) { remove(thisStop + lengthChange, thisStop); } else if (lengthChange > 0) { makeInsertSpace(thisStop, lengthChange); } try { this.modCountIncr = 1; System.arraycopy(srcArray, srcStart, getArray(), thisStart, replacementLen); } catch (ArrayStoreException e) { throw new IllegalArgumentException("'ofArrayType' must be compatible with existing array type of " + getArray().getClass().getName() + "\tsee java.lang.Class.getName()."); } }
0 0 3
            
// in src/org/python/modules/time/Time.java
catch (ArrayIndexOutOfBoundsException e) { throw new PyException(Py.ValueError, new PyString("day of week out of range (0-6)")); }
// in src/org/python/modules/time/Time.java
catch (ArrayIndexOutOfBoundsException e) { throw new PyException(Py.ValueError, new PyString("month out of range (1-12)")); }
// in src/org/python/core/AnnotationReader.java
catch (ArrayIndexOutOfBoundsException e) { IOException ioe = new IOException("Malformed bytecode: not enough data"); ioe.initCause(e);// IOException didn't grow a constructor that could take a cause till // 1.6, so do it the old fashioned way throw ioe; }
3
            
// in src/org/python/modules/time/Time.java
catch (ArrayIndexOutOfBoundsException e) { throw new PyException(Py.ValueError, new PyString("day of week out of range (0-6)")); }
// in src/org/python/modules/time/Time.java
catch (ArrayIndexOutOfBoundsException e) { throw new PyException(Py.ValueError, new PyString("month out of range (1-12)")); }
// in src/org/python/core/AnnotationReader.java
catch (ArrayIndexOutOfBoundsException e) { IOException ioe = new IOException("Malformed bytecode: not enough data"); ioe.initCause(e);// IOException didn't grow a constructor that could take a cause till // 1.6, so do it the old fashioned way throw ioe; }
2
unknown (Lib) ArrayStoreException 0 0 0 1
            
// in src/org/python/core/AbstractArray.java
catch (ArrayStoreException e) { throw new IllegalArgumentException("'ofArrayType' must be compatible with existing array type of " + getArray().getClass().getName() + "\tsee java.lang.Class.getName()."); }
1
            
// in src/org/python/core/AbstractArray.java
catch (ArrayStoreException e) { throw new IllegalArgumentException("'ofArrayType' must be compatible with existing array type of " + getArray().getClass().getName() + "\tsee java.lang.Class.getName()."); }
1
unknown (Lib) BufferOverflowException 0 0 0 1
            
// in src/org/python/core/io/LineBufferedWriter.java
catch (BufferOverflowException boe) { // buffer is full; we *must* flush flush(); buffer.put(next); }
0 0
unknown (Lib) BuildException 17
            
// in src/org/python/expose/generate/ExposeTask.java
private void expose(Set<File> toExpose) { for (File f : toExpose) { ExposedTypeProcessor etp; try { etp = new ExposedTypeProcessor(new FileInputStream(f)); } catch (IOException e) { throw new BuildException("Unable to read '" + f + "' to expose it", e); } catch (InvalidExposingException iee) { throw new BuildException(iee.getMessage()); } for (MethodExposer exposer : etp.getMethodExposers()) { generate(exposer); } for (DescriptorExposer exposer : etp.getDescriptorExposers()) { generate(exposer); } if (etp.getNewExposer() != null) { generate(etp.getNewExposer()); } generate(etp.getTypeExposer()); write(etp.getExposedClassName(), etp.getBytecode()); } }
// in src/org/python/expose/generate/ExposeTask.java
private void write(String destClass, byte[] newClassfile) { File dest = new File(destDir, destClass.replace('.', '/') + ".class"); dest.getParentFile().mkdirs();// TODO - check for success FileOutputStream out = null; try { out = new FileOutputStream(dest); out.write(newClassfile); } catch (IOException e) { throw new BuildException("Unable to write to '" + dest + "'", e); } finally { if (out != null) { try { out.close(); } catch (IOException e) { // Le sigh... } } } }
// in src/org/python/util/JycompileAntTask.java
protected void compile(File src, File compiled, String moduleName) { byte[] bytes; try { bytes = imp.compileSource(moduleName, src); } catch (PyException pye) { pye.printStackTrace(); throw new BuildException("Compile failed; see the compiler error output for details."); } File dir = compiled.getParentFile(); if (!dir.exists() && !compiled.getParentFile().mkdirs()) { throw new BuildException("Unable to make directory for compiled file: " + compiled); } imp.cacheCompiledSource(src.getAbsolutePath(), compiled.getAbsolutePath(), bytes); }
// in src/org/python/util/TemplateAntTask.java
public void execute() { if(null == srcDir) { throw new BuildException("no srcdir specified"); } else if(!srcDir.exists()) { throw new BuildException("srcdir '" + srcDir + "' doesn't exist"); } File gexposeScript = new File(srcDir.getAbsolutePath() + File.separator + "gexpose.py"); File gderiveScript = new File(srcDir.getAbsolutePath() + File.separator + "gderived.py"); if(!gexposeScript.exists()) { throw new BuildException("no gexpose.py script found at: " + gexposeScript); } if(!gderiveScript.exists()) { throw new BuildException("no gderive.py script found at: " + gderiveScript); } runPythonScript(gexposeScript.getAbsolutePath()); runPythonScript(gderiveScript.getAbsolutePath()); }
// in src/org/python/util/TemplateAntTask.java
private void runPythonScript(String script) throws BuildException { if(null == python) { python = "python"; } Execute e = new Execute(); e.setWorkingDirectory(srcDir); String[] command; if(lazy) { command = new String[] {python, script, "--lazy"}; } else { command = new String[] {python, script}; } e.setCommandline(command); if(verbose) { String out = ""; for(int k = 0; k < e.getCommandline().length; k++) { out += (e.getCommandline()[k] + " "); } log("executing: " + out); } try { e.execute(); } catch(IOException e2) { throw new BuildException(e2.toString(), e2); } }
// in src/org/python/util/GlobMatchingTask.java
Override public void execute() throws BuildException { checkParameters(); toExpose.clear(); for (String srcEntry : src.list()) { File srcDir = getProject().resolveFile(srcEntry); if (!srcDir.exists()) { throw new BuildException("srcdir '" + srcDir.getPath() + "' does not exist!", getLocation()); } String[] files = getDirectoryScanner(srcDir).getIncludedFiles(); scanDir(srcDir, destDir != null ? destDir : srcDir, files); } process(toExpose); }
// in src/org/python/util/GlobMatchingTask.java
protected void checkParameters() throws BuildException { if (src == null || src.size() == 0) { throw new BuildException("srcdir attribute must be set!", getLocation()); } if (destDir != null && !destDir.isDirectory()) { throw new BuildException("destination directory '" + destDir + "' does not exist " + "or is not a directory", getLocation()); } }
// in src/org/python/util/JythoncAntTask.java
public void setWorkdir(File aValue) { if( aValue.exists() ) { if( ! aValue.isDirectory() ) { throw new BuildException( "Workdir ("+ aValue + ") is not a directory" ); } } else { aValue.mkdirs(); } workdir = aValue; }
// in src/org/python/util/JythoncAntTask.java
public File getPythonHome() { if(jythonHome == null ) { String aPythonHome = getProject().getProperty("python.home"); if(aPythonHome == null ) { throw new BuildException("No python.home or home specified"); } jythonHome = new File(aPythonHome); } return jythonHome; }
// in src/org/python/util/JythoncAntTask.java
public void execute() { try { Java javaTask = null; javaTask = (Java)getProject().createTask("java"); javaTask.setTaskName("jythonc"); javaTask.setClassname( JYTHON_CLASS ); javaTask.createJvmarg().setValue( "-Dpython.home=" + getPythonHome() ); // classpath File aJythonJarFile = new File(getPythonHome(), PySystemState.JYTHON_JAR ); createClasspath().setLocation(aJythonJarFile); javaTask.setClasspath(classpath); // jythonc file javaTask.createArg().setFile( getJythoncPY() ); if( packageName != null ) { javaTask.createArg().setValue("--package"); javaTask.createArg().setValue(packageName); } if( jarFile != null ) { javaTask.createArg().setValue( "--jar" ); javaTask.createArg().setFile( jarFile ); } if(deep) { javaTask.createArg().setValue( "--deep" ); } if(core) { javaTask.createArg().setValue( "--core" ); } if(all) { javaTask.createArg().setValue( "--all" ); } if( jarFileBean != null ) { javaTask.createArg().setValue( "--bean" ); javaTask.createArg().setFile( jarFileBean ); } if( addpackages != null ) { javaTask.createArg().setValue( "--addpackages " ); javaTask.createArg().setValue( addpackages ); } if( workdir != null ) { javaTask.createArg().setValue( "--workdir " ); javaTask.createArg().setFile( workdir ); } if( skipModule != null ) { javaTask.createArg().setValue("--skip"); javaTask.createArg().setValue(skipModule); } // --compiler if( compiler == null ) { // try to use the compiler specified by build.compiler. Right now we are // just going to allow Jikes String buildCompiler = getProject().getProperty("build.compiler"); if (buildCompiler != null && buildCompiler.equals("jikes")) { javaTask.createArg().setValue("--compiler"); javaTask.createArg().setValue("jikes"); } } else { javaTask.createArg().setValue("--compiler"); javaTask.createArg().setValue(compiler); } String aCompilerOpts = getCompilerOptions(); if( aCompilerOpts != null ) { javaTask.createArg().setValue("--compileropts"); javaTask.createArg().setValue(aCompilerOpts); } if( falsenames != null ) { javaTask.createArg().setValue("--falsenames"); javaTask.createArg().setValue(falsenames); } if( extraArgs != null ) { javaTask.createArg().setLine(extraArgs); } //get dependencies list. if( srcDir == null ) { srcDir = getProject().resolveFile("."); } DirectoryScanner scanner = super.getDirectoryScanner(srcDir); String[] dependencies = scanner.getIncludedFiles(); log("compiling " + dependencies.length + " file" + ((dependencies.length == 1)?"":"s")); String baseDir = scanner.getBasedir().toString() + File.separator; //add to the command for (int i = 0; i < dependencies.length; i++) { String targetFile = dependencies[i]; javaTask.createArg().setValue(baseDir + targetFile); } // change the location directory javaTask.setDir(srcDir); javaTask.setFork(true); if (javaTask.executeJava() != 0) { throw new BuildException("jythonc reported an error"); } } catch (Exception e) { // Have to catch this because of the semantics of calling main() String msg = "Exception while calling " + JYTHON_CLASS + ". Details: " + e.toString(); throw new BuildException(msg, e); } }
6
            
// in src/org/python/expose/generate/ExposeTask.java
catch (IOException e) { throw new BuildException("Unable to read '" + f + "' to expose it", e); }
// in src/org/python/expose/generate/ExposeTask.java
catch (InvalidExposingException iee) { throw new BuildException(iee.getMessage()); }
// in src/org/python/expose/generate/ExposeTask.java
catch (IOException e) { throw new BuildException("Unable to write to '" + dest + "'", e); }
// in src/org/python/util/JycompileAntTask.java
catch (PyException pye) { pye.printStackTrace(); throw new BuildException("Compile failed; see the compiler error output for details."); }
// in src/org/python/util/TemplateAntTask.java
catch(IOException e2) { throw new BuildException(e2.toString(), e2); }
// in src/org/python/util/JythoncAntTask.java
catch (Exception e) { // Have to catch this because of the semantics of calling main() String msg = "Exception while calling " + JYTHON_CLASS + ". Details: " + e.toString(); throw new BuildException(msg, e); }
5
            
// in src/org/python/expose/generate/ExposeTask.java
Override public void process(Set<File> toExpose) throws BuildException { if (toExpose.size() > 1) { log("Exposing " + toExpose.size() + " classes"); } else if (toExpose.size() == 1) { log("Exposing 1 class"); } // Quiet harmless unbootstrapped warnings during the expose process int verbose = Options.verbose; Options.verbose = Py.ERROR; try { expose(toExpose); } finally { Options.verbose = verbose; } }
// in src/org/python/util/JycompileAntTask.java
Override public void process(Set<File> toCompile) throws BuildException { if (toCompile.size() == 0) { return; } else if (toCompile.size() > 1) { log("Compiling " + toCompile.size() + " files"); } else if (toCompile.size() == 1) { log("Compiling 1 file"); } Properties props = new Properties(); props.setProperty(PySystemState.PYTHON_CACHEDIR_SKIP, "true"); PySystemState.initialize(System.getProperties(), props); for (File src : toCompile) { String name = _py_compile.getModuleName(src); String compiledFilePath = name.replace('.', '/'); if (src.getName().endsWith("__init__.py")) { compiledFilePath += "/__init__"; } File compiled = new File(destDir, compiledFilePath + "$py.class"); compile(src, compiled, name); } }
// in src/org/python/util/TemplateAntTask.java
private void runPythonScript(String script) throws BuildException { if(null == python) { python = "python"; } Execute e = new Execute(); e.setWorkingDirectory(srcDir); String[] command; if(lazy) { command = new String[] {python, script, "--lazy"}; } else { command = new String[] {python, script}; } e.setCommandline(command); if(verbose) { String out = ""; for(int k = 0; k < e.getCommandline().length; k++) { out += (e.getCommandline()[k] + " "); } log("executing: " + out); } try { e.execute(); } catch(IOException e2) { throw new BuildException(e2.toString(), e2); } }
// in src/org/python/util/GlobMatchingTask.java
Override public void execute() throws BuildException { checkParameters(); toExpose.clear(); for (String srcEntry : src.list()) { File srcDir = getProject().resolveFile(srcEntry); if (!srcDir.exists()) { throw new BuildException("srcdir '" + srcDir.getPath() + "' does not exist!", getLocation()); } String[] files = getDirectoryScanner(srcDir).getIncludedFiles(); scanDir(srcDir, destDir != null ? destDir : srcDir, files); } process(toExpose); }
// in src/org/python/util/GlobMatchingTask.java
protected void checkParameters() throws BuildException { if (src == null || src.size() == 0) { throw new BuildException("srcdir attribute must be set!", getLocation()); } if (destDir != null && !destDir.isDirectory()) { throw new BuildException("destination directory '" + destDir + "' does not exist " + "or is not a directory", getLocation()); } }
0 0 0
unknown (Lib) ClassCastException 0 0 0 9
            
// in src/com/ziclix/python/sql/connect/Connectx.java
catch (NoSuchMethodException e) { Class<?> primitive = null; try { Field f = valueClass.getField("TYPE"); primitive = (Class<?>) f.get(valueClass); } catch (NoSuchFieldException ex) { } catch (IllegalAccessException ex) { } catch (ClassCastException ex) { } if (primitive != null && primitive.isPrimitive()) { return getMethod(srcClass, methodName, primitive); } }
// in src/com/ziclix/python/sql/connect/Connectx.java
catch (ClassCastException ex) { }
// in src/org/python/core/PyArray.java
catch (ClassCastException e) { throw Py.TypeError("Type not compatible with array type"); }
// in src/org/python/core/PyArray.java
catch(ClassCastException e) { throw Py.TypeError("Type not compatible with array type"); }
// in src/org/python/core/PyArray.java
catch(ClassCastException e) { throw Py.TypeError("Type not compatible with array type"); }
// in src/org/python/core/PyArray.java
catch(ClassCastException e) { throw Py.TypeError("Type not compatible with array type"); }
// in src/org/python/core/PyArray.java
catch(ClassCastException e) { throw Py.TypeError("Type not compatible with array type"); }
// in src/org/python/core/__builtin__.java
catch (ClassCastException e) { throw Py.TypeError("apply() 3rd argument must be a " + "dictionary with string keys"); }
// in src/org/python/core/__builtin__.java
catch (ClassCastException e) { throw Py.TypeError(String.format("Expected keys() to be a list, not '%s'", retObj.getType().fastGetName())); }
// in src/org/python/core/PyJavaType.java
catch(ClassCastException classCast) { return Py.NotImplemented; }
7
            
// in src/org/python/core/PyArray.java
catch (ClassCastException e) { throw Py.TypeError("Type not compatible with array type"); }
// in src/org/python/core/PyArray.java
catch(ClassCastException e) { throw Py.TypeError("Type not compatible with array type"); }
// in src/org/python/core/PyArray.java
catch(ClassCastException e) { throw Py.TypeError("Type not compatible with array type"); }
// in src/org/python/core/PyArray.java
catch(ClassCastException e) { throw Py.TypeError("Type not compatible with array type"); }
// in src/org/python/core/PyArray.java
catch(ClassCastException e) { throw Py.TypeError("Type not compatible with array type"); }
// in src/org/python/core/__builtin__.java
catch (ClassCastException e) { throw Py.TypeError("apply() 3rd argument must be a " + "dictionary with string keys"); }
// in src/org/python/core/__builtin__.java
catch (ClassCastException e) { throw Py.TypeError(String.format("Expected keys() to be a list, not '%s'", retObj.getType().fastGetName())); }
0
unknown (Lib) ClassNotFoundException 2
            
// in src/org/python/core/SyspathJavaLoader.java
Override protected Class<?> findClass(String name) throws ClassNotFoundException { PySystemState sys = Py.getSystemState(); ClassLoader sysClassLoader = sys.getClassLoader(); if (sysClassLoader != null) { // sys.classLoader overrides this class loader! return sysClassLoader.loadClass(name); } // Search the sys.path for a .class file matching the named class. PyList path = sys.path; for (int i = 0; i < path.__len__(); i++) { byte[] buffer; PyObject entry = replacePathItem(sys, i, path); if (entry instanceof SyspathArchive) { SyspathArchive archive = (SyspathArchive)entry; buffer = getBytesFromArchive(archive, name); } else { if (!(entry instanceof PyUnicode)) { entry = entry.__str__(); } String dir = entry.toString(); buffer = getBytesFromDir(dir, name); } if (buffer != null) { definePackageForClass(name); return defineClass(name, buffer, 0, buffer.length); } } // couldn't find the .class file on sys.path throw new ClassNotFoundException(name); }
// in src/org/python/core/BytecodeLoader.java
Override protected Class<?> loadClass(String name, boolean resolve) throws ClassNotFoundException { Class<?> c = findLoadedClass(name); if (c != null) { return c; } for (ClassLoader loader : parents) { try { return loader.loadClass(name); } catch (ClassNotFoundException cnfe) {} } // couldn't find the .class file on sys.path throw new ClassNotFoundException(name); }
0 10
            
// in src/org/python/core/SyspathJavaLoader.java
Override protected Class<?> findClass(String name) throws ClassNotFoundException { PySystemState sys = Py.getSystemState(); ClassLoader sysClassLoader = sys.getClassLoader(); if (sysClassLoader != null) { // sys.classLoader overrides this class loader! return sysClassLoader.loadClass(name); } // Search the sys.path for a .class file matching the named class. PyList path = sys.path; for (int i = 0; i < path.__len__(); i++) { byte[] buffer; PyObject entry = replacePathItem(sys, i, path); if (entry instanceof SyspathArchive) { SyspathArchive archive = (SyspathArchive)entry; buffer = getBytesFromArchive(archive, name); } else { if (!(entry instanceof PyUnicode)) { entry = entry.__str__(); } String dir = entry.toString(); buffer = getBytesFromDir(dir, name); } if (buffer != null) { definePackageForClass(name); return defineClass(name, buffer, 0, buffer.length); } } // couldn't find the .class file on sys.path throw new ClassNotFoundException(name); }
// in src/org/python/core/BytecodeLoader.java
Override protected Class<?> loadClass(String name, boolean resolve) throws ClassNotFoundException { Class<?> c = findLoadedClass(name); if (c != null) { return c; } for (ClassLoader loader : parents) { try { return loader.loadClass(name); } catch (ClassNotFoundException cnfe) {} } // couldn't find the .class file on sys.path throw new ClassNotFoundException(name); }
// in src/org/python/core/PyInstance.java
private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException { in.defaultReadObject(); String module = in.readUTF(); String name = in.readUTF(); /* Check for types and missing members here */ //System.out.println("module: "+module+", "+name); PyObject mod = imp.importName(module.intern(), false); PyClass pyc = (PyClass)mod.__getattr__(name.intern()); instclass = pyc; }
// in src/org/python/core/PyJavaType.java
private static <T> T cloneX(T x) throws IOException, ClassNotFoundException { ByteArrayOutputStream bout = new ByteArrayOutputStream(); CloneOutput cout = new CloneOutput(bout); cout.writeObject(x); byte[] bytes = bout.toByteArray(); ByteArrayInputStream bin = new ByteArrayInputStream(bytes); CloneInput cin = new CloneInput(bin, cout); @SuppressWarnings("unchecked") // thanks to Bas de Bakker for the tip! T clone = (T) cin.readObject(); return clone; }
// in src/org/python/core/PyJavaType.java
Override protected Class<?> resolveClass(ObjectStreamClass osc) throws IOException, ClassNotFoundException { Class<?> c = output.classQueue.poll(); String expected = osc.getName(); String found = (c == null) ? null : c.getName(); if (!expected.equals(found)) { throw new InvalidClassException("Classes desynchronized: " + "found " + found + " when expecting " + expected); } return c; }
// in src/org/python/core/PyJavaType.java
Override protected Class<?> resolveProxyClass(String[] interfaceNames) throws IOException, ClassNotFoundException { return output.classQueue.poll(); }
// in src/org/python/core/Py.java
private static Class<?> findClassInternal(String name, String reason) throws ClassNotFoundException { ClassLoader classLoader = Py.getSystemState().getClassLoader(); if (classLoader != null) { if (reason != null) { writeDebug("import", "trying " + name + " as " + reason + " in sys.classLoader"); } return loadAndInitClass(name, classLoader); } if (!syspathJavaLoaderRestricted) { try { classLoader = imp.getSyspathJavaLoader(); if (classLoader != null && reason != null) { writeDebug("import", "trying " + name + " as " + reason + " in SysPathJavaLoader"); } } catch (SecurityException e) { syspathJavaLoaderRestricted = true; } } if (syspathJavaLoaderRestricted) { classLoader = imp.getParentClassLoader(); if (classLoader != null && reason != null) { writeDebug("import", "trying " + name + " as " + reason + " in Jython's parent class loader"); } } if (classLoader != null) { try { return loadAndInitClass(name, classLoader); } catch (ClassNotFoundException cnfe) { // let the default classloader try // XXX: by trying another classloader that may not be on a // parent/child relationship with the Jython's parent // classsloader we are risking some nasty class loading // problems (such as having two incompatible copies for // the same class that is itself a dependency of two // classes loaded from these two different class loaders) } } if (reason != null) { writeDebug("import", "trying " + name + " as " + reason + " in context class loader, for backwards compatibility"); } return loadAndInitClass(name, Thread.currentThread().getContextClassLoader()); }
// in src/org/python/core/Py.java
private static Class<?> loadAndInitClass(String name, ClassLoader loader) throws ClassNotFoundException { return Class.forName(name, true, loader); }
// in src/org/python/util/PythonObjectInputStream.java
protected Class<?> resolveClass(ObjectStreamClass v) throws IOException, ClassNotFoundException { String clsName = v.getName(); if (clsName.startsWith("org.python.proxies")) { int idx = clsName.lastIndexOf('$'); if (idx > 19) { clsName = clsName.substring(19, idx); } idx = clsName.indexOf('$'); if (idx >= 0) { String mod = clsName.substring(0, idx); clsName = clsName.substring(idx + 1); PyObject module = importModule(mod); PyType pycls = (PyType)module.__getattr__(clsName.intern()); return pycls.getProxyType(); } } try { return super.resolveClass(v); } catch (ClassNotFoundException exc) { PyObject m = importModule(clsName); Object cls = m.__tojava__(Class.class); if (cls != null && cls != Py.NoConversion) { return (Class<?>)cls; } throw exc; } }
// in src/org/python/util/Generic.java
private void readObject(ObjectInputStream in) throws IOException, ClassNotFoundException { in.defaultReadObject(); keySet = map.keySet(); }
9
            
// in src/com/ziclix/python/sql/JDBC30DataHandler.java
catch (ClassNotFoundException e) { throw new RuntimeException("JDBC3.0 required to use this DataHandler"); }
// in src/org/python/modules/random/PyRandom.java
catch (ClassNotFoundException e) { throw Py.SystemError("state vector invalid: "+e.getMessage()); }
// in src/org/python/core/PySystemState.java
catch (ClassNotFoundException e) { Py.writeWarning("initializer", "Specified initializer class '" + className + "' not found, continuing"); return false; }
// in src/org/python/core/BytecodeLoader.java
catch (ClassNotFoundException cnfe) {}
// in src/org/python/core/PyType.java
catch (ClassNotFoundException e) { // Well, this is certainly surprising. throw new RuntimeException("Got ClassNotFound calling Class.forName on an already " + " found class.", e); }
// in src/org/python/core/Py.java
catch (ClassNotFoundException cnfe) { // let the default classloader try // XXX: by trying another classloader that may not be on a // parent/child relationship with the Jython's parent // classsloader we are risking some nasty class loading // problems (such as having two incompatible copies for // the same class that is itself a dependency of two // classes loaded from these two different class loaders) }
// in src/org/python/core/Py.java
catch (ClassNotFoundException e) { // e.printStackTrace(); return null; }
// in src/org/python/core/Py.java
catch (ClassNotFoundException e) { return null; }
// in src/org/python/util/PythonObjectInputStream.java
catch (ClassNotFoundException exc) { PyObject m = importModule(clsName); Object cls = m.__tojava__(Class.class); if (cls != null && cls != Py.NoConversion) { return (Class<?>)cls; } throw exc; }
4
            
// in src/com/ziclix/python/sql/JDBC30DataHandler.java
catch (ClassNotFoundException e) { throw new RuntimeException("JDBC3.0 required to use this DataHandler"); }
// in src/org/python/modules/random/PyRandom.java
catch (ClassNotFoundException e) { throw Py.SystemError("state vector invalid: "+e.getMessage()); }
// in src/org/python/core/PyType.java
catch (ClassNotFoundException e) { // Well, this is certainly surprising. throw new RuntimeException("Got ClassNotFound calling Class.forName on an already " + " found class.", e); }
// in src/org/python/util/PythonObjectInputStream.java
catch (ClassNotFoundException exc) { PyObject m = importModule(clsName); Object cls = m.__tojava__(Class.class); if (cls != null && cls != Py.NoConversion) { return (Class<?>)cls; } throw exc; }
2
unknown (Lib) CloneNotSupportedException 0 0 0 3
            
// in src/org/python/modules/_hashlib.java
catch (CloneNotSupportedException cnse) { throw Py.RuntimeError(String.format("_hashlib.HASH (%s) internal error", name)); }
// in src/org/python/core/PyBuiltinMethodSet.java
catch (CloneNotSupportedException e) { throw new RuntimeException("Didn't expect PyBuiltinMethodSet to throw " + "CloneNotSupported since it implements Cloneable", e); }
// in src/org/python/core/PyBuiltinMethod.java
catch(CloneNotSupportedException e) { throw new RuntimeException("Didn't expect PyBuiltinMethodto throw " + "CloneNotSupported since it implements Cloneable", e); }
3
            
// in src/org/python/modules/_hashlib.java
catch (CloneNotSupportedException cnse) { throw Py.RuntimeError(String.format("_hashlib.HASH (%s) internal error", name)); }
// in src/org/python/core/PyBuiltinMethodSet.java
catch (CloneNotSupportedException e) { throw new RuntimeException("Didn't expect PyBuiltinMethodSet to throw " + "CloneNotSupported since it implements Cloneable", e); }
// in src/org/python/core/PyBuiltinMethod.java
catch(CloneNotSupportedException e) { throw new RuntimeException("Didn't expect PyBuiltinMethodto throw " + "CloneNotSupported since it implements Cloneable", e); }
2
unknown (Lib) ClosedChannelException 0 0 0 1
            
// in src/org/python/modules/posix/PosixModule.java
catch (ClosedChannelException cce) { // In the rare case it's closed but the rawIO wasn't throw Py.ValueError("I/O operation on closed file"); }
1
            
// in src/org/python/modules/posix/PosixModule.java
catch (ClosedChannelException cce) { // In the rare case it's closed but the rawIO wasn't throw Py.ValueError("I/O operation on closed file"); }
0
unknown (Lib) ConcurrentModificationException 0 0 0 1
            
// in src/org/python/core/PyList.java
catch (ConcurrentModificationException ex) { throw Py.ValueError(message); }
1
            
// in src/org/python/core/PyList.java
catch (ConcurrentModificationException ex) { throw Py.ValueError(message); }
0
checked (Domain) ConversionException
public static class ConversionException extends Exception {

        public int index;

        public ConversionException(int index) {
            this.index = index;
        }

    }
4
            
// in src/org/python/core/PyObject.java
public String asString(int index) throws ConversionException { throw new ConversionException(index); }
// in src/org/python/core/PyObject.java
public String asName(int index) throws ConversionException { throw new ConversionException(index); }
// in src/org/python/core/PyObject.java
public int asInt(int index) throws ConversionException { throw new ConversionException(index); }
// in src/org/python/core/PyObject.java
public long asLong(int index) throws ConversionException { throw new ConversionException(index); }
0 8
            
// in src/org/python/modules/jffi/ScalarCData.java
Override public long asLong(int index) throws ConversionException { return getValue().asLong(index); }
// in src/org/python/core/PyObject.java
public String asString(int index) throws ConversionException { throw new ConversionException(index); }
// in src/org/python/core/PyObject.java
public String asStringOrNull(int index) throws ConversionException { return asString(index); }
// in src/org/python/core/PyObject.java
public String asName(int index) throws ConversionException { throw new ConversionException(index); }
// in src/org/python/core/PyObject.java
public int asInt(int index) throws ConversionException { throw new ConversionException(index); }
// in src/org/python/core/PyObject.java
public long asLong(int index) throws ConversionException { throw new ConversionException(index); }
// in src/org/python/core/PyString.java
Override public String asString(int index) throws PyObject.ConversionException { return getString(); }
// in src/org/python/core/PyString.java
Override public String asName(int index) throws PyObject.ConversionException { return internedString(); }
1
            
// in src/org/python/core/PyObject.java
catch(PyObject.ConversionException e) { throw Py.TypeError("attribute name must be a string"); }
1
            
// in src/org/python/core/PyObject.java
catch(PyObject.ConversionException e) { throw Py.TypeError("attribute name must be a string"); }
0
unknown (Lib) EOFException 0 0 2
            
// in src/org/python/core/PyArray.java
private int fromStream(InputStream is) throws IOException, EOFException { return fromStream(is, is.available() / getStorageSize()); }
// in src/org/python/core/PyArray.java
private int fromStream(InputStream is, int count) throws IOException, EOFException { DataInputStream dis = new DataInputStream(is); // current number of items present int origsize = delegate.getSize(); // position to start inserting into int index = origsize; // create capacity for 'count' items delegate.ensureCapacity(index + count); if (type.isPrimitive()) { switch (typecode.charAt(0)) { case 'z': for (int i = 0; i < count; i++, index++) { Array.setBoolean(data, index, dis.readBoolean()); delegate.size++; } break; case 'b': for (int i = 0; i < count; i++, index++) { Array.setByte(data, index, dis.readByte()); delegate.size++; } break; case 'B': for (int i = 0; i < count; i++, index++) { Array.setShort(data, index, unsignedByte(dis.readByte())); delegate.size++; } break; case 'u': // use 32-bit integers since we want UCS-4 storage for (int i = 0; i < count; i++, index++) { Array.setInt(data, index, dis.readInt()); delegate.size++; } break; case 'c': for (int i = 0; i < count; i++, index++) { Array.setChar(data, index, (char) (dis.readByte() & 0xff)); delegate.size++; } break; case 'h': for (int i = 0; i < count; i++, index++) { Array.setShort(data, index, dis.readShort()); delegate.size++; } break; case 'H': for (int i = 0; i < count; i++, index++) { Array.setInt(data, index, unsignedShort(dis.readShort())); delegate.size++; } break; case 'i': for (int i = 0; i < count; i++, index++) { Array.setInt(data, index, dis.readInt()); delegate.size++; } break; case 'I': for (int i = 0; i < count; i++, index++) { Array.setLong(data, index, unsignedInt(dis.readInt())); delegate.size++; } break; case 'l': for (int i = 0; i < count; i++, index++) { Array.setLong(data, index, dis.readLong()); delegate.size++; } break; case 'L': // faking it for (int i = 0; i < count; i++, index++) { Array.setLong(data, index, dis.readLong()); delegate.size++; } break; case 'f': for (int i = 0; i < count; i++, index++) { Array.setFloat(data, index, dis.readFloat()); delegate.size++; } break; case 'd': for (int i = 0; i < count; i++, index++) { Array.setDouble(data, index, dis.readDouble()); delegate.size++; } break; } } dis.close(); return (index - origsize); }
5
            
// in src/org/python/core/PyArray.java
catch(EOFException e) { // stubbed catch for fromStream throws throw Py.EOFError("not enough items in string"); }
// in src/org/python/core/packagecache/PackageManager.java
catch (EOFException eof) { //Empty or 1 byte file. return -1; }
// in src/org/python/core/packagecache/CachedJarsPackageManager.java
catch (EOFException eof) { ; }
// in src/org/python/core/packagecache/CachedJarsPackageManager.java
catch (EOFException eof) { ; }
// in src/org/python/util/ReadlineConsole.java
catch(EOFException eofe) { throw new PyException(Py.EOFError); }
2
            
// in src/org/python/core/PyArray.java
catch(EOFException e) { // stubbed catch for fromStream throws throw Py.EOFError("not enough items in string"); }
// in src/org/python/util/ReadlineConsole.java
catch(EOFException eofe) { throw new PyException(Py.EOFError); }
1
runtime (Lib) Error 1
            
// in src/org/python/util/InteractiveInterpreter.java
private void doBreak() { throw new Error("Python interrupt"); //Thread.currentThread().interrupt(); }
0 0 0 0 0
checked (Lib) Exception 1
            
// in src/org/python/compiler/CodeCompiler.java
Override protected Object unhandled_node(PythonTree node) throws Exception { throw new Exception("Unhandled node " + node); }
0 498
            
// in src/org/python/indexer/AstConverter.java
private List<NExceptHandler> convertListExceptHandler(List<excepthandler> in) throws Exception { List<NExceptHandler> out = new ArrayList<NExceptHandler>(in == null ? 0 : in.size()); if (in != null) { for (excepthandler e : in) { @SuppressWarnings("unchecked") NExceptHandler nxh = (NExceptHandler)e.accept(this); if (nxh != null) { out.add(nxh); } } } return out; }
// in src/org/python/indexer/AstConverter.java
private List<NNode> convertListExpr(List<expr> in) throws Exception { List<NNode> out = new ArrayList<NNode>(in == null ? 0 : in.size()); if (in != null) { for (expr e : in) { @SuppressWarnings("unchecked") NNode nx = (NNode)e.accept(this); if (nx != null) { out.add(nx); } } } return out; }
// in src/org/python/indexer/AstConverter.java
private List<NName> convertListName(List<Name> in) throws Exception { List<NName> out = new ArrayList<NName>(in == null ? 0 : in.size()); if (in != null) { for (expr e : in) { @SuppressWarnings("unchecked") NName nn = (NName)e.accept(this); if (nn != null) { out.add(nn); } } } return out; }
// in src/org/python/indexer/AstConverter.java
private NQname convertQname(List<Name> in) throws Exception { if (in == null) { return null; } // This would be less ugly if we generated Qname nodes in the antlr ast. NQname out = null; int end = -1; for (int i = in.size() - 1; i >= 0; i--) { Name n = in.get(i); if (end == -1) { end = n.getCharStopIndex(); } @SuppressWarnings("unchecked") NName nn = (NName)n.accept(this); out = new NQname(out, nn, n.getCharStartIndex(), end); } return out; }
// in src/org/python/indexer/AstConverter.java
private List<NKeyword> convertListKeyword(List<keyword> in) throws Exception { List<NKeyword> out = new ArrayList<NKeyword>(in == null ? 0 : in.size()); if (in != null) { for (keyword e : in) { NKeyword nkw = new NKeyword(e.getInternalArg(), convExpr(e.getInternalValue())); if (nkw != null) { out.add(nkw); } } } return out; }
// in src/org/python/indexer/AstConverter.java
private NBlock convertListStmt(List<stmt> in) throws Exception { List<NNode> out = new ArrayList<NNode>(in == null ? 0 : in.size()); if (in != null) { for (stmt e : in) { @SuppressWarnings("unchecked") NNode nx = (NNode)e.accept(this); if (nx != null) { out.add(nx); } } } return new NBlock(out, 0, 0); }
// in src/org/python/indexer/AstConverter.java
private NNode convExpr(PythonTree e) throws Exception { if (e == null) { return null; } @SuppressWarnings("unchecked") Object o = e.accept(this); if (o instanceof NNode) { return (NNode)o; } return null; }
// in src/org/python/indexer/AstConverter.java
Override public Object visitAssert(Assert n) throws Exception { return new NAssert(convExpr(n.getInternalTest()), convExpr(n.getInternalMsg()), start(n), stop(n)); }
// in src/org/python/indexer/AstConverter.java
Override public Object visitAssign(Assign n) throws Exception { return new NAssign(convertListExpr(n.getInternalTargets()), convExpr(n.getInternalValue()), start(n), stop(n)); }
// in src/org/python/indexer/AstConverter.java
Override public Object visitAttribute(Attribute n) throws Exception { return new NAttribute(convExpr(n.getInternalValue()), (NName)convExpr(n.getInternalAttrName()), start(n), stop(n)); }
// in src/org/python/indexer/AstConverter.java
Override public Object visitAugAssign(AugAssign n) throws Exception { return new NAugAssign(convExpr(n.getInternalTarget()), convExpr(n.getInternalValue()), convOp(n.getInternalOp()), start(n), stop(n)); }
// in src/org/python/indexer/AstConverter.java
Override public Object visitBinOp(BinOp n) throws Exception { return new NBinOp(convExpr(n.getInternalLeft()), convExpr(n.getInternalRight()), convOp(n.getInternalOp()), start(n), stop(n)); }
// in src/org/python/indexer/AstConverter.java
Override public Object visitBoolOp(BoolOp n) throws Exception { NBoolOp.OpType op; switch (n.getInternalOp()) { case And: op = NBoolOp.OpType.AND; break; case Or: op = NBoolOp.OpType.OR; break; default: op = NBoolOp.OpType.UNDEFINED; break; } return new NBoolOp(op, convertListExpr(n.getInternalValues()), start(n), stop(n)); }
// in src/org/python/indexer/AstConverter.java
Override public Object visitBreak(Break n) throws Exception { return new NBreak(start(n), stop(n)); }
// in src/org/python/indexer/AstConverter.java
Override public Object visitCall(Call n) throws Exception { return new NCall(convExpr(n.getInternalFunc()), convertListExpr(n.getInternalArgs()), convertListKeyword(n.getInternalKeywords()), convExpr(n.getInternalKwargs()), convExpr(n.getInternalStarargs()), start(n), stop(n)); }
// in src/org/python/indexer/AstConverter.java
Override public Object visitClassDef(ClassDef n) throws Exception { return new NClassDef((NName)convExpr(n.getInternalNameNode()), convertListExpr(n.getInternalBases()), convertListStmt(n.getInternalBody()), start(n), stop(n)); }
// in src/org/python/indexer/AstConverter.java
Override public Object visitCompare(Compare n) throws Exception { return new NCompare(convExpr(n.getInternalLeft()), null, // XXX: why null? convertListExpr(n.getInternalComparators()), start(n), stop(n)); }
// in src/org/python/indexer/AstConverter.java
Override public Object visitContinue(Continue n) throws Exception { return new NContinue(start(n), stop(n)); }
// in src/org/python/indexer/AstConverter.java
Override public Object visitDelete(Delete n) throws Exception { return new NDelete(convertListExpr(n.getInternalTargets()), start(n), stop(n)); }
// in src/org/python/indexer/AstConverter.java
Override public Object visitDict(Dict n) throws Exception { return new NDict(convertListExpr(n.getInternalKeys()), convertListExpr(n.getInternalValues()), start(n), stop(n)); }
// in src/org/python/indexer/AstConverter.java
Override public Object visitEllipsis(Ellipsis n) throws Exception { return new NEllipsis(start(n), stop(n)); }
// in src/org/python/indexer/AstConverter.java
Override public Object visitExceptHandler(ExceptHandler n) throws Exception { return new NExceptHandler(convExpr(n.getInternalName()), convExpr(n.getInternalType()), convertListStmt(n.getInternalBody()), start(n), stop(n)); }
// in src/org/python/indexer/AstConverter.java
Override public Object visitExec(Exec n) throws Exception { return new NExec(convExpr(n.getInternalBody()), convExpr(n.getInternalGlobals()), convExpr(n.getInternalLocals()), start(n), stop(n)); }
// in src/org/python/indexer/AstConverter.java
Override public Object visitExpr(Expr n) throws Exception { return new NExprStmt(convExpr(n.getInternalValue()), start(n), stop(n)); }
// in src/org/python/indexer/AstConverter.java
Override public Object visitFor(For n) throws Exception { return new NFor(convExpr(n.getInternalTarget()), convExpr(n.getInternalIter()), convertListStmt(n.getInternalBody()), convertListStmt(n.getInternalOrelse()), start(n), stop(n)); }
// in src/org/python/indexer/AstConverter.java
Override public Object visitFunctionDef(FunctionDef n) throws Exception { arguments args = n.getInternalArgs(); NFunctionDef fn = new NFunctionDef((NName)convExpr(n.getInternalNameNode()), convertListExpr(args.getInternalArgs()), convertListStmt(n.getInternalBody()), convertListExpr(args.getInternalDefaults()), (NName)convExpr(args.getInternalVarargName()), (NName)convExpr(args.getInternalKwargName()), start(n), stop(n)); fn.setDecoratorList(convertListExpr(n.getInternalDecorator_list())); return fn; }
// in src/org/python/indexer/AstConverter.java
Override public Object visitGeneratorExp(GeneratorExp n) throws Exception { List<NComprehension> generators = new ArrayList<NComprehension>(n.getInternalGenerators().size()); for (comprehension c : n.getInternalGenerators()) { generators.add(new NComprehension(convExpr(c.getInternalTarget()), convExpr(c.getInternalIter()), convertListExpr(c.getInternalIfs()), start(c), stop(c))); } return new NGeneratorExp(convExpr(n.getInternalElt()), generators, start(n), stop(n)); }
// in src/org/python/indexer/AstConverter.java
Override public Object visitGlobal(Global n) throws Exception { return new NGlobal(convertListName(n.getInternalNameNodes()), start(n), stop(n)); }
// in src/org/python/indexer/AstConverter.java
Override public Object visitIf(If n) throws Exception { return new NIf(convExpr(n.getInternalTest()), convertListStmt(n.getInternalBody()), convertListStmt(n.getInternalOrelse()), start(n), stop(n)); }
// in src/org/python/indexer/AstConverter.java
Override public Object visitIfExp(IfExp n) throws Exception { return new NIfExp(convExpr(n.getInternalTest()), convExpr(n.getInternalBody()), convExpr(n.getInternalOrelse()), start(n), stop(n)); }
// in src/org/python/indexer/AstConverter.java
Override public Object visitImport(Import n) throws Exception { List<NAlias> aliases = new ArrayList<NAlias>(n.getInternalNames().size()); for (alias e : n.getInternalNames()) { aliases.add(new NAlias(e.getInternalName(), convertQname(e.getInternalNameNodes()), (NName)convExpr(e.getInternalAsnameNode()), start(e), stop(e))); } return new NImport(aliases, start(n), stop(n)); }
// in src/org/python/indexer/AstConverter.java
Override public Object visitImportFrom(ImportFrom n) throws Exception { List<NAlias> aliases = new ArrayList<NAlias>(n.getInternalNames().size()); for (alias e : n.getInternalNames()) { aliases.add(new NAlias(e.getInternalName(), convertQname(e.getInternalNameNodes()), (NName)convExpr(e.getInternalAsnameNode()), start(e), stop(e))); } return new NImportFrom(n.getInternalModule(), convertQname(n.getInternalModuleNames()), aliases, start(n), stop(n)); }
// in src/org/python/indexer/AstConverter.java
Override public Object visitIndex(Index n) throws Exception { return new NIndex(convExpr(n.getInternalValue()), start(n), stop(n)); }
// in src/org/python/indexer/AstConverter.java
Override public Object visitLambda(Lambda n) throws Exception { arguments args = n.getInternalArgs(); return new NLambda(convertListExpr(args.getInternalArgs()), convExpr(n.getInternalBody()), convertListExpr(args.getInternalDefaults()), (NName)convExpr(args.getInternalVarargName()), (NName)convExpr(args.getInternalKwargName()), start(n), stop(n)); }
// in src/org/python/indexer/AstConverter.java
Override public Object visitList(org.python.antlr.ast.List n) throws Exception { return new NList(convertListExpr(n.getInternalElts()), start(n), stop(n)); }
// in src/org/python/indexer/AstConverter.java
Override public Object visitListComp(ListComp n) throws Exception { List<NComprehension> generators = new ArrayList<NComprehension>(n.getInternalGenerators().size()); for (comprehension c : n.getInternalGenerators()) { generators.add(new NComprehension(convExpr(c.getInternalTarget()), convExpr(c.getInternalIter()), convertListExpr(c.getInternalIfs()), start(c), stop(c))); } return new NListComp(convExpr(n.getInternalElt()), generators, start(n), stop(n)); }
// in src/org/python/indexer/AstConverter.java
Override public Object visitModule(Module n) throws Exception { return new NModule(convertListStmt(n.getInternalBody()), start(n), stop(n)); }
// in src/org/python/indexer/AstConverter.java
Override public Object visitName(Name n) throws Exception { return new NName(n.getInternalId(), start(n), stop(n)); }
// in src/org/python/indexer/AstConverter.java
Override public Object visitNum(Num n) throws Exception { return new NNum(n.getInternalN(), start(n), stop(n)); }
// in src/org/python/indexer/AstConverter.java
Override public Object visitPass(Pass n) throws Exception { return new NPass(start(n), stop(n)); }
// in src/org/python/indexer/AstConverter.java
Override public Object visitPrint(Print n) throws Exception { return new NPrint(convExpr(n.getInternalDest()), convertListExpr(n.getInternalValues()), start(n), stop(n)); }
// in src/org/python/indexer/AstConverter.java
Override public Object visitRaise(Raise n) throws Exception { return new NRaise(convExpr(n.getInternalType()), convExpr(n.getInternalInst()), convExpr(n.getInternalTback()), start(n), stop(n)); }
// in src/org/python/indexer/AstConverter.java
Override public Object visitRepr(Repr n) throws Exception { return new NRepr(convExpr(n.getInternalValue()), start(n), stop(n)); }
// in src/org/python/indexer/AstConverter.java
Override public Object visitReturn(Return n) throws Exception { return new NReturn(convExpr(n.getInternalValue()), start(n), stop(n)); }
// in src/org/python/indexer/AstConverter.java
Override public Object visitSlice(Slice n) throws Exception { return new NSlice(convExpr(n.getInternalLower()), convExpr(n.getInternalStep()), convExpr(n.getInternalUpper()), start(n), stop(n)); }
// in src/org/python/indexer/AstConverter.java
Override public Object visitStr(Str n) throws Exception { return new NStr(n.getInternalS(), start(n), stop(n)); }
// in src/org/python/indexer/AstConverter.java
Override public Object visitSubscript(Subscript n) throws Exception { return new NSubscript(convExpr(n.getInternalValue()), convExpr(n.getInternalSlice()), start(n), stop(n)); }
// in src/org/python/indexer/AstConverter.java
Override public Object visitTryExcept(TryExcept n) throws Exception { return new NTryExcept(convertListExceptHandler(n.getInternalHandlers()), convertListStmt(n.getInternalBody()), convertListStmt(n.getInternalOrelse()), start(n), stop(n)); }
// in src/org/python/indexer/AstConverter.java
Override public Object visitTryFinally(TryFinally n) throws Exception { return new NTryFinally(convertListStmt(n.getInternalBody()), convertListStmt(n.getInternalFinalbody()), start(n), stop(n)); }
// in src/org/python/indexer/AstConverter.java
Override public Object visitTuple(Tuple n) throws Exception { return new NTuple(convertListExpr(n.getInternalElts()), start(n), stop(n)); }
// in src/org/python/indexer/AstConverter.java
Override public Object visitUnaryOp(UnaryOp n) throws Exception { return new NUnaryOp(null, // XXX: why null for operator? convExpr(n.getInternalOperand()), start(n), stop(n)); }
// in src/org/python/indexer/AstConverter.java
Override public Object visitWhile(While n) throws Exception { return new NWhile(convExpr(n.getInternalTest()), convertListStmt(n.getInternalBody()), convertListStmt(n.getInternalOrelse()), start(n), stop(n)); }
// in src/org/python/indexer/AstConverter.java
Override public Object visitWith(With n) throws Exception { return new NWith(convExpr(n.getInternalOptional_vars()), convExpr(n.getInternalContext_expr()), convertListStmt(n.getInternalBody()), start(n), stop(n)); }
// in src/org/python/indexer/AstConverter.java
Override public Object visitYield(Yield n) throws Exception { return new NYield(convExpr(n.getInternalValue()), start(n), stop(n)); }
// in src/org/python/indexer/Indexer.java
public NModuleType getModuleForFile(String file) throws Exception { if (failedModules.contains(file)) { return null; } NModuleType m = getCachedModule(file); if (m != null) { return m; } return loadFile(file); }
// in src/org/python/indexer/Indexer.java
public List<Outliner.Entry> generateOutline(String file) throws Exception { return new Outliner().generate(this, file); }
// in src/org/python/indexer/Indexer.java
public NModuleType loadFile(String path) throws Exception { return loadFile(path, false); }
// in src/org/python/indexer/Indexer.java
public NModuleType loadString(String path, String contents) throws Exception { NModuleType module = getCachedModule(path); if (module != null) { finer("\nusing cached module " + path + " [succeeded]"); return module; } return parseAndResolve(path, contents); }
// in src/org/python/indexer/Indexer.java
public NModuleType loadFile(String path, boolean skipChain) throws Exception { File f = new File(path); if (f.isDirectory()) { finer("\n loading init file from directory: " + path); f = Util.joinPath(path, "__init__.py"); path = f.getAbsolutePath(); } if (!f.canRead()) { finer("\nfile not not found or cannot be read: " + path); return null; } NModuleType module = getCachedModule(path); if (module != null) { finer("\nusing cached module " + path + " [succeeded]"); return module; } if (!skipChain) { loadParentPackage(path); } try { return parseAndResolve(path); } catch (StackOverflowError soe) { handleException("Error loading " + path, soe); return null; } }
// in src/org/python/indexer/Indexer.java
private void loadParentPackage(String file) throws Exception { File f = new File(file); File parent = f.getParentFile(); if (parent == null || isInLoadPath(parent)) { return; } // the parent package of an __init__.py file is the grandparent dir if (parent != null && f.isFile() && "__init__.py".equals(f.getName())) { parent = parent.getParentFile(); } if (parent == null || isInLoadPath(parent)) { return; } File initpy = Util.joinPath(parent, "__init__.py"); if (!(initpy.isFile() && initpy.canRead())) { return; } loadFile(initpy.getPath()); }
// in src/org/python/indexer/Indexer.java
private NModuleType parseAndResolve(String file) throws Exception { return parseAndResolve(file, null); }
// in src/org/python/indexer/Indexer.java
private AstCache getAstCache() throws Exception { if (astCache == null) { astCache = AstCache.get(); } return astCache; }
// in src/org/python/indexer/Indexer.java
public NModule getAstForFile(String file) throws Exception { return getAstCache().getAST(file); }
// in src/org/python/indexer/Indexer.java
public NModule getAstForFile(String file, String contents) throws Exception { return getAstCache().getAST(file, contents); }
// in src/org/python/indexer/Indexer.java
public NModuleType getBuiltinModule(String qname) throws Exception { return builtins.get(qname); }
// in src/org/python/indexer/Indexer.java
public NModuleType loadModule(String modname) throws Exception { if (failedModules.contains(modname)) { return null; } NModuleType cached = getCachedModule(modname); // builtin file-less modules if (cached != null) { finer("\nusing cached module " + modname); return cached; } NModuleType mt = getBuiltinModule(modname); if (mt != null) { return mt; } finer("looking for module " + modname); if (modname.endsWith(".py")) { modname = modname.substring(0, modname.length() - 3); } String modpath = modname.replace('.', '/'); // A nasty hack to avoid e.g. python2.5 becoming python2/5. // Should generalize this for directory components containing '.'. modpath = modpath.replaceFirst("(/python[23])/([0-9]/)", "$1.$2"); List<String> loadPath = getLoadPath(); for (String p : loadPath) { String dirname = p + modpath; String pyname = dirname + ".py"; String initname = Util.joinPath(dirname, "__init__.py").getAbsolutePath(); String name; // foo/bar has priority over foo/bar.py // http://www.python.org/doc/essays/packages.html if (Util.isReadableFile(initname)) { name = initname; } else if (Util.isReadableFile(pyname)) { name = pyname; } else { continue; } name = Util.canonicalize(name); NModuleType m = loadFile(name); if (m != null) { finer("load of module " + modname + "[succeeded]"); return m; } } finer("failed to find module " + modname + " in load path"); failedModules.add(modname); return null; }
// in src/org/python/indexer/Indexer.java
public void loadFileRecursive(String fullname) throws Exception { File file_or_dir = new File(fullname); if (file_or_dir.isDirectory()) { for (File file : file_or_dir.listFiles()) { loadFileRecursive(file.getAbsolutePath()); } } else { if (file_or_dir.getAbsolutePath().endsWith(".py")) { loadFile(file_or_dir.getAbsolutePath()); } } }
// in src/org/python/indexer/Outliner.java
public List<Entry> generate(Indexer idx, String abspath) throws Exception { NModuleType mt = idx.getModuleForFile(abspath); if (mt == null) { return new ArrayList<Entry>(); } return generate(mt.getTable(), abspath); }
// in src/org/python/indexer/ast/NSubscript.java
Override public NType resolve(Scope s) throws Exception { NType vt = resolveExpr(value, s); NType st = resolveExpr(slice, s); // slicing if (vt.isUnknownType()) { if (st.isListType()) { return setType(vt); } return setType(new NUnknownType()); } if (st.isListType()) { NType getslice_type = vt.getTable().lookupTypeAttr("__getslice__"); if (getslice_type == null) { addError("The type can't be sliced: " + vt); return setType(new NUnknownType()); } if (!getslice_type.isFuncType()) { addError("The type's __getslice__ method is not a function: " + getslice_type); return setType(new NUnknownType()); } return setType(getslice_type.asFuncType().getReturnType().follow()); } // subscription if (slice instanceof NIndex) { if (vt.isListType()) { warnUnlessNumIndex(st); return setType(vt.asListType().getElementType()); } if (vt.isTupleType()) { warnUnlessNumIndex(st); return setType(vt.asTupleType().toListType().getElementType()); } if (vt.isStrType()) { warnUnlessNumIndex(st); return setType(Indexer.idx.builtins.BaseStr); } // XXX: unicode, buffer, xrange if (vt.isDictType()) { if (!st.follow().equals(vt.asDictType().getKeyType())) { addWarning("Possible KeyError (wrong type for subscript)"); } return setType(vt.asDictType().getValueType()); // infer it regardless } // else fall through } // subscription via delegation if (vt.isUnionType()) { for (NType u : vt.asUnionType().getTypes()) { NType gt = vt.getTable().lookupTypeAttr("__getitem__"); if (gt != null) { return setType(get__getitem__type(gt, gt)); } } } NType gt = vt.getTable().lookupTypeAttr("__getitem__"); return setType(get__getitem__type(gt, vt)); }
// in src/org/python/indexer/ast/NWhile.java
Override public NType resolve(Scope s) throws Exception { resolveExpr(test, s); if (body != null) { setType(resolveExpr(body, s)); } if (orelse != null) { addType(resolveExpr(orelse, s)); } return getType(); }
// in src/org/python/indexer/ast/NAugAssign.java
Override public NType resolve(Scope s) throws Exception { resolveExpr(target, s); return setType(resolveExpr(value, s)); }
// in src/org/python/indexer/ast/NNum.java
Override public NType resolve(Scope s) throws Exception { return setType(Indexer.idx.builtins.BaseNum); }
// in src/org/python/indexer/ast/NameBinder.java
public void bind(Scope s, NNode target, NType rvalue) throws Exception { if (target instanceof NName) { bindName(s, (NName)target, rvalue); return; } if (target instanceof NTuple) { bind(s, ((NTuple)target).elts, rvalue); return; } if (target instanceof NList) { bind(s, ((NList)target).elts, rvalue); return; } if (target instanceof NAttribute) { // This causes various problems if we let it happen during the // name-binding pass. I believe the only name-binding context // in which an NAttribute can be an lvalue is in an assignment. // Assignments are statements, so they can only appear in blocks. // Hence the scope for the top-level name is unambiguous; we can // safely leave binding it until the resolve pass. if (!s.isNameBindingPhase()) { ((NAttribute)target).setAttr(s, rvalue); } return; } if (target instanceof NSubscript) { // Ditto. No resolving is allowed during the name-binding phase. if (!s.isNameBindingPhase()) { target.resolveExpr(target, s); } return; } Indexer.idx.putProblem(target, "invalid location for assignment"); }
// in src/org/python/indexer/ast/NameBinder.java
public void bind(Scope s, List<NNode> xs, NType rvalue) throws Exception { if (rvalue.isTupleType()) { List<NType> vs = rvalue.asTupleType().getElementTypes(); if (xs.size() != vs.size()) { reportUnpackMismatch(xs, vs.size()); } else { for (int i = 0; i < xs.size(); i++) { bind(s, xs.get(i), vs.get(i)); } } return; } if (rvalue.isListType()) { bind(s, xs, rvalue.asListType().toTupleType(xs.size())); return; } if (rvalue.isDictType()) { bind(s, xs, rvalue.asDictType().toTupleType(xs.size())); return; } if (!rvalue.isUnknownType()) { Indexer.idx.putProblem(xs.get(0).getFile(), xs.get(0).start(), xs.get(xs.size()-1).end(), "unpacking non-iterable: " + rvalue); } for (int i = 0; i < xs.size(); i++) { bind(s, xs.get(i), new NUnknownType()); } }
// in src/org/python/indexer/ast/NameBinder.java
public NBinding bindName(Scope s, NName name, NType rvalue) throws Exception { NBinding b; if (s.isGlobalName(name.id)) { b = s.getGlobalTable().put(name.id, name, rvalue, kindOr(SCOPE)); Indexer.idx.putLocation(name, b); } else { Scope bindingScope = s.getScopeSymtab(); b = bindingScope.put(name.id, name, rvalue, kindOr(bindingScope.isFunctionScope() ? VARIABLE : SCOPE)); } name.setType(b.followType()); // XXX: this seems like a bit of a hack; should at least figure out // and document what use cases require it. NType nameType = name.getType(); if (!(nameType.isModuleType() || nameType.isClassType())) { nameType.getTable().setPath(b.getQname()); } return b; }
// in src/org/python/indexer/ast/NameBinder.java
public void bindIter(Scope s, NNode target, NNode iter) throws Exception { NType iterType = NNode.resolveExpr(iter, s); if (iterType.isListType()) { bind(s, target, iterType.asListType().getElementType()); } else if (iterType.isTupleType()) { bind(s, target, iterType.asTupleType().toListType().getElementType()); } else { NBinding ent = iterType.getTable().lookupAttr("__iter__"); if (ent == null || !ent.getType().isFuncType()) { if (!iterType.isUnknownType()) { iter.addWarning("not an iterable type: " + iterType); } bind(s, target, new NUnknownType()); } else { bind(s, target, ent.getType().asFuncType().getReturnType()); } } }
// in src/org/python/indexer/ast/NExprStmt.java
Override public NType resolve(Scope s) throws Exception { resolveExpr(value, s); return getType(); }
// in src/org/python/indexer/ast/NTryExcept.java
Override public NType resolve(Scope s) throws Exception { resolveList(handlers, s); if (body != null) { setType(resolveExpr(body, s)); } if (orelse != null) { addType(resolveExpr(orelse, s)); } return getType(); }
// in src/org/python/indexer/ast/NAttribute.java
public void setAttr(Scope s, NType v) throws Exception { setType(new NUnknownType()); NType targetType = resolveExpr(target, s); if (targetType.isUnionType()) { targetType = targetType.asUnionType().firstKnownNonNullAlternate(); if (targetType == null) { return; } } targetType = targetType.follow(); if (targetType == Indexer.idx.builtins.None) { return; } NBinding b = targetType.getTable().putAttr(attr.id, attr, v, ATTRIBUTE); if (b != null) { setType(attr.setType(b.followType())); } }
// in src/org/python/indexer/ast/NAttribute.java
Override public NType resolve(Scope s) throws Exception { setType(new NUnknownType()); NType targetType = resolveExpr(target, s); if (targetType.isUnionType()) { NType ret = new NUnknownType(); for (NType tp : targetType.asUnionType().getTypes()) { resolveAttributeOnType(tp); ret = NUnionType.union(ret, getType()); } setType(attr.setType(ret.follow())); } else { resolveAttributeOnType(targetType); } return getType(); }
// in src/org/python/indexer/ast/NIf.java
Override public NType resolve(Scope s) throws Exception { resolveExpr(test, s); if (body != null) { setType(resolveExpr(body, s)); } if (orelse != null) { addType(resolveExpr(orelse, s)); } return getType(); }
// in src/org/python/indexer/ast/NExec.java
Override public NType resolve(Scope s) throws Exception { resolveExpr(body, s); resolveExpr(globals, s); resolveExpr(locals, s); return getType(); }
// in src/org/python/indexer/ast/NWith.java
Override public NType resolve(Scope s) throws Exception { NType val = resolveExpr(context_expr, s); NameBinder.make().bind(s, optional_vars, val); return setType(resolveExpr(body, s)); }
// in src/org/python/indexer/ast/NCall.java
Override public NType resolve(Scope s) throws Exception { NType ft = resolveExpr(func, s); List<NType> argTypes = new ArrayList<NType>(); for (NNode a : args) { argTypes.add(resolveExpr(a, s)); } resolveList(keywords, s); resolveExpr(starargs, s); resolveExpr(kwargs, s); if (ft.isClassType()) { return setType(ft); // XXX: was new NInstanceType(ft) } if (ft.isFuncType()) { return setType(ft.asFuncType().getReturnType().follow()); } if (ft.isUnknownType()) { NUnknownType to = new NUnknownType(); NFuncType at = new NFuncType(to); NUnionType.union(ft, at); return setType(to); } addWarning("calling non-function " + ft); return setType(new NUnknownType()); }
// in src/org/python/indexer/ast/NIfExp.java
Override public NType resolve(Scope s) throws Exception { resolveExpr(test, s); if (body != null) { setType(resolveExpr(body, s)); } if (orelse != null) { addType(resolveExpr(orelse, s)); } return getType(); }
// in src/org/python/indexer/ast/NPrint.java
Override public NType resolve(Scope s) throws Exception { resolveExpr(dest, s); resolveList(values, s); return getType(); }
// in src/org/python/indexer/ast/NExceptHandler.java
Override protected void bindNames(Scope s) throws Exception { if (name != null) { NameBinder.make().bind(s, name, new NUnknownType()); } }
// in src/org/python/indexer/ast/NExceptHandler.java
Override public NType resolve(Scope s) throws Exception { NType typeval = new NUnknownType(); if (exceptionType != null) { typeval = resolveExpr(exceptionType, s); } if (name != null) { NameBinder.make().bind(s, name, typeval); } if (body != null) { return setType(resolveExpr(body, s)); } else { return setType(new NUnknownType()); } }
// in src/org/python/indexer/ast/NComprehension.java
Override protected void bindNames(Scope s) throws Exception { bindNames(s, target, NameBinder.make()); }
// in src/org/python/indexer/ast/NComprehension.java
private void bindNames(Scope s, NNode target, NameBinder binder) throws Exception { if (target instanceof NName) { binder.bind(s, (NName)target, new NUnknownType()); return; } if (target instanceof NSequence) { for (NNode n : ((NSequence)target).getElements()) { bindNames(s, n, binder); } } }
// in src/org/python/indexer/ast/NComprehension.java
Override public NType resolve(Scope s) throws Exception { NameBinder.make().bindIter(s, target, iter); resolveList(ifs, s); return setType(target.getType()); }
// in src/org/python/indexer/ast/NImport.java
Override protected void bindNames(Scope s) throws Exception { bindAliases(s, aliases); }
// in src/org/python/indexer/ast/NImport.java
static void bindAliases(Scope s, List<NAlias> aliases) throws Exception { NameBinder binder = NameBinder.make(); for (NAlias a : aliases) { if (a.aname != null) { binder.bind(s, a.aname, new NUnknownType()); } } }
// in src/org/python/indexer/ast/NImport.java
Override public NType resolve(Scope s) throws Exception { Scope scope = s.getScopeSymtab(); for (NAlias a : aliases) { NType modtype = resolveExpr(a, s); if (modtype.isModuleType()) { importName(scope, a, modtype.asModuleType()); } } return getType(); }
// in src/org/python/indexer/ast/NImport.java
private void importName(Scope s, NAlias a, NModuleType mt) throws Exception { if (a.aname != null) { if (mt.getFile() != null) { NameBinder.make().bind(s, a.aname, mt); } else { // XXX: seems like the url should be set in loadModule, not here. // Can't the moduleTable store url-keyed modules too? s.update(a.aname.id, new NUrl(Builtins.LIBRARY_URL + mt.getTable().getPath() + ".html"), mt, NBinding.Kind.SCOPE); } } addReferences(s, a.qname, true/*put top name in scope*/); }
// in src/org/python/indexer/ast/NList.java
Override public NType resolve(Scope s) throws Exception { if (elts.size() == 0) { return setType(new NListType()); // list<unknown> } NListType listType = null; for (NNode elt : elts) { if (listType == null) { listType = new NListType(resolveExpr(elt, s)); } else { listType.add(resolveExpr(elt, s)); } } if (listType != null) { setType(listType); } return getType(); }
// in src/org/python/indexer/ast/NBlock.java
Override public NType resolve(Scope scope) throws Exception { for (NNode n : seq) { // XXX: This works for inferring lambda return types, but needs // to be fixed for functions (should be union of return stmt types). NType returnType = resolveExpr(n, scope); if (returnType != Indexer.idx.builtins.None) { setType(returnType); } } return getType(); }
// in src/org/python/indexer/ast/NGeneratorExp.java
Override public NType resolve(Scope s) throws Exception { resolveList(generators, s); return setType(new NListType(resolveExpr(elt, s))); }
// in src/org/python/indexer/ast/NAssign.java
Override protected void bindNames(Scope s) throws Exception { NameBinder binder = NameBinder.make(); for (NNode target : targets) { binder.bind(s, target, new NUnknownType()); } }
// in src/org/python/indexer/ast/NAssign.java
Override public NType resolve(Scope s) throws Exception { NType valueType = resolveExpr(rvalue, s); switch (targets.size()) { case 0: break; case 1: NameBinder.make().bind(s, targets.get(0), valueType); break; default: NameBinder.make().bind(s, targets, valueType); break; } return setType(valueType); }
// in src/org/python/indexer/ast/NSlice.java
Override public NType resolve(Scope s) throws Exception { resolveExpr(lower, s); resolveExpr(step, s); resolveExpr(upper, s); return setType(new NListType()); }
// in src/org/python/indexer/ast/NReturn.java
Override public NType resolve(Scope s) throws Exception { return setType(resolveExpr(value, s)); }
// in src/org/python/indexer/ast/NDelete.java
Override public NType resolve(Scope s) throws Exception { for (NNode n : targets) { resolveExpr(n, s); if (n instanceof NName) { s.remove(((NName)n).id); } } return getType(); }
// in src/org/python/indexer/ast/NFunctionDef.java
Override protected void bindNames(Scope s) throws Exception { Scope owner = s.getScopeSymtab(); // enclosing class, function or module setType(new NFuncType()); Scope funcTable = new Scope(s.getEnclosingLexicalScope(), Scope.Type.FUNCTION); getType().setTable(funcTable); funcTable.setPath(owner.extendPath(getBindingName(owner))); // If we already defined this function in this scope, don't try it again. NType existing = owner.lookupType(getBindingName(owner), true /* local scope */); if (existing != null && existing.isFuncType()) { return; } bindFunctionName(owner); bindFunctionParams(funcTable); bindFunctionDefaults(s); bindMethodAttrs(owner); }
// in src/org/python/indexer/ast/NFunctionDef.java
protected void bindFunctionName(Scope owner) throws Exception { NBinding.Kind funkind = FUNCTION; if (owner.getScopeType() == Scope.Type.CLASS) { if ("__init__".equals(name.id)) { funkind = CONSTRUCTOR; } else { funkind = METHOD; } } NameBinder.make(funkind).bindName(owner, name, getType()); }
// in src/org/python/indexer/ast/NFunctionDef.java
protected void bindFunctionParams(Scope funcTable) throws Exception { NameBinder param = NameBinder.make(PARAMETER); for (NNode a : args) { param.bind(funcTable, a, new NUnknownType()); } if (varargs != null) { param.bind(funcTable, varargs, new NListType()); } if (kwargs != null) { param.bind(funcTable, kwargs, new NDictType()); } }
// in src/org/python/indexer/ast/NFunctionDef.java
protected void bindFunctionDefaults(Scope s) throws Exception { for (NNode n : defaults) { if (n.bindsName()) { n.bindNames(s); } } }
// in src/org/python/indexer/ast/NFunctionDef.java
protected void bindMethodAttrs(Scope owner) throws Exception { NType cls = Indexer.idx.lookupQnameType(owner.getPath()); if (cls == null || !cls.isClassType()) { return; } // We don't currently differentiate between classes and instances. addReadOnlyAttr("im_class", cls, CLASS); addReadOnlyAttr("__class__", cls, CLASS); addReadOnlyAttr("im_self", cls, ATTRIBUTE); addReadOnlyAttr("__self__", cls, ATTRIBUTE); }
// in src/org/python/indexer/ast/NFunctionDef.java
Override public NType resolve(Scope outer) throws Exception { resolveList(defaults, outer); resolveList(decoratorList, outer); Scope funcTable = getTable(); NBinding selfBinding = funcTable.lookup("__self__"); if (selfBinding != null && !selfBinding.getType().isClassType()) { selfBinding = null; } if (selfBinding != null) { if (args.size() < 1) { addWarning(name, "method should have at least one argument (self)"); } else if (!(args.get(0) instanceof NName)) { addError(name, "self parameter must be an identifier"); } } NTupleType fromType = new NTupleType(); bindParamsToDefaults(selfBinding, fromType); if (varargs != null) { NBinding b = funcTable.lookupLocal(varargs.id); if (b != null) { fromType.add(b.getType()); } } if (kwargs != null) { NBinding b = funcTable.lookupLocal(kwargs.id); if (b != null) { fromType.add(b.getType()); } } NType toType = resolveExpr(body, funcTable); getType().asFuncType().setReturnType(toType); return getType(); }
// in src/org/python/indexer/ast/NFunctionDef.java
private void bindParamsToDefaults(NBinding selfBinding, NTupleType fromType) throws Exception { NameBinder param = NameBinder.make(PARAMETER); Scope funcTable = getTable(); for (int i = 0; i < args.size(); i++) { NNode arg = args.get(i); NType argtype = ((i == 0 && selfBinding != null) ? selfBinding.getType() : getArgType(args, defaults, i)); param.bind(funcTable, arg, argtype); fromType.add(argtype); } }
// in src/org/python/indexer/ast/NRaise.java
Override public NType resolve(Scope s) throws Exception { resolveExpr(exceptionType, s); resolveExpr(inst, s); resolveExpr(traceback, s); return getType(); }
// in src/org/python/indexer/ast/NCompare.java
Override public NType resolve(Scope s) throws Exception { setType(Indexer.idx.builtins.BaseNum); resolveExpr(left, s); resolveList(comparators, s); return getType(); }
// in src/org/python/indexer/ast/NQname.java
Override public NType resolve(Scope s) throws Exception { setType(name.setType(new NUnknownType())); // Check for top-level native or standard module. if (isUnqualified()) { NModuleType mt = Indexer.idx.loadModule(name.id); if (mt != null) { return setType(name.setType(mt)); } } else { // Check for second-level builtin such as "os.path". NModuleType mt = Indexer.idx.getBuiltinModule(thisQname()); if (mt != null) { setType(name.setType(mt)); resolveExpr(next, s); return mt; } } return resolveInFilesystem(s); }
// in src/org/python/indexer/ast/NQname.java
private NType resolveInFilesystem(Scope s) throws Exception { NModuleType start = getStartModule(s); if (start == null) { reportUnresolvedModule(); return getType(); } String qname = start.getTable().getPath(); String relQname; if (isDot()) { relQname = Util.getQnameParent(qname); } else if (!isTop()) { relQname = qname + "." + name.id; } else { // top name: first look in current dir, then sys.path String dirQname = isInitPy() ? qname : Util.getQnameParent(qname); relQname = dirQname + "." + name.id; if (Indexer.idx.loadModule(relQname) == null) { relQname = name.id; } } NModuleType mod = Indexer.idx.loadModule(relQname); if (mod == null) { reportUnresolvedModule(); return getType(); } setType(name.setType(mod)); if (!isTop() && mod.getFile() != null) { Scope parentPkg = getPrevious().getTable(); NBinding mb = Indexer.idx.moduleTable.lookup(mod.getFile()); parentPkg.put(name.id, mb); } resolveExpr(next, s); return getType(); }
// in src/org/python/indexer/ast/NQname.java
private NModuleType getStartModule(Scope s) throws Exception { if (!isTop()) { return getPrevious().getType().asModuleType(); } // Start with module for current file (i.e. containing directory). NModuleType start = null; Scope mtable = s.getSymtabOfType(Scope.Type.MODULE); if (mtable != null) { start = Indexer.idx.loadModule(mtable.getPath()); if (start != null) { return start; } } String dir = new File(getFile()).getParent(); if (dir == null) { Indexer.idx.warn("Unable to find parent dir for " + getFile()); return null; } return Indexer.idx.loadModule(dir); }
// in src/org/python/indexer/ast/NModule.java
public void setFile(String file) throws Exception { this.file = file; this.name = Util.moduleNameFor(file); this.md5 = Util.getMD5(new File(file)); }
// in src/org/python/indexer/ast/NModule.java
public void setFile(File path) throws Exception { file = path.getCanonicalPath(); name = Util.moduleNameFor(file); md5 = Util.getMD5(path); }
// in src/org/python/indexer/ast/NModule.java
public void setFileAndMD5(String path, String md5) throws Exception { file = path; name = Util.moduleNameFor(file); this.md5 = md5; }
// in src/org/python/indexer/ast/NModule.java
Override public NType resolve(Scope s) throws Exception { NBinding mb = Indexer.idx.moduleTable.lookupLocal(file); if (mb == null ) { Indexer.idx.reportFailedAssertion("No module for " + name + ": " + file); setType(new NModuleType(name, file, s)); } else { setType(mb.getType()); } resolveExpr(body, getTable()); resolveExportedNames(); return getType(); }
// in src/org/python/indexer/ast/NModule.java
private void resolveExportedNames() throws Exception { NModuleType mtype = null; NType thisType = getType(); if (thisType.isModuleType()) { mtype = thisType.asModuleType(); } else if (thisType.isUnionType()) { for (NType u : thisType.asUnionType().getTypes()) { if (u.isModuleType()) { mtype = u.asModuleType(); break; } } } if (mtype == null) { Indexer.idx.reportFailedAssertion("Found non-module type for " + this + " in " + getFile() + ": " + thisType); return; } Scope table = mtype.getTable(); for (NStr nstr : getExportedNameNodes()) { String name = nstr.n.toString(); NBinding b = table.lookupLocal(name); if (b != null) { Indexer.idx.putLocation(nstr, b); } } }
// in src/org/python/indexer/ast/NModule.java
public List<String> getExportedNames() throws Exception { List<String> exports = new ArrayList<String>(); if (!getType().isModuleType()) { return exports; } for (NStr nstr : getExportedNameNodes()) { exports.add(nstr.n.toString()); } return exports; }
// in src/org/python/indexer/ast/NModule.java
public List<NStr> getExportedNameNodes() throws Exception { List<NStr> exports = new ArrayList<NStr>(); if (!getType().isModuleType()) { return exports; } NBinding all = getTable().lookupLocal("__all__"); if (all== null) { return exports; } Def def = all.getSignatureNode(); if (def == null) { return exports; } NNode __all__ = getDeepestNodeAtOffset(def.start()); if (!(__all__ instanceof NName)) { return exports; } NNode assign = __all__.getParent(); if (!(assign instanceof NAssign)) { return exports; } NNode rvalue = ((NAssign)assign).rvalue; if (!(rvalue instanceof NList)) { return exports; } for (NNode elt : ((NList)rvalue).elts) { if (elt instanceof NStr) { NStr nstr = (NStr)elt; if (nstr.n != null) { exports.add(nstr); } } } return exports; }
// in src/org/python/indexer/ast/NListComp.java
Override public NType resolve(Scope s) throws Exception { NameBinder binder = NameBinder.make(); resolveList(generators, s); return setType(new NListType(resolveExpr(elt, s))); }
// in src/org/python/indexer/ast/NImportFrom.java
Override protected void bindNames(Scope s) throws Exception { // XXX: we can support this by resolving the qname now. if (isImportStar()) { return; } NImport.bindAliases(s, aliases); }
// in src/org/python/indexer/ast/NImportFrom.java
Override public NType resolve(Scope s) throws Exception { Scope scope = s.getScopeSymtab(); resolveExpr(qname, s); NType bottomType = qname.getBottom().getType(); if (!bottomType.isModuleType()) { return setType(new NUnknownType()); } NModuleType mt = (NModuleType)bottomType; setType(mt); NImport.addReferences(s, qname, false /* don't put top name in scope */); if (isImportStar()) { importStar(s, mt); return getType(); } for (NAlias a : aliases) { resolveAlias(scope, mt, a); } return getType(); }
// in src/org/python/indexer/ast/NImportFrom.java
private void resolveAlias(Scope scope, NModuleType mt, NAlias a) throws Exception { // Possibilities 1 & 2: x/y.py or x/y/__init__.py NBinding entry = mt.getTable().lookup(a.name); if (entry == null) { // Possibility 3: try looking for x/y/foo.py String mqname = qname.toQname() + "." + a.qname.toQname(); NModuleType mt2 = Indexer.idx.loadModule(mqname); if (mt2 != null) { entry = Indexer.idx.lookupQname(mt2.getTable().getPath()); } } if (entry == null) { addError(a, "name " + a.qname.getName().id + " not found in module " + this.module); return; } String qname = a.qname.getName().id; String aname = a.aname != null ? a.aname.id : null; // Create references for both the name and the alias (if present). // Then if "foo", add "foo" to scope. If "foo as bar", add "bar". Indexer.idx.putLocation(a.qname.getName(), entry); if (aname != null) { Indexer.idx.putLocation(a.aname, entry); scope.put(aname, entry); } else { scope.put(qname, entry); } }
// in src/org/python/indexer/ast/NImportFrom.java
private void importStar(Scope s, NModuleType mt) throws Exception { if (mt == null || mt.getFile() == null) { return; } NModule mod = Indexer.idx.getAstForFile(mt.getFile()); if (mod == null) { return; } List<String> names = mod.getExportedNames(); if (!names.isEmpty()) { for (String name : names) { NBinding nb = mt.getTable().lookupLocal(name); if (nb != null) { s.put(name, nb); } } } else { // Fall back to importing all names not starting with "_". for (Entry<String, NBinding> e : mt.getTable().entrySet()) { if (!e.getKey().startsWith("_")) { s.put(e.getKey(), e.getValue()); } } } }
// in src/org/python/indexer/ast/NUrl.java
Override public NType resolve(Scope s) throws Exception { return setType(Indexer.idx.builtins.BaseStr); }
// in src/org/python/indexer/ast/NClassDef.java
Override protected void bindNames(Scope s) throws Exception { Scope container = s.getScopeSymtab(); setType(new NClassType(name.id, container)); // If we already defined this class in this scope, don't redefine it. NType existing = container.lookupType(name.id); if (existing != null && existing.isClassType()) { return; } NameBinder.make(NBinding.Kind.CLASS).bind(container, name, getType()); }
// in src/org/python/indexer/ast/NClassDef.java
Override public NType resolve(Scope s) throws Exception { NClassType thisType = getType().asClassType(); List<NType> baseTypes = new ArrayList<NType>(); for (NNode base : bases) { NType baseType = resolveExpr(base, s); if (baseType.isClassType()) { thisType.addSuper(baseType); } baseTypes.add(baseType); } Builtins builtins = Indexer.idx.builtins; addSpecialAttribute("__bases__", new NTupleType(baseTypes)); addSpecialAttribute("__name__", builtins.BaseStr); addSpecialAttribute("__module__", builtins.BaseStr); addSpecialAttribute("__doc__", builtins.BaseStr); addSpecialAttribute("__dict__", new NDictType(builtins.BaseStr, new NUnknownType())); resolveExpr(body, getTable()); return getType(); }
// in src/org/python/indexer/ast/NAlias.java
Override public NType resolve(Scope s) throws Exception { setType(resolveExpr(qname, s)); // "import a.b.c" defines 'a' (the top module) in the scope, whereas // "import a.b.c as x" defines 'x', which refers to the bottom module. if (aname != null && qname != null) { setType(qname.getBottom().getType()); aname.setType(getType()); } return getType(); }
// in src/org/python/indexer/ast/NBoolOp.java
Override public NType resolve(Scope s) throws Exception { if (op == OpType.AND) { NType last = null; for (NNode e : values) { last = resolveExpr(e, s); } return setType(last == null ? new NUnknownType() : last); } // OR return setType(resolveListAsUnion(values, s)); }
// in src/org/python/indexer/ast/NBinOp.java
Override public NType resolve(Scope s) throws Exception { NType ltype = null, rtype = null; if (left != null) { ltype = resolveExpr(left, s).follow(); } if (right != null) { rtype = resolveExpr(right, s).follow(); } // If either non-null operand is a string, assume the result is a string. if (ltype == Indexer.idx.builtins.BaseStr || rtype == Indexer.idx.builtins.BaseStr) { return setType(Indexer.idx.builtins.BaseStr); } // If either non-null operand is a number, assume the result is a number. if (ltype == Indexer.idx.builtins.BaseNum || rtype == Indexer.idx.builtins.BaseNum) { return setType(Indexer.idx.builtins.BaseNum); } if (ltype == null) { return setType(rtype == null ? new NUnknownType() : rtype); } if (rtype == null) { return setType(ltype == null ? new NUnknownType() : ltype); } return setType(NUnionType.union(ltype, rtype)); }
// in src/org/python/indexer/ast/NTuple.java
Override public NType resolve(Scope s) throws Exception { NTupleType thisType = new NTupleType(); for (NNode e : elts) { thisType.add(resolveExpr(e, s)); } return setType(thisType); }
// in src/org/python/indexer/ast/NStr.java
Override public NType resolve(Scope s) throws Exception { return setType(Indexer.idx.builtins.BaseStr); }
// in src/org/python/indexer/ast/NRepr.java
Override public NType resolve(Scope s) throws Exception { resolveExpr(value, s); return setType(Indexer.idx.builtins.BaseStr); }
// in src/org/python/indexer/ast/NYield.java
Override public NType resolve(Scope s) throws Exception { return setType(new NListType(resolveExpr(value, s))); }
// in src/org/python/indexer/ast/NUnaryOp.java
Override public NType resolve(Scope s) throws Exception { return setType(resolveExpr(operand, s)); }
// in src/org/python/indexer/ast/NNode.java
protected void bindNames(Scope s) throws Exception { throw new UnsupportedOperationException("Not a name-binding node type"); }
// in src/org/python/indexer/ast/NNode.java
public NType resolve(Scope s) throws Exception { return getType(); }
// in src/org/python/indexer/ast/NIndex.java
Override public NType resolve(Scope s) throws Exception { return setType(resolveExpr(value, s)); }
// in src/org/python/indexer/ast/NName.java
Override public NType resolve(Scope s) throws Exception { NBinding b = s.lookup(id); if (b == null) { b = makeTempBinding(s); } Indexer.idx.putLocation(this, b); return setType(b.followType()); }
// in src/org/python/indexer/ast/NGlobal.java
Override public NType resolve(Scope s) throws Exception { Scope moduleTable = s.getGlobalTable(); for (NName name : names) { if (s.isGlobalName(name.id)) { continue; // already bound by this (or another) global stmt } s.addGlobalName(name.id); NBinding b = moduleTable.lookup(name); if (b == null) { b = moduleTable.put(name.id, null, new NUnknownType(), NBinding.Kind.SCOPE); } Indexer.idx.putLocation(name, b); } return getType(); }
// in src/org/python/indexer/ast/NBody.java
Override public NType resolve(Scope scope) throws Exception { try { scope.setNameBindingPhase(true); visit(new GlobalFinder(scope)); visit(new BindingFinder(scope)); } finally { scope.setNameBindingPhase(false); } return super.resolve(scope); }
// in src/org/python/indexer/ast/NAssert.java
Override public NType resolve(Scope s) throws Exception { resolveExpr(test, s); resolveExpr(msg, s); return getType(); }
// in src/org/python/indexer/ast/NLambda.java
Override protected void bindFunctionName(Scope owner) throws Exception { NameBinder.make(NBinding.Kind.FUNCTION).bindName(owner, fname, getType()); }
// in src/org/python/indexer/ast/NLambda.java
Override protected void bindMethodAttrs(Scope owner) throws Exception { // no-op }
// in src/org/python/indexer/ast/NLambda.java
Override public NType resolve(Scope s) throws Exception { if (!getType().isFuncType()) { org.python.indexer.Indexer.idx.reportFailedAssertion( "Bad type on " + this + ": type=" + getType() + " in file " + getFile() + " at " + start()); } NTupleType fromType = new NTupleType(); NameBinder param = NameBinder.make(NBinding.Kind.PARAMETER); resolveList(defaults, s); Scope funcTable = getTable(); int argnum = 0; for (NNode a : args) { NType argtype = NFunctionDef.getArgType(args, defaults, argnum++); param.bind(funcTable, a, argtype); fromType.add(argtype); } if (varargs != null) { NType u = new NUnknownType(); param.bind(funcTable, varargs, u); fromType.add(u); } if (kwargs != null) { NType u = new NUnknownType(); param.bind(funcTable, kwargs, u); fromType.add(u); } // A lambda body is not an NBody, so it doesn't undergo the two // pre-resolve passes for finding global statements and name-binding // constructs. However, the lambda expression may itself contain // name-binding constructs (generally, other lambdas), so we need to // perform the name-binding pass on it before resolving. try { funcTable.setNameBindingPhase(true); body.visit(new BindingFinder(funcTable)); } finally { funcTable.setNameBindingPhase(false); } NType toType = resolveExpr(body, funcTable); if (getType().isFuncType()) { // else warning logged at method entry above getType().asFuncType().setReturnType(toType); } return getType(); }
// in src/org/python/indexer/ast/NFor.java
Override protected void bindNames(Scope s) throws Exception { bindNames(s, target, NameBinder.make()); }
// in src/org/python/indexer/ast/NFor.java
private void bindNames(Scope s, NNode target, NameBinder binder) throws Exception { if (target instanceof NName) { binder.bind(s, (NName)target, new NUnknownType()); return; } if (target instanceof NSequence) { for (NNode n : ((NSequence)target).getElements()) { bindNames(s, n, binder); } } }
// in src/org/python/indexer/ast/NFor.java
Override public NType resolve(Scope s) throws Exception { NameBinder.make().bindIter(s, target, iter); if (body == null) { setType(new NUnknownType()); } else { setType(resolveExpr(body, s)); } if (orelse != null) { addType(resolveExpr(orelse, s)); } return getType(); }
// in src/org/python/indexer/ast/NKeyword.java
Override public NType resolve(Scope s) throws Exception { return setType(resolveExpr(value, s)); }
// in src/org/python/indexer/ast/NDict.java
Override public NType resolve(Scope s) throws Exception { NType keyType = resolveListAsUnion(keys, s); NType valType = resolveListAsUnion(values, s); return setType(new NDictType(keyType, valType)); }
// in src/org/python/indexer/ast/NTryFinally.java
Override public NType resolve(Scope s) throws Exception { if (body != null) { setType(resolveExpr(body, s)); } if (finalbody != null) { addType(resolveExpr(finalbody, s)); } return getType(); }
// in src/org/python/indexer/Util.java
public static void writeFile(String path, String contents) throws Exception { PrintWriter out = null; try { out = new PrintWriter(new BufferedWriter(new FileWriter(path))); out.print(contents); out.flush(); } finally { if (out != null) { out.close(); } } }
// in src/org/python/indexer/Util.java
public static String readFile(String filename) throws Exception { return readFile(new File(filename)); }
// in src/org/python/indexer/Util.java
public static String readFile(File path) throws Exception { // Don't use line-oriented file read -- need to retain CRLF if present // so the style-run and link offsets are correct. return new String(getBytesFromFile(path), UTF_8); }
// in src/org/python/indexer/Util.java
public static String getMD5(File path) throws Exception { byte[] bytes = getBytesFromFile(path); return getMD5(bytes); }
// in src/org/python/indexer/Util.java
public static String getMD5(byte[] fileContents) throws Exception { MessageDigest algorithm = MessageDigest.getInstance("MD5"); algorithm.reset(); algorithm.update(fileContents); byte messageDigest[] = algorithm.digest(); StringBuilder sb = new StringBuilder(); for (int i = 0; i < messageDigest.length; i++) { sb.append(String.format("%02x", 0xFF & messageDigest[i])); } return sb.toString(); }
// in src/org/python/indexer/AstCache.java
public static AstCache get() throws Exception { if (INSTANCE == null) { INSTANCE = new AstCache(); } return INSTANCE; }
// in src/org/python/indexer/AstCache.java
public NModule getAST(String path) throws Exception { if (path == null) throw new IllegalArgumentException("null path"); return fetch(path); }
// in src/org/python/indexer/AstCache.java
public NModule getAST(String path, String contents) throws Exception { if (path == null) throw new IllegalArgumentException("null path"); if (contents == null) throw new IllegalArgumentException("null contents"); // Cache stores null value if the parse failed. if (cache.containsKey(path)) { return cache.get(path); } NModule mod = null; try { mod = parse(path, contents); if (mod != null) { mod.setFileAndMD5(path, Util.getMD5(contents.getBytes("UTF-8"))); } } finally { cache.put(path, mod); // may be null } return mod; }
// in src/org/python/indexer/AstCache.java
private NModule fetch(String path) throws Exception { // Cache stores null value if the parse failed. if (cache.containsKey(path)) { return cache.get(path); } // Might be cached on disk but not in memory. NModule mod = getSerializedModule(path); if (mod != null) { fine("reusing " + path); cache.put(path, mod); return mod; } try { mod = parse(path); } finally { cache.put(path, mod); // may be null } if (mod != null) { serialize(mod); } return mod; }
// in src/org/python/indexer/AstCache.java
private NModule parse(String path) throws Exception { fine("parsing " + path); mod ast = invokeANTLR(path); return generateAST(ast, path); }
// in src/org/python/indexer/AstCache.java
private NModule parse(String path, String contents) throws Exception { fine("parsing " + path); mod ast = invokeANTLR(path, contents); return generateAST(ast, path); }
// in src/org/python/indexer/AstCache.java
private NModule generateAST(mod ast, String path) throws Exception { if (ast == null) { Indexer.idx.reportFailedAssertion("ANTLR returned NULL for " + path); return null; } // Convert to indexer's AST. Type conversion warnings are harmless here. @SuppressWarnings("unchecked") Object obj = ast.accept(new AstConverter()); if (!(obj instanceof NModule)) { warn("\n[warning] converted AST is not a module: " + obj); return null; } NModule module = (NModule)obj; if (new File(path).canRead()) { module.setFile(path); } return module; }
// in src/org/python/indexer/AstCache.java
public String getCachePath(File sourcePath) throws Exception { return getCachePath(Util.getMD5(sourcePath), sourcePath.getName()); }
// in src/org/python/indexer/AstCache.java
void serialize(NModule ast) throws Exception { String path = getCachePath(ast.getMD5(), new File(ast.getFile()).getName()); ObjectOutputStream oos = null; FileOutputStream fos = null; try { fos = new FileOutputStream(path); oos = new ObjectOutputStream(fos); oos.writeObject(ast); } finally { if (oos != null) { oos.close(); } else if (fos != null) { fos.close(); } } }
// in src/org/python/indexer/AstCache.java
NModule deserialize(File sourcePath) throws Exception { String cachePath = getCachePath(sourcePath); FileInputStream fis = null; ObjectInputStream ois = null; try { fis = new FileInputStream(cachePath); ois = new ObjectInputStream(fis); NModule mod = (NModule)ois.readObject(); // Files in different dirs may have the same base name and contents. mod.setFile(sourcePath); return mod; } finally { if (ois != null) { ois.close(); } else if (fis != null) { fis.close(); } } }
// in src/org/python/indexer/demos/HtmlDemo.java
private void makeOutputDir() throws Exception { if (!OUTPUT_DIR.exists()) { OUTPUT_DIR.mkdirs(); info("created directory: " + OUTPUT_DIR.getAbsolutePath()); } }
// in src/org/python/indexer/demos/HtmlDemo.java
private void start(File stdlib, File fileOrDir) throws Exception { rootDir = fileOrDir.isFile() ? fileOrDir.getParentFile() : fileOrDir; rootPath = rootDir.getCanonicalPath(); indexer = new Indexer(); indexer.addPath(stdlib.getCanonicalPath()); info("building index..."); indexer.loadFileRecursive(fileOrDir.getCanonicalPath()); indexer.ready(); info(indexer.getStatusReport()); generateHtml(); }
// in src/org/python/indexer/demos/HtmlDemo.java
private void generateHtml() throws Exception { info("generating html..."); makeOutputDir(); linker = new Linker(rootPath, OUTPUT_DIR); linker.findLinks(indexer); int rootLength = rootPath.length(); for (String path : indexer.getLoadedFiles()) { if (!path.startsWith(rootPath)) { continue; } File destFile = Util.joinPath(OUTPUT_DIR, path.substring(rootLength)); destFile.getParentFile().mkdirs(); String destPath = destFile.getAbsolutePath() + ".html"; String html = markup(path); Util.writeFile(destPath, html); } info("wrote " + indexer.getLoadedFiles().size() + " files to " + OUTPUT_DIR); }
// in src/org/python/indexer/demos/HtmlDemo.java
private String markup(String path) throws Exception { String source = Util.readFile(path); List<StyleRun> styles = new Styler(indexer, linker).addStyles(path, source); styles.addAll(linker.getStyles(path)); source = new StyleApplier(path, source, styles).apply(); String outline = new HtmlOutline(indexer).generate(path); return "<html><head title=\"" + path + "\">" + "<style type='text/css'>\n" + CSS + "</style>\n" + "</head>\n<body>\n" + "<table width=100% border='1px solid gray'><tr><td valign='top'>" + outline + "</td><td>" + "<pre>" + addLineNumbers(source) + "</pre>" + "</td></tr></table></body></html>"; }
// in src/org/python/indexer/demos/HtmlDemo.java
public static void main(String[] args) throws Exception { if (args.length != 2) { usage(); } File fileOrDir = checkFile(args[1]); File stdlib = checkFile(args[0]); if (!stdlib.isDirectory()) { abort("Not a directory: " + stdlib); } new HtmlDemo().start(stdlib, fileOrDir); }
// in src/org/python/indexer/demos/HtmlOutline.java
public String generate(String path) throws Exception { buffer = new StringBuilder(1024); List<Outliner.Entry> entries = indexer.generateOutline(path); addOutline(entries); String html = buffer.toString(); buffer = null; return html; }
// in src/org/python/indexer/demos/Styler.java
public List<StyleRun> addStyles(String path, String src) throws Exception { this.path = path; source = src; NModule m = indexer.getAstForFile(path); if (m != null) { m.visit(this); highlightLexicalTokens(); } return styles; }
// in src/org/python/compiler/ProxyMaker.java
public void doConstants() throws Exception { Code code = classfile.addMethod("<clinit>", makeSig("V"), Modifier.STATIC); code.return_(); }
// in src/org/python/compiler/ProxyMaker.java
public static void doReturn(Code code, Class<?> type) throws Exception { switch (getType(type)) { case tNone: break; case tCharacter: case tBoolean: case tByte: case tShort: case tInteger: code.ireturn(); break; case tLong: code.lreturn(); break; case tFloat: code.freturn(); break; case tDouble: code.dreturn(); break; case tVoid: code.return_(); break; default: code.areturn(); break; } }
// in src/org/python/compiler/ProxyMaker.java
public static void doNullReturn(Code code, Class<?> type) throws Exception { switch (getType(type)) { case tNone: break; case tCharacter: case tBoolean: case tByte: case tShort: case tInteger: code.iconst_0(); code.ireturn(); break; case tLong: code.lconst_0(); code.lreturn(); break; case tFloat: code.fconst_0(); code.freturn(); break; case tDouble: code.dconst_0(); code.dreturn(); break; case tVoid: code.return_(); break; default: code.aconst_null(); code.areturn(); break; } }
// in src/org/python/compiler/ProxyMaker.java
public void callSuper(Code code, String name, String superclass, Class<?>[] parameters, Class<?> ret, String sig) throws Exception { code.aload(0); int local_index; int i; for (i=0, local_index=1; i<parameters.length; i++) { switch(getType(parameters[i])) { case tCharacter: case tBoolean: case tByte: case tShort: case tInteger: code.iload(local_index); local_index += 1; break; case tLong: code.lload(local_index); local_index += 2; break; case tFloat: code.fload(local_index); local_index += 1; break; case tDouble: code.dload(local_index); local_index += 2; break; default: code.aload(local_index); local_index += 1; break; } } code.invokespecial(superclass, name, sig); doReturn(code, ret); }
// in src/org/python/compiler/ProxyMaker.java
public void doJavaCall(Code code, String name, String type, String jcallName) throws Exception { code.invokevirtual("org/python/core/PyObject", jcallName, makeSig($pyObj, $objArr)); code.invokestatic("org/python/core/Py", "py2"+name, makeSig(type, $pyObj)); }
// in src/org/python/compiler/ProxyMaker.java
public void getArgs(Code code, Class<?>[] parameters) throws Exception { if (parameters.length == 0) { code.getstatic("org/python/core/Py", "EmptyObjects", $pyObjArr); } else { code.iconst(parameters.length); code.anewarray("java/lang/Object"); int array = code.getLocal("[org/python/core/PyObject"); code.astore(array); int local_index; int i; for (i=0, local_index=1; i<parameters.length; i++) { code.aload(array); code.iconst(i); switch (getType(parameters[i])) { case tBoolean: case tByte: case tShort: case tInteger: code.iload(local_index); local_index += 1; code.invokestatic("org/python/core/Py", "newInteger", "(I)" + $pyInteger); break; case tLong: code.lload(local_index); local_index += 2; code.invokestatic("org/python/core/Py", "newInteger", "(J)" + $pyObj); break; case tFloat: code.fload(local_index); local_index += 1; code.invokestatic("org/python/core/Py", "newFloat", "(F)" + $pyFloat); break; case tDouble: code.dload(local_index); local_index += 2; code.invokestatic("org/python/core/Py", "newFloat", "(D)" + $pyFloat); break; case tCharacter: code.iload(local_index); local_index += 1; code.invokestatic("org/python/core/Py", "newString", "(C)" + $pyStr); break; default: code.aload(local_index); local_index += 1; break; } code.aastore(); } code.aload(array); } }
// in src/org/python/compiler/ProxyMaker.java
public void callMethod(Code code, String name, Class<?>[] parameters, Class<?> ret, Class<?>[] exceptions) throws Exception { Label start = null; Label end = null; String jcallName = "_jcall"; int instLocal = 0; if (exceptions.length > 0) { start = new Label(); end = new Label(); jcallName = "_jcallexc"; instLocal = code.getLocal("org/python/core/PyObject"); code.astore(instLocal); code.label(start); code.aload(instLocal); } getArgs(code, parameters); switch (getType(ret)) { case tCharacter: doJavaCall(code, "char", "C", jcallName); break; case tBoolean: doJavaCall(code, "boolean", "Z", jcallName); break; case tByte: case tShort: case tInteger: doJavaCall(code, "int", "I", jcallName); break; case tLong: doJavaCall(code, "long", "J", jcallName); break; case tFloat: doJavaCall(code, "float", "F", jcallName); break; case tDouble: doJavaCall(code, "double", "D", jcallName); break; case tVoid: doJavaCall(code, "void", "V", jcallName); break; default: code.invokevirtual("org/python/core/PyObject", jcallName, makeSig($pyObj, $objArr)); code.ldc(ret.getName()); code.invokestatic("java/lang/Class","forName", makeSig($clss, $str)); code.invokestatic("org/python/core/Py", "tojava", makeSig($obj, $pyObj, $clss)); // I guess I need this checkcast to keep the verifier happy code.checkcast(mapClass(ret)); break; } if (end != null) { code.label(end); } doReturn(code, ret); if (exceptions.length > 0) { boolean throwableFound = false; Label handlerStart = null; for (Class<?> exception : exceptions) { handlerStart = new Label(); code.label(handlerStart); int excLocal = code.getLocal("java/lang/Throwable"); code.astore(excLocal); code.aload(excLocal); code.athrow(); code.visitTryCatchBlock(start, end, handlerStart, mapClass(exception)); doNullReturn(code, ret); code.freeLocal(excLocal); if (exception == Throwable.class) throwableFound = true; } if (!throwableFound) { // The final catch (Throwable) handlerStart = new Label(); code.label(handlerStart); int excLocal = code.getLocal("java/lang/Throwable"); code.astore(excLocal); code.aload(instLocal); code.aload(excLocal); code.invokevirtual("org/python/core/PyObject", "_jthrow", makeSig("V", $throwable)); code.visitTryCatchBlock(start, end, handlerStart, "java/lang/Throwable"); code.freeLocal(excLocal); doNullReturn(code, ret); } code.freeLocal(instLocal); } }
// in src/org/python/compiler/ProxyMaker.java
public void addMethod(Method method, int access) throws Exception { boolean isAbstract = false; if (Modifier.isAbstract(access)) { access = access & ~Modifier.ABSTRACT; isAbstract = true; } Class<?>[] parameters = method.getParameterTypes(); Class<?> ret = method.getReturnType(); String sig = makeSig(ret, parameters); String name = method.getName(); names.add(name); Code code = classfile.addMethod(name, sig, access); code.aload(0); code.ldc(name); if (!isAbstract) { int tmp = code.getLocal("org/python/core/PyObject"); code.invokestatic("org/python/compiler/ProxyMaker", "findPython", makeSig($pyObj, $pyProxy, $str)); code.astore(tmp); code.aload(tmp); Label callPython = new Label(); code.ifnonnull(callPython); String superClass = mapClass(method.getDeclaringClass()); callSuper(code, name, superClass, parameters, ret, sig); code.label(callPython); code.aload(tmp); callMethod(code, name, parameters, ret, method.getExceptionTypes()); addSuperMethod("super__"+name, name, superClass, parameters, ret, sig, access); } else { code.invokestatic("org/python/compiler/ProxyMaker", "findPython", makeSig($pyObj, $pyProxy, $str)); code.dup(); Label returnNull = new Label(); code.ifnull(returnNull); callMethod(code, name, parameters, ret, method.getExceptionTypes()); code.label(returnNull); code.pop(); doNullReturn(code, ret); } }
// in src/org/python/compiler/ProxyMaker.java
protected void addMethods(Class<?> c, Set<String> t) throws Exception { Method[] methods = c.getDeclaredMethods(); for (Method method : methods) { if (!t.add(methodString(method))) { continue; } int access = method.getModifiers(); if (Modifier.isStatic(access) || Modifier.isPrivate(access)) { continue; } if (Modifier.isNative(access)) { access = access & ~Modifier.NATIVE; } if (Modifier.isProtected(access)) { access = (access & ~Modifier.PROTECTED) | Modifier.PUBLIC; if (Modifier.isFinal(access)) { addSuperMethod(method, access); continue; } } else if (Modifier.isFinal(access)) { continue; } else if (!Modifier.isPublic(access)) { continue; // package protected by process of elimination; we can't override } addMethod(method, access); } Class<?> sc = c.getSuperclass(); if (sc != null) { addMethods(sc, t); } for (Class<?> iface : c.getInterfaces()) { addMethods(iface, t); } }
// in src/org/python/compiler/ProxyMaker.java
public void addConstructor(String name, Class<?>[] parameters, Class<?> ret, String sig, int access) throws Exception { Code code = classfile.addMethod("<init>", sig, access); callSuper(code, "<init>", name, parameters, Void.TYPE, sig); }
// in src/org/python/compiler/ProxyMaker.java
public void addConstructors(Class<?> c) throws Exception { Constructor<?>[] constructors = c.getDeclaredConstructors(); String name = mapClass(c); for (Constructor<?> constructor : constructors) { int access = constructor.getModifiers(); if (Modifier.isPrivate(access)) { continue; } if (Modifier.isNative(access)) { access = access & ~Modifier.NATIVE; } if (Modifier.isProtected(access)) { access = access & ~Modifier.PROTECTED | Modifier.PUBLIC; } Class<?>[] parameters = constructor.getParameterTypes(); addConstructor(name, parameters, Void.TYPE, makeSig(Void.TYPE, parameters), access); } }
// in src/org/python/compiler/ProxyMaker.java
public void addSuperMethod(Method method, int access) throws Exception { Class<?>[] parameters = method.getParameterTypes(); Class<?> ret = method.getReturnType(); String superClass = mapClass(method.getDeclaringClass()); String superName = method.getName(); String methodName = superName; if (Modifier.isFinal(access)) { methodName = "super__" + superName; access &= ~Modifier.FINAL; } addSuperMethod(methodName, superName, superClass, parameters, ret, makeSig(ret, parameters), access); }
// in src/org/python/compiler/ProxyMaker.java
public void addSuperMethod(String methodName, String superName, String declClass, Class<?>[] parameters, Class<?> ret, String sig, int access) throws Exception { if (methodName.startsWith("super__")) { /* rationale: JC java-class, P proxy-class subclassing JC in order to avoid infinite recursion P should define super__foo only if no class between P and JC in the hierarchy defines it yet; this means that the python class needing P is the first that redefines the JC method foo. */ try { superclass.getMethod(methodName, parameters); return; } catch (NoSuchMethodException e) { // OK, no one else defines it, so we need to } catch (SecurityException e) { return; } } supernames.add(methodName); Code code = classfile.addMethod(methodName, sig, access); callSuper(code, superName, declClass, parameters, ret, sig); }
// in src/org/python/compiler/ProxyMaker.java
public void addProxy() throws Exception { // implement PyProxy interface classfile.addField("__proxy", $pyObj, Modifier.PROTECTED); // setProxy methods Code code = classfile.addMethod("_setPyInstance", makeSig("V", $pyObj), Modifier.PUBLIC); code.aload(0); code.aload(1); code.putfield(classfile.name, "__proxy", $pyObj); code.return_(); // getProxy method code = classfile.addMethod("_getPyInstance", makeSig($pyObj), Modifier.PUBLIC); code.aload(0); code.getfield(classfile.name, "__proxy", $pyObj); code.areturn(); String pySys = "Lorg/python/core/PySystemState;"; // implement PyProxy interface classfile.addField("__systemState", pySys, Modifier.PROTECTED | Modifier.TRANSIENT); // setProxy method code = classfile.addMethod("_setPySystemState", makeSig("V", pySys), Modifier.PUBLIC); code.aload(0); code.aload(1); code.putfield(classfile.name, "__systemState", pySys); code.return_(); // getProxy method code = classfile.addMethod("_getPySystemState", makeSig(pySys), Modifier.PUBLIC); code.aload(0); code.getfield(classfile.name, "__systemState", pySys); code.areturn(); }
// in src/org/python/compiler/ProxyMaker.java
public void addClassDictInit() throws Exception { // classDictInit method classfile.addInterface(mapClass(org.python.core.ClassDictInit.class)); Code code = classfile.addMethod("classDictInit", makeSig("V", $pyObj), Modifier.PUBLIC | Modifier.STATIC); code.aload(0); code.ldc("__supernames__"); int strArray = CodeCompiler.makeStrings(code, supernames); code.aload(strArray); code.freeLocal(strArray); code.invokestatic("org/python/core/Py", "java2py", makeSig($pyObj, $obj)); code.invokevirtual("org/python/core/PyObject", "__setitem__", makeSig("V", $str, $pyObj)); code.return_(); }
// in src/org/python/compiler/ProxyMaker.java
public void build(OutputStream out) throws Exception { build(); classfile.write(out); }
// in src/org/python/compiler/ProxyMaker.java
public void build() throws Exception { names = Generic.set(); int access = superclass.getModifiers(); if ((access & Modifier.FINAL) != 0) { throw new InstantiationException("can't subclass final class"); } access = Modifier.PUBLIC | Modifier.SYNCHRONIZED; classfile = new ClassFile(myClass, mapClass(superclass), access); addProxy(); addConstructors(superclass); classfile.addInterface("org/python/core/PyProxy"); Set<String> seenmethods = Generic.set(); addMethods(superclass, seenmethods); for (Class<?> iface : interfaces) { if (iface.isAssignableFrom(superclass)) { Py.writeWarning("compiler", "discarding redundant interface: " + iface.getName()); continue; } classfile.addInterface(mapClass(iface)); addMethods(iface, seenmethods); } doConstants(); addClassDictInit(); }
// in src/org/python/compiler/AdapterMaker.java
Override public void build() throws Exception { names = Generic.set(); int access = Opcodes.ACC_PUBLIC | Opcodes.ACC_SYNCHRONIZED; classfile = new ClassFile(myClass, "java/lang/Object", access); classfile.addInterface(mapClass(interfaces[0])); addMethods(interfaces[0], new HashSet<String>()); addConstructors(Object.class); doConstants(); }
// in src/org/python/compiler/AdapterMaker.java
Override public void doConstants() throws Exception { for (String name : names) { classfile.addField(name, $pyObj, Opcodes.ACC_PUBLIC); } }
// in src/org/python/compiler/AdapterMaker.java
Override public void addMethod(Method method, int access) throws Exception { Class<?>[] parameters = method.getParameterTypes(); Class<?> ret = method.getReturnType(); String name = method.getName(); names.add(name); Code code = classfile.addMethod(name, makeSig(ret, parameters), Opcodes.ACC_PUBLIC); code.aload(0); code.getfield(classfile.name, name, $pyObj); code.dup(); Label returnNull = new Label(); code.ifnull(returnNull); callMethod(code, name, parameters, ret, method.getExceptionTypes()); code.label(returnNull); doNullReturn(code, ret); }
// in src/org/python/compiler/ScopeInfo.java
public void cook(ScopeInfo up, int distance, CompilationContext ctxt) throws Exception { if(up == null) return; // top level => nop this.up = up; this.distance = distance; boolean func = kind == FUNCSCOPE; Vector<String> purecells = new Vector<String>(); cell = 0; boolean some_inner_free = inner_free.size() > 0; for (Enumeration e = inner_free.keys(); e.hasMoreElements(); ) { String name = (String)e.nextElement(); SymInfo info = tbl.get(name); if (info == null) { tbl.put(name,new SymInfo(FREE)); continue; } int flags = info.flags; if (func) { // not func global and bound ? if ((flags&NGLOBAL) == 0 && (flags&BOUND) != 0) { info.flags |= CELL; if ((info.flags&PARAM) != 0) jy_paramcells.addElement(name); cellvars.addElement(name); info.env_index = cell++; if ((flags&PARAM) == 0) purecells.addElement(name); continue; } } else { info.flags |= FREE; } } boolean some_free = false; boolean nested = up.kind != TOPSCOPE; for (Map.Entry<String, SymInfo> entry : tbl.entrySet()) { String name = entry.getKey(); SymInfo info = entry.getValue(); int flags = info.flags; if (nested && (flags&FREE) != 0) up.inner_free.put(name,PRESENT); if ((flags&(GLOBAL|PARAM|CELL)) == 0) { if ((flags&BOUND) != 0) { // ?? only func // System.err.println("local: "+name); names.addElement(name); info.locals_index = local++; continue; } info.flags |= FREE; some_free = true; if (nested) up.inner_free.put(name,PRESENT); } } if ((jy_npurecell = purecells.size()) > 0) { int sz = purecells.size(); for (int i = 0; i < sz; i++) { names.addElement(purecells.elementAt(i)); } } if (some_free && nested) { up.contains_ns_free_vars = true; } // XXX - this doesn't catch all cases - may depend subtly // on how visiting NOW works with antlr compared to javacc if ((unqual_exec || from_import_star)) { if(some_inner_free) dynastuff_trouble(true, ctxt); else if(func_level > 1 && some_free) dynastuff_trouble(false, ctxt); } }
// in src/org/python/compiler/ScopeInfo.java
private void dynastuff_trouble(boolean inner_free, CompilationContext ctxt) throws Exception { StringBuilder illegal = new StringBuilder(); if (unqual_exec && from_import_star) { illegal.append("function '") .append(scope_name) .append("' uses import * and bare exec, which are illegal"); } else if (unqual_exec) { illegal.append("unqualified exec is not allowed in function '") .append(scope_name) .append("'"); } else { illegal.append("import * is not allowed in function '").append(scope_name).append("'"); } if (inner_free) { illegal.append(" because it contains a function with free variables"); } else { illegal.append(" because it contains free variables"); } ctxt.error(illegal.toString(), true, scope_node); }
// in src/org/python/compiler/Future.java
private boolean check(ImportFrom cand) throws Exception { if (!cand.getInternalModule().equals(FutureFeature.MODULE_NAME)) return false; if (cand.getInternalNames().isEmpty()) { throw new ParseException( "future statement does not support import *", cand); } try { for (alias feature : cand.getInternalNames()) { // *known* features FutureFeature.addFeature(feature.getInternalName(), features); } } catch (ParseException pe) { throw new ParseException(pe.getMessage(), cand); } return true; }
// in src/org/python/compiler/Future.java
public void preprocessFutures(mod node, org.python.core.CompilerFlags cflags) throws Exception { if (cflags != null) { if (cflags.isFlagSet(CodeFlag.CO_FUTURE_DIVISION)) FutureFeature.division.addTo(features); if (cflags.isFlagSet(CodeFlag.CO_FUTURE_WITH_STATEMENT)) FutureFeature.with_statement.addTo(features); if (cflags.isFlagSet(CodeFlag.CO_FUTURE_ABSOLUTE_IMPORT)) FutureFeature.absolute_import.addTo(features); } int beg = 0; List<stmt> suite = null; if (node instanceof Module) { suite = ((Module) node).getInternalBody(); if (suite.size() > 0 && suite.get(0) instanceof Expr && ((Expr) suite.get(0)).getInternalValue() instanceof Str) { beg++; } } else if (node instanceof Interactive) { suite = ((Interactive) node).getInternalBody(); } else { return; } for (int i = beg; i < suite.size(); i++) { stmt s = suite.get(i); if (!(s instanceof ImportFrom)) break; s.from_future_checked = true; if (!check((ImportFrom) s)) break; } if (cflags != null) { for (FutureFeature feature : featureSet) { feature.setFlag(cflags); } } }
// in src/org/python/compiler/Future.java
public static void checkFromFuture(ImportFrom node) throws Exception { if (node.from_future_checked) return; if (node.getInternalModule().equals(FutureFeature.MODULE_NAME)) { throw new ParseException("from __future__ imports must occur " + "at the beginning of the file", node); } node.from_future_checked = true; }
// in src/org/python/compiler/CodeCompiler.java
public void loadFrame() throws Exception { code.aload(1); }
// in src/org/python/compiler/CodeCompiler.java
public void loadThreadState() throws Exception { code.aload(2); }
// in src/org/python/compiler/CodeCompiler.java
public void setLastI(int idx) throws Exception { loadFrame(); code.iconst(idx); code.putfield(p(PyFrame.class), "f_lasti", "I"); }
// in src/org/python/compiler/CodeCompiler.java
private void loadf_back() throws Exception { code.getfield(p(PyFrame.class), "f_back", ci(PyFrame.class)); }
// in src/org/python/compiler/CodeCompiler.java
public int storeTop() throws Exception { int tmp = code.getLocal(p(PyObject.class)); code.astore(tmp); return tmp; }
// in src/org/python/compiler/CodeCompiler.java
public void setline(int line) throws Exception { if (module.linenumbers) { code.setline(line); loadFrame(); code.iconst(line); code.invokevirtual(p(PyFrame.class), "setline", sig(Void.TYPE, Integer.TYPE)); } }
// in src/org/python/compiler/CodeCompiler.java
public void setline(PythonTree node) throws Exception { setline(node.getLine()); }
// in src/org/python/compiler/CodeCompiler.java
public void set(PythonTree node) throws Exception { int tmp = storeTop(); set(node, tmp); code.aconst_null(); code.astore(tmp); code.freeLocal(tmp); }
// in src/org/python/compiler/CodeCompiler.java
public void set(PythonTree node, int tmp) throws Exception { temporary = tmp; visit(node); }
// in src/org/python/compiler/CodeCompiler.java
private void saveAugTmps(PythonTree node, int count) throws Exception { if (count >= 4) { augtmp4 = code.getLocal(ci(PyObject.class)); code.astore(augtmp4); } if (count >= 3) { augtmp3 = code.getLocal(ci(PyObject.class)); code.astore(augtmp3); } if (count >= 2) { augtmp2 = code.getLocal(ci(PyObject.class)); code.astore(augtmp2); } augtmp1 = code.getLocal(ci(PyObject.class)); code.astore(augtmp1); code.aload(augtmp1); if (count >= 2) { code.aload(augtmp2); } if (count >= 3) { code.aload(augtmp3); } if (count >= 4) { code.aload(augtmp4); } }
// in src/org/python/compiler/CodeCompiler.java
private void restoreAugTmps(PythonTree node, int count) throws Exception { code.aload(augtmp1); code.freeLocal(augtmp1); if (count == 1) { return; } code.aload(augtmp2); code.freeLocal(augtmp2); if (count == 2) { return; } code.aload(augtmp3); code.freeLocal(augtmp3); if (count == 3) { return; } code.aload(augtmp4); code.freeLocal(augtmp4); }
// in src/org/python/compiler/CodeCompiler.java
void parse(mod node, Code code, boolean fast_locals, String className, Str classDoc, boolean classBody, ScopeInfo scope, CompilerFlags cflags) throws Exception { this.fast_locals = fast_locals; this.className = className; this.code = code; this.cflags = cflags; this.my_scope = scope; this.tbl = scope.tbl; //BEGIN preparse if (classBody) { // Set the class's __module__ to __name__. fails when there's no __name__ loadFrame(); code.ldc("__module__"); loadFrame(); code.ldc("__name__"); code.invokevirtual(p(PyFrame.class), "getname", sig(PyObject.class, String.class)); code.invokevirtual(p(PyFrame.class), "setlocal", sig(Void.TYPE, String.class, PyObject.class)); if (classDoc != null) { loadFrame(); code.ldc("__doc__"); visit(classDoc); code.invokevirtual(p(PyFrame.class), "setlocal", sig(Void.TYPE, String.class, PyObject.class)); } } Label genswitch = new Label(); if (my_scope.generator) { code.goto_(genswitch); } Label start = new Label(); code.label(start); int nparamcell = my_scope.jy_paramcells.size(); if (nparamcell > 0) { java.util.List<String> paramcells = my_scope.jy_paramcells; for (int i = 0; i < nparamcell; i++) { code.aload(1); SymInfo syminf = tbl.get(paramcells.get(i)); code.iconst(syminf.locals_index); code.iconst(syminf.env_index); code.invokevirtual(p(PyFrame.class), "to_cell", sig(Void.TYPE, Integer.TYPE, Integer.TYPE)); } } //END preparse optimizeGlobals = checkOptimizeGlobals(fast_locals, my_scope); if (my_scope.max_with_count > 0) { // allocate for all the with-exits we will have in the frame; // this allows yield and with to happily co-exist loadFrame(); code.iconst(my_scope.max_with_count); code.anewarray(p(PyObject.class)); code.putfield(p(PyFrame.class), "f_exits", ci(PyObject[].class)); } Object exit = visit(node); if (classBody) { loadFrame(); code.invokevirtual(p(PyFrame.class), "getf_locals", sig(PyObject.class)); code.areturn(); } else { if (exit == null) { setLastI(-1); getNone(); code.areturn(); } } //BEGIN postparse // similar to visitResume code in pyasm.py if (my_scope.generator) { code.label(genswitch); code.aload(1); code.getfield(p(PyFrame.class), "f_lasti", "I"); Label[] y = new Label[yields.size() + 1]; y[0] = start; for (int i = 1; i < y.length; i++) { y[i] = yields.get(i - 1); } code.tableswitch(0, y.length - 1, start, y); } //END postparse }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitInteractive(Interactive node) throws Exception { traverse(node); return null; }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitModule(org.python.antlr.ast.Module suite) throws Exception { Str docStr = getDocStr(suite.getInternalBody()); if (docStr != null) { loadFrame(); code.ldc("__doc__"); visit(docStr); code.invokevirtual(p(PyFrame.class), "setglobal", sig(Void.TYPE, String.class, PyObject.class)); } traverse(suite); return null; }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitExpression(Expression node) throws Exception { if (my_scope.generator && node.getInternalBody() != null) { module.error("'return' with argument inside generator", true, node); } return visitReturn(new Return(node, node.getInternalBody()), true); }
// in src/org/python/compiler/CodeCompiler.java
public int makeArray(java.util.List<? extends PythonTree> nodes) throws Exception { // XXX: This should produce an array on the stack (if possible) instead of a local // the caller is responsible for freeing. int n; if (nodes == null) { n = 0; } else { n = nodes.size(); } int array = code.getLocal(ci(PyObject[].class)); if (n == 0) { code.getstatic(p(Py.class), "EmptyObjects", ci(PyObject[].class)); code.astore(array); } else { code.iconst(n); code.anewarray(p(PyObject.class)); code.astore(array); for (int i = 0; i < n; i++) { visit(nodes.get(i)); code.aload(array); code.swap(); code.iconst(i); code.swap(); code.aastore(); } } return array; }
// in src/org/python/compiler/CodeCompiler.java
public boolean makeClosure(ScopeInfo scope) throws Exception { if (scope == null || scope.freevars == null) { return false; } int n = scope.freevars.size(); if (n == 0) { return false; } int tmp = code.getLocal(ci(PyObject[].class)); code.iconst(n); code.anewarray(p(PyObject.class)); code.astore(tmp); Map<String, SymInfo> upTbl = scope.up.tbl; for (int i = 0; i < n; i++) { code.aload(tmp); code.iconst(i); loadFrame(); for (int j = 1; j < scope.distance; j++) { loadf_back(); } SymInfo symInfo = upTbl.get(scope.freevars.elementAt(i)); code.iconst(symInfo.env_index); code.invokevirtual(p(PyFrame.class), "getclosure", sig(PyObject.class, Integer.TYPE)); code.aastore(); } code.aload(tmp); code.freeLocal(tmp); return true; }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitFunctionDef(FunctionDef node) throws Exception { String name = getName(node.getInternalName()); setline(node); ScopeInfo scope = module.getScopeInfo(node); // NOTE: this is attached to the constructed PyFunction, so it cannot be nulled out // with freeArray, unlike other usages of makeArray here int defaults = makeArray(scope.ac.getDefaults()); code.new_(p(PyFunction.class)); code.dup(); loadFrame(); code.getfield(p(PyFrame.class), "f_globals", ci(PyObject.class)); code.aload(defaults); code.freeLocal(defaults); scope.setup_closure(); scope.dump(); module.codeConstant(new Suite(node, node.getInternalBody()), name, true, className, false, false, node.getLine(), scope, cflags).get(code); Str docStr = getDocStr(node.getInternalBody()); if (docStr != null) { visit(docStr); } else { code.aconst_null(); } if (!makeClosure(scope)) { code.invokespecial(p(PyFunction.class), "<init>", sig(Void.TYPE, PyObject.class, PyObject[].class, PyCode.class, PyObject.class)); } else { code.invokespecial(p(PyFunction.class), "<init>", sig(Void.TYPE, PyObject.class, PyObject[].class, PyCode.class, PyObject.class, PyObject[].class)); } applyDecorators(node.getInternalDecorator_list()); set(new Name(node, node.getInternalName(), expr_contextType.Store)); return null; }
// in src/org/python/compiler/CodeCompiler.java
private void applyDecorators(java.util.List<expr> decorators) throws Exception { if (decorators != null && !decorators.isEmpty()) { int res = storeTop(); for (expr decorator : decorators) { visit(decorator); stackProduce(); } for (int i = decorators.size(); i > 0; i--) { stackConsume(); loadThreadState(); code.aload(res); code.invokevirtual(p(PyObject.class), "__call__", sig(PyObject.class, ThreadState.class, PyObject.class)); code.astore(res); } code.aload(res); code.freeLocal(res); } }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitExpr(Expr node) throws Exception { setline(node); visit(node.getInternalValue()); if (print_results) { code.invokestatic(p(Py.class), "printResult", sig(Void.TYPE, PyObject.class)); } else { code.pop(); } return null; }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitAssign(Assign node) throws Exception { setline(node); visit(node.getInternalValue()); if (node.getInternalTargets().size() == 1) { set(node.getInternalTargets().get(0)); } else { int tmp = storeTop(); for (expr target : node.getInternalTargets()) { set(target, tmp); } code.freeLocal(tmp); } return null; }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitPrint(Print node) throws Exception { setline(node); int tmp = -1; if (node.getInternalDest() != null) { visit(node.getInternalDest()); tmp = storeTop(); } if (node.getInternalValues() == null || node.getInternalValues().size() == 0) { if (node.getInternalDest() != null) { code.aload(tmp); code.invokestatic(p(Py.class), "printlnv", sig(Void.TYPE, PyObject.class)); } else { code.invokestatic(p(Py.class), "println", sig(Void.TYPE)); } } else { for (int i = 0; i < node.getInternalValues().size(); i++) { if (node.getInternalDest() != null) { code.aload(tmp); visit(node.getInternalValues().get(i)); if (node.getInternalNl() && i == node.getInternalValues().size() - 1) { code.invokestatic(p(Py.class), "println", sig(Void.TYPE, PyObject.class, PyObject.class)); } else { code.invokestatic(p(Py.class), "printComma", sig(Void.TYPE, PyObject.class, PyObject.class)); } } else { visit(node.getInternalValues().get(i)); if (node.getInternalNl() && i == node.getInternalValues().size() - 1) { code.invokestatic(p(Py.class), "println", sig(Void.TYPE, PyObject.class)); } else { code.invokestatic(p(Py.class), "printComma", sig(Void.TYPE, PyObject.class)); } } } } if (node.getInternalDest() != null) { code.freeLocal(tmp); } return null; }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitDelete(Delete node) throws Exception { setline(node); traverse(node); return null; }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitPass(Pass node) throws Exception { setline(node); return null; }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitBreak(Break node) throws Exception { //setline(node); Not needed here... if (breakLabels.empty()) { throw new ParseException("'break' outside loop", node); } doFinallysDownTo(bcfLevel); code.goto_(breakLabels.peek()); return null; }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitContinue(Continue node) throws Exception { //setline(node); Not needed here... if (continueLabels.empty()) { throw new ParseException("'continue' not properly in loop", node); } doFinallysDownTo(bcfLevel); code.goto_(continueLabels.peek()); return Exit; }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitYield(Yield node) throws Exception { setline(node); if (!fast_locals) { throw new ParseException("'yield' outside function", node); } int stackState = saveStack(); if (node.getInternalValue() != null) { visit(node.getInternalValue()); } else { getNone(); } setLastI(++yield_count); saveLocals(); code.areturn(); Label restart = new Label(); yields.addElement(restart); code.label(restart); restoreLocals(); restoreStack(stackState); loadFrame(); code.invokevirtual(p(PyFrame.class), "getGeneratorInput", sig(Object.class)); code.dup(); code.instanceof_(p(PyException.class)); Label done2 = new Label(); code.ifeq(done2); code.checkcast(p(Throwable.class)); code.athrow(); code.label(done2); code.checkcast(p(PyObject.class)); return null; }
// in src/org/python/compiler/CodeCompiler.java
private int saveStack() throws Exception { if (stack.size() > 0) { int array = code.getLocal(ci(Object[].class)); code.iconst(stack.size()); code.anewarray(p(Object.class)); code.astore(array); ListIterator<String> content = stack.listIterator(stack.size()); for (int i = 0; content.hasPrevious(); i++) { String signature = content.previous(); if (p(ThreadState.class).equals(signature)) { // Stack: ... threadstate code.pop(); // Stack: ... } else { code.aload(array); // Stack: |- ... value array code.swap(); code.iconst(i++); code.swap(); // Stack: |- ... array index value code.aastore(); // Stack: |- ... } } return array; } else { return -1; } }
// in src/org/python/compiler/CodeCompiler.java
private void restoreStack(int array) throws Exception { if (stack.size() > 0) { int i = stack.size() - 1; for (String signature : stack) { if (p(ThreadState.class).equals(signature)) { loadThreadState(); } else { code.aload(array); // Stack: |- ... array code.iconst(i--); code.aaload(); // Stack: |- ... value code.checkcast(signature); } } code.freeLocal(array); } }
// in src/org/python/compiler/CodeCompiler.java
private void restoreLocals() throws Exception { endExceptionHandlers(); Vector<String> v = code.getActiveLocals(); loadFrame(); code.getfield(p(PyFrame.class), "f_savedlocals", ci(Object[].class)); int locals = code.getLocal(ci(Object[].class)); code.astore(locals); for (int i = 0; i < v.size(); i++) { String type = v.elementAt(i); if (type == null) { continue; } code.aload(locals); code.iconst(i); code.aaload(); code.checkcast(type); code.astore(i); } code.freeLocal(locals); restartExceptionHandlers(); }
// in src/org/python/compiler/CodeCompiler.java
private void saveLocals() throws Exception { Vector<String> v = code.getActiveLocals(); code.iconst(v.size()); code.anewarray(p(Object.class)); int locals = code.getLocal(ci(Object[].class)); code.astore(locals); for (int i = 0; i < v.size(); i++) { String type = v.elementAt(i); if (type == null) { continue; } code.aload(locals); code.iconst(i); //code.checkcast(code.pool.Class(p(Object.class))); if (i == 2222) { code.aconst_null(); } else { code.aload(i); } code.aastore(); } loadFrame(); code.aload(locals); code.putfield(p(PyFrame.class), "f_savedlocals", ci(Object[].class)); code.freeLocal(locals); }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitReturn(Return node) throws Exception { return visitReturn(node, false); }
// in src/org/python/compiler/CodeCompiler.java
public Object visitReturn(Return node, boolean inEval) throws Exception { setline(node); if (!inEval && !fast_locals) { throw new ParseException("'return' outside function", node); } int tmp = 0; if (node.getInternalValue() != null) { if (my_scope.generator) { throw new ParseException("'return' with argument " + "inside generator", node); } visit(node.getInternalValue()); tmp = code.getReturnLocal(); code.astore(tmp); } doFinallysDownTo(0); setLastI(-1); if (node.getInternalValue() != null) { code.aload(tmp); } else { getNone(); } code.areturn(); return Exit; }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitRaise(Raise node) throws Exception { setline(node); if (node.getInternalType() != null) { visit(node.getInternalType()); stackProduce(); } if (node.getInternalInst() != null) { visit(node.getInternalInst()); stackProduce(); } if (node.getInternalTback() != null) { visit(node.getInternalTback()); stackProduce(); } if (node.getInternalType() == null) { code.invokestatic(p(Py.class), "makeException", sig(PyException.class)); } else if (node.getInternalInst() == null) { stackConsume(); code.invokestatic(p(Py.class), "makeException", sig(PyException.class, PyObject.class)); } else if (node.getInternalTback() == null) { stackConsume(2); code.invokestatic(p(Py.class), "makeException", sig(PyException.class, PyObject.class, PyObject.class)); } else { stackConsume(3); code.invokestatic(p(Py.class), "makeException", sig(PyException.class, PyObject.class, PyObject.class, PyObject.class)); } code.athrow(); return Exit; }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitImport(Import node) throws Exception { setline(node); for (alias a : node.getInternalNames()) { String asname = null; if (a.getInternalAsname() != null) { String name = a.getInternalName(); asname = a.getInternalAsname(); code.ldc(name); loadFrame(); defaultImportLevel(); code.invokestatic(p(imp.class), "importOneAs", sig(PyObject.class, String.class, PyFrame.class, Integer.TYPE)); } else { String name = a.getInternalName(); asname = name; if (asname.indexOf('.') > 0) { asname = asname.substring(0, asname.indexOf('.')); } code.ldc(name); loadFrame(); defaultImportLevel(); code.invokestatic(p(imp.class), "importOne", sig(PyObject.class, String.class, PyFrame.class, Integer.TYPE)); } set(new Name(a, asname, expr_contextType.Store)); } return null; }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitImportFrom(ImportFrom node) throws Exception { Future.checkFromFuture(node); // future stmt support setline(node); code.ldc(node.getInternalModule()); java.util.List<alias> aliases = node.getInternalNames(); if (aliases == null || aliases.size() == 0) { throw new ParseException("Internel parser error", node); } else if (aliases.size() == 1 && aliases.get(0).getInternalName().equals("*")) { if (node.getInternalLevel() > 0) { throw new ParseException("'import *' not allowed with 'from .'", node); } if (my_scope.func_level > 0) { module.error("import * only allowed at module level", false, node); if (my_scope.contains_ns_free_vars) { module.error("import * is not allowed in function '" + my_scope.scope_name + "' because it contains a nested function with free variables", true, node); } } if (my_scope.func_level > 1) { module.error("import * is not allowed in function '" + my_scope.scope_name + "' because it is a nested function", true, node); } loadFrame(); defaultImportLevel(); code.invokestatic(p(imp.class), "importAll", sig(Void.TYPE, String.class, PyFrame.class, Integer.TYPE)); } else { java.util.List<String> fromNames = new ArrayList<String>();//[names.size()]; java.util.List<String> asnames = new ArrayList<String>();//[names.size()]; for (int i = 0; i < aliases.size(); i++) { fromNames.add(aliases.get(i).getInternalName()); asnames.add(aliases.get(i).getInternalAsname()); if (asnames.get(i) == null) { asnames.set(i, fromNames.get(i)); } } int strArray = makeStrings(code, fromNames); code.aload(strArray); code.freeLocal(strArray); loadFrame(); if (node.getInternalLevel() == 0) { defaultImportLevel(); } else { code.iconst(node.getInternalLevel()); } code.invokestatic(p(imp.class), "importFrom", sig(PyObject[].class, String.class, String[].class, PyFrame.class, Integer.TYPE)); int tmp = storeTop(); for (int i = 0; i < aliases.size(); i++) { code.aload(tmp); code.iconst(i); code.aaload(); set(new Name(aliases.get(i), asnames.get(i), expr_contextType.Store)); } code.freeLocal(tmp); } return null; }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitGlobal(Global node) throws Exception { return null; }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitExec(Exec node) throws Exception { setline(node); visit(node.getInternalBody()); stackProduce(); if (node.getInternalGlobals() != null) { visit(node.getInternalGlobals()); } else { code.aconst_null(); } stackProduce(); if (node.getInternalLocals() != null) { visit(node.getInternalLocals()); } else { code.aconst_null(); } stackProduce(); //do the real work here stackConsume(3); code.invokestatic(p(Py.class), "exec", sig(Void.TYPE, PyObject.class, PyObject.class, PyObject.class)); return null; }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitAssert(Assert node) throws Exception { setline(node); Label end_of_assert = new Label(); /* First do an if __debug__: */ loadFrame(); emitGetGlobal("__debug__"); code.invokevirtual(p(PyObject.class), "__nonzero__", sig(Boolean.TYPE)); code.ifeq(end_of_assert); /* Now do the body of the assert. If PyObject.__nonzero__ is true, then the assertion succeeded, the message portion should not be processed. Otherwise, the message will be processed. */ visit(node.getInternalTest()); code.invokevirtual(p(PyObject.class), "__nonzero__", sig(Boolean.TYPE)); /* If evaluation is false, then branch to end of method */ code.ifne(end_of_assert); /* Visit the message part of the assertion, or pass Py.None */ if (node.getInternalMsg() != null) { visit(node.getInternalMsg()); } else { getNone(); } /* Push exception type onto stack(AssertionError) */ loadFrame(); emitGetGlobal("AssertionError"); code.swap(); // The type is the first argument, but the message could be a yield code.invokestatic(p(Py.class), "makeException", sig(PyException.class, PyObject.class, PyObject.class)); /* Raise assertion error. Only executes this logic if assertion failed */ code.athrow(); /* And finally set the label for the end of it all */ code.label(end_of_assert); return null; }
// in src/org/python/compiler/CodeCompiler.java
public Object doTest(Label end_of_if, If node, int index) throws Exception { Label end_of_suite = new Label(); setline(node.getInternalTest()); visit(node.getInternalTest()); code.invokevirtual(p(PyObject.class), "__nonzero__", sig(Boolean.TYPE)); code.ifeq(end_of_suite); Object exit = suite(node.getInternalBody()); if (end_of_if != null && exit == null) { code.goto_(end_of_if); } code.label(end_of_suite); if (node.getInternalOrelse() != null) { return suite(node.getInternalOrelse()) != null ? exit : null; } else { return null; } }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitIf(If node) throws Exception { Label end_of_if = null; if (node.getInternalOrelse() != null) { end_of_if = new Label(); } Object exit = doTest(end_of_if, node, 0); if (end_of_if != null) { code.label(end_of_if); } return exit; }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitIfExp(IfExp node) throws Exception { setline(node.getInternalTest()); Label end = new Label(); Label end_of_else = new Label(); visit(node.getInternalTest()); code.invokevirtual(p(PyObject.class), "__nonzero__", sig(Boolean.TYPE)); code.ifeq(end_of_else); visit(node.getInternalBody()); code.goto_(end); code.label(end_of_else); visit(node.getInternalOrelse()); code.label(end); return null; }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitWhile(While node) throws Exception { int savebcf = beginLoop(); Label continue_loop = continueLabels.peek(); Label break_loop = breakLabels.peek(); Label start_loop = new Label(); code.goto_(continue_loop); code.label(start_loop); //Do suite suite(node.getInternalBody()); code.label(continue_loop); setline(node); //Do test visit(node.getInternalTest()); code.invokevirtual(p(PyObject.class), "__nonzero__", sig(Boolean.TYPE)); code.ifne(start_loop); finishLoop(savebcf); if (node.getInternalOrelse() != null) { //Do else suite(node.getInternalOrelse()); } code.label(break_loop); // Probably need to detect "guaranteed exits" return null; }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitFor(For node) throws Exception { int savebcf = beginLoop(); Label continue_loop = continueLabels.peek(); Label break_loop = breakLabels.peek(); Label start_loop = new Label(); Label next_loop = new Label(); setline(node); //parse the list visit(node.getInternalIter()); int iter_tmp = code.getLocal(p(PyObject.class)); int expr_tmp = code.getLocal(p(PyObject.class)); //set up the loop iterator code.invokevirtual(p(PyObject.class), "__iter__", sig(PyObject.class)); code.astore(iter_tmp); //do check at end of loop. Saves one opcode ;-) code.goto_(next_loop); code.label(start_loop); //set iter variable to current entry in list set(node.getInternalTarget(), expr_tmp); //evaluate for body suite(node.getInternalBody()); code.label(continue_loop); code.label(next_loop); setline(node); //get the next element from the list code.aload(iter_tmp); code.invokevirtual(p(PyObject.class), "__iternext__", sig(PyObject.class)); code.astore(expr_tmp); code.aload(expr_tmp); //if no more elements then fall through code.ifnonnull(start_loop); finishLoop(savebcf); if (node.getInternalOrelse() != null) { //Do else clause if provided suite(node.getInternalOrelse()); } code.label(break_loop); code.freeLocal(iter_tmp); code.freeLocal(expr_tmp); // Probably need to detect "guaranteed exits" return null; }
// in src/org/python/compiler/CodeCompiler.java
public void exceptionTest(int exc, Label end_of_exceptions, TryExcept node, int index) throws Exception { for (int i = 0; i < node.getInternalHandlers().size(); i++) { ExceptHandler handler = (ExceptHandler) node.getInternalHandlers().get(i); //setline(name); Label end_of_self = new Label(); if (handler.getInternalType() != null) { code.aload(exc); //get specific exception visit(handler.getInternalType()); code.invokevirtual(p(PyException.class), "match", sig(Boolean.TYPE, PyObject.class)); code.ifeq(end_of_self); } else { if (i != node.getInternalHandlers().size() - 1) { throw new ParseException( "default 'except:' must be last", handler); } } if (handler.getInternalName() != null) { code.aload(exc); code.getfield(p(PyException.class), "value", ci(PyObject.class)); set(handler.getInternalName()); } //do exception body suite(handler.getInternalBody()); code.goto_(end_of_exceptions); code.label(end_of_self); } code.aload(exc); code.athrow(); }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitTryFinally(TryFinally node) throws Exception { Label start = new Label(); Label end = new Label(); Label handlerStart = new Label(); Label finallyEnd = new Label(); Object ret; ExceptionHandler inFinally = new ExceptionHandler(node); // Do protected suite exceptionHandlers.push(inFinally); int excLocal = code.getLocal(p(Throwable.class)); code.aconst_null(); code.astore(excLocal); code.label(start); inFinally.exceptionStarts.addElement(start); ret = suite(node.getInternalBody()); code.label(end); inFinally.exceptionEnds.addElement(end); inFinally.bodyDone = true; exceptionHandlers.pop(); if (ret == NoExit) { inlineFinally(inFinally); code.goto_(finallyEnd); } // Handle any exceptions that get thrown in suite code.label(handlerStart); code.astore(excLocal); code.aload(excLocal); loadFrame(); code.invokestatic(p(Py.class), "addTraceback", sig(Void.TYPE, Throwable.class, PyFrame.class)); inlineFinally(inFinally); code.aload(excLocal); code.checkcast(p(Throwable.class)); code.athrow(); code.label(finallyEnd); code.freeLocal(excLocal); inFinally.addExceptionHandlers(handlerStart); // According to any JVM verifiers, this code block might not return return null; }
// in src/org/python/compiler/CodeCompiler.java
private void inlineFinally(ExceptionHandler handler) throws Exception { if (!handler.bodyDone) { // end the previous exception block so inlined finally code doesn't // get covered by our exception handler. Label end = new Label(); code.label(end); handler.exceptionEnds.addElement(end); // also exiting the try: portion of this particular finally } if (handler.isFinallyHandler()) { handler.finalBody(this); } }
// in src/org/python/compiler/CodeCompiler.java
private void reenterProtectedBody(ExceptionHandler handler) throws Exception { // restart exception coverage Label restart = new Label(); code.label(restart); handler.exceptionStarts.addElement(restart); }
// in src/org/python/compiler/CodeCompiler.java
private void doFinallysDownTo(int level) throws Exception { Stack<ExceptionHandler> poppedHandlers = new Stack<ExceptionHandler>(); while (exceptionHandlers.size() > level) { ExceptionHandler handler = exceptionHandlers.pop(); inlineFinally(handler); poppedHandlers.push(handler); } while (poppedHandlers.size() > 0) { ExceptionHandler handler = poppedHandlers.pop(); reenterProtectedBody(handler); exceptionHandlers.push(handler); } }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitTryExcept(TryExcept node) throws Exception { Label start = new Label(); Label end = new Label(); Label handler_start = new Label(); Label handler_end = new Label(); ExceptionHandler handler = new ExceptionHandler(); code.label(start); handler.exceptionStarts.addElement(start); exceptionHandlers.push(handler); //Do suite Object exit = suite(node.getInternalBody()); exceptionHandlers.pop(); code.label(end); handler.exceptionEnds.addElement(end); if (exit == null) { code.goto_(handler_end); } code.label(handler_start); loadFrame(); code.invokestatic(p(Py.class), "setException", sig(PyException.class, Throwable.class, PyFrame.class)); int exc = code.getFinallyLocal(p(Throwable.class)); code.astore(exc); if (node.getInternalOrelse() == null) { //No else clause to worry about exceptionTest(exc, handler_end, node, 1); code.label(handler_end); } else { //Have else clause Label else_end = new Label(); exceptionTest(exc, else_end, node, 1); code.label(handler_end); //do else clause suite(node.getInternalOrelse()); code.label(else_end); } code.freeFinallyLocal(exc); handler.addExceptionHandlers(handler_start); return null; }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitSuite(Suite node) throws Exception { return suite(node.getInternalBody()); }
// in src/org/python/compiler/CodeCompiler.java
public Object suite(java.util.List<stmt> stmts) throws Exception { for (stmt s : stmts) { Object exit = visit(s); if (exit != null) { return Exit; } } return null; }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitBoolOp(BoolOp node) throws Exception { Label end = new Label(); visit(node.getInternalValues().get(0)); for (int i = 1; i < node.getInternalValues().size(); i++) { code.dup(); code.invokevirtual(p(PyObject.class), "__nonzero__", sig(Boolean.TYPE)); switch (node.getInternalOp()) { case Or: code.ifne(end); break; case And: code.ifeq(end); break; } code.pop(); visit(node.getInternalValues().get(i)); } code.label(end); return null; }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitCompare(Compare node) throws Exception { int last = code.getLocal(p(PyObject.class)); int result = code.getLocal(p(PyObject.class)); Label end = new Label(); visit(node.getInternalLeft()); code.astore(last); int n = node.getInternalOps().size(); for (int i = 0; i < n - 1; i++) { visit(node.getInternalComparators().get(i)); code.aload(last); code.swap(); code.dup(); code.astore(last); visitCmpop(node.getInternalOps().get(i)); code.dup(); code.astore(result); code.invokevirtual(p(PyObject.class), "__nonzero__", sig(Boolean.TYPE)); code.ifeq(end); } visit(node.getInternalComparators().get(n - 1)); code.aload(last); code.swap(); visitCmpop(node.getInternalOps().get(n - 1)); if (n > 1) { code.astore(result); code.label(end); code.aload(result); } code.aconst_null(); code.astore(last); code.freeLocal(last); code.freeLocal(result); return null; }
// in src/org/python/compiler/CodeCompiler.java
public void visitCmpop(cmpopType op) throws Exception { String name = null; switch (op) { case Eq: name = "_eq"; break; case NotEq: name = "_ne"; break; case Lt: name = "_lt"; break; case LtE: name = "_le"; break; case Gt: name = "_gt"; break; case GtE: name = "_ge"; break; case Is: name = "_is"; break; case IsNot: name = "_isnot"; break; case In: name = "_in"; break; case NotIn: name = "_notin"; break; } code.invokevirtual(p(PyObject.class), name, sig(PyObject.class, PyObject.class)); }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitBinOp(BinOp node) throws Exception { visit(node.getInternalLeft()); stackProduce(); visit(node.getInternalRight()); stackConsume(); String name = null; switch (node.getInternalOp()) { case Add: name = "_add"; break; case Sub: name = "_sub"; break; case Mult: name = "_mul"; break; case Div: name = "_div"; break; case Mod: name = "_mod"; break; case Pow: name = "_pow"; break; case LShift: name = "_lshift"; break; case RShift: name = "_rshift"; break; case BitOr: name = "_or"; break; case BitXor: name = "_xor"; break; case BitAnd: name = "_and"; break; case FloorDiv: name = "_floordiv"; break; } if (node.getInternalOp() == operatorType.Div && module.getFutures().areDivisionOn()) { name = "_truediv"; } code.invokevirtual(p(PyObject.class), name, sig(PyObject.class, PyObject.class)); return null; }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitUnaryOp(UnaryOp node) throws Exception { visit(node.getInternalOperand()); String name = null; switch (node.getInternalOp()) { case Invert: name = "__invert__"; break; case Not: name = "__not__"; break; case UAdd: name = "__pos__"; break; case USub: name = "__neg__"; break; } code.invokevirtual(p(PyObject.class), name, sig(PyObject.class)); return null; }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitAugAssign(AugAssign node) throws Exception { setline(node); augmode = expr_contextType.Load; visit(node.getInternalTarget()); int target = storeTop(); visit(node.getInternalValue()); code.aload(target); code.swap(); String name = null; switch (node.getInternalOp()) { case Add: name = "_iadd"; break; case Sub: name = "_isub"; break; case Mult: name = "_imul"; break; case Div: name = "_idiv"; break; case Mod: name = "_imod"; break; case Pow: name = "_ipow"; break; case LShift: name = "_ilshift"; break; case RShift: name = "_irshift"; break; case BitOr: name = "_ior"; break; case BitXor: name = "_ixor"; break; case BitAnd: name = "_iand"; break; case FloorDiv: name = "_ifloordiv"; break; } if (node.getInternalOp() == operatorType.Div && module.getFutures().areDivisionOn()) { name = "_itruediv"; } code.invokevirtual(p(PyObject.class), name, sig(PyObject.class, PyObject.class)); code.freeLocal(target); temporary = storeTop(); augmode = expr_contextType.Store; visit(node.getInternalTarget()); code.freeLocal(temporary); return null; }
// in src/org/python/compiler/CodeCompiler.java
public Object invokeNoKeywords(Attribute node, java.util.List<expr> values) throws Exception { String name = getName(node.getInternalAttr()); visit(node.getInternalValue()); stackProduce(); code.ldc(name); code.invokevirtual(p(PyObject.class), "__getattr__", sig(PyObject.class, String.class)); loadThreadState(); stackProduce(p(ThreadState.class)); switch (values.size()) { case 0: stackConsume(2); // target + ts code.invokevirtual(p(PyObject.class), "__call__", sig(PyObject.class, ThreadState.class)); break; case 1: visit(values.get(0)); stackConsume(2); // target + ts code.invokevirtual(p(PyObject.class), "__call__", sig(PyObject.class, ThreadState.class, PyObject.class)); break; case 2: visit(values.get(0)); stackProduce(); visit(values.get(1)); stackConsume(3); // target + ts + arguments code.invokevirtual(p(PyObject.class), "__call__", sig(PyObject.class, ThreadState.class, PyObject.class, PyObject.class)); break; case 3: visit(values.get(0)); stackProduce(); visit(values.get(1)); stackProduce(); visit(values.get(2)); stackConsume(4); // target + ts + arguments code.invokevirtual(p(PyObject.class), "__call__", sig(PyObject.class, ThreadState.class, PyObject.class, PyObject.class, PyObject.class)); break; case 4: visit(values.get(0)); stackProduce(); visit(values.get(1)); stackProduce(); visit(values.get(2)); stackProduce(); visit(values.get(3)); stackConsume(5); // target + ts + arguments code.invokevirtual(p(PyObject.class), "__call__", sig(PyObject.class, ThreadState.class, PyObject.class, PyObject.class, PyObject.class, PyObject.class)); break; default: int argArray = makeArray(values); code.aload(argArray); code.freeLocal(argArray); stackConsume(2); // target + ts code.invokevirtual(p(PyObject.class), "__call__", sig(PyObject.class, ThreadState.class, PyObject[].class)); break; } return null; }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitCall(Call node) throws Exception { java.util.List<String> keys = new ArrayList<String>(); java.util.List<expr> values = new ArrayList<expr>(); for (int i = 0; i < node.getInternalArgs().size(); i++) { values.add(node.getInternalArgs().get(i)); } for (int i = 0; i < node.getInternalKeywords().size(); i++) { keys.add(node.getInternalKeywords().get(i).getInternalArg()); values.add(node.getInternalKeywords().get(i).getInternalValue()); } if ((node.getInternalKeywords() == null || node.getInternalKeywords().size() == 0) && node.getInternalStarargs() == null && node.getInternalKwargs() == null && node.getInternalFunc() instanceof Attribute) { return invokeNoKeywords((Attribute) node.getInternalFunc(), values); } visit(node.getInternalFunc()); stackProduce(); if (node.getInternalStarargs() != null || node.getInternalKwargs() != null) { int argArray = makeArray(values); int strArray = makeStrings(code, keys); if (node.getInternalStarargs() == null) { code.aconst_null(); } else { visit(node.getInternalStarargs()); } stackProduce(); if (node.getInternalKwargs() == null) { code.aconst_null(); } else { visit(node.getInternalKwargs()); } stackProduce(); code.aload(argArray); code.aload(strArray); code.freeLocal(strArray); code.dup2_x2(); code.pop2(); stackConsume(3); // target + starargs + kwargs code.invokevirtual(p(PyObject.class), "_callextra", sig(PyObject.class, PyObject[].class, String[].class, PyObject.class, PyObject.class)); freeArrayRef(argArray); } else if (keys.size() > 0) { loadThreadState(); stackProduce(p(ThreadState.class)); int argArray = makeArray(values); int strArray = makeStrings(code, keys); code.aload(argArray); code.aload(strArray); code.freeLocal(strArray); stackConsume(2); // target + ts code.invokevirtual(p(PyObject.class), "__call__", sig(PyObject.class, ThreadState.class, PyObject[].class, String[].class)); freeArrayRef(argArray); } else { loadThreadState(); stackProduce(p(ThreadState.class)); switch (values.size()) { case 0: stackConsume(2); // target + ts code.invokevirtual(p(PyObject.class), "__call__", sig(PyObject.class, ThreadState.class)); break; case 1: visit(values.get(0)); stackConsume(2); // target + ts code.invokevirtual(p(PyObject.class), "__call__", sig(PyObject.class, ThreadState.class, PyObject.class)); break; case 2: visit(values.get(0)); stackProduce(); visit(values.get(1)); stackConsume(3); // target + ts + arguments code.invokevirtual(p(PyObject.class), "__call__", sig(PyObject.class, ThreadState.class, PyObject.class, PyObject.class)); break; case 3: visit(values.get(0)); stackProduce(); visit(values.get(1)); stackProduce(); visit(values.get(2)); stackConsume(4); // target + ts + arguments code.invokevirtual(p(PyObject.class), "__call__", sig(PyObject.class, ThreadState.class, PyObject.class, PyObject.class, PyObject.class)); break; case 4: visit(values.get(0)); stackProduce(); visit(values.get(1)); stackProduce(); visit(values.get(2)); stackProduce(); visit(values.get(3)); stackConsume(5); // target + ts + arguments code.invokevirtual(p(PyObject.class), "__call__", sig(PyObject.class, ThreadState.class, PyObject.class, PyObject.class, PyObject.class, PyObject.class)); break; default: int argArray = makeArray(values); code.aload(argArray); code.freeLocal(argArray); stackConsume(2); // target + ts code.invokevirtual(p(PyObject.class), "__call__", sig(PyObject.class, ThreadState.class, PyObject[].class)); break; } } return null; }
// in src/org/python/compiler/CodeCompiler.java
public Object Slice(Subscript node, Slice slice) throws Exception { expr_contextType ctx = node.getInternalCtx(); if (ctx == expr_contextType.AugStore && augmode == expr_contextType.Store) { restoreAugTmps(node, 4); ctx = expr_contextType.Store; } else { visit(node.getInternalValue()); stackProduce(); if (slice.getInternalLower() != null) { visit(slice.getInternalLower()); } else { code.aconst_null(); } stackProduce(); if (slice.getInternalUpper() != null) { visit(slice.getInternalUpper()); } else { code.aconst_null(); } stackProduce(); if (slice.getInternalStep() != null) { visit(slice.getInternalStep()); } else { code.aconst_null(); } stackProduce(); if (node.getInternalCtx() == expr_contextType.AugStore && augmode == expr_contextType.Load) { saveAugTmps(node, 4); ctx = expr_contextType.Load; } stackConsume(4); } switch (ctx) { case Del: code.invokevirtual(p(PyObject.class), "__delslice__", sig(Void.TYPE, PyObject.class, PyObject.class, PyObject.class)); return null; case Load: code.invokevirtual(p(PyObject.class), "__getslice__", sig(PyObject.class, PyObject.class, PyObject.class, PyObject.class)); return null; case Param: case Store: code.aload(temporary); code.invokevirtual(p(PyObject.class), "__setslice__", sig(Void.TYPE, PyObject.class, PyObject.class, PyObject.class, PyObject.class)); return null; } return null; }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitSubscript(Subscript node) throws Exception { if (node.getInternalSlice() instanceof Slice) { return Slice(node, (Slice) node.getInternalSlice()); } int value = temporary; expr_contextType ctx = node.getInternalCtx(); if (node.getInternalCtx() == expr_contextType.AugStore && augmode == expr_contextType.Store) { restoreAugTmps(node, 2); ctx = expr_contextType.Store; } else { visit(node.getInternalValue()); stackProduce(); visit(node.getInternalSlice()); stackConsume(); if (node.getInternalCtx() == expr_contextType.AugStore && augmode == expr_contextType.Load) { saveAugTmps(node, 2); ctx = expr_contextType.Load; } } switch (ctx) { case Del: code.invokevirtual(p(PyObject.class), "__delitem__", sig(Void.TYPE, PyObject.class)); return null; case Load: code.invokevirtual(p(PyObject.class), "__getitem__", sig(PyObject.class, PyObject.class)); return null; case Param: case Store: code.aload(value); code.invokevirtual(p(PyObject.class), "__setitem__", sig(Void.TYPE, PyObject.class, PyObject.class)); return null; } return null; }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitIndex(Index node) throws Exception { traverse(node); return null; }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitExtSlice(ExtSlice node) throws Exception { int dims = makeArray(node.getInternalDims()); code.new_(p(PyTuple.class)); code.dup(); code.aload(dims); code.invokespecial(p(PyTuple.class), "<init>", sig(Void.TYPE, PyObject[].class)); freeArray(dims); return null; }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitAttribute(Attribute node) throws Exception { expr_contextType ctx = node.getInternalCtx(); if (node.getInternalCtx() == expr_contextType.AugStore && augmode == expr_contextType.Store) { restoreAugTmps(node, 2); ctx = expr_contextType.Store; } else { visit(node.getInternalValue()); code.ldc(getName(node.getInternalAttr())); if (node.getInternalCtx() == expr_contextType.AugStore && augmode == expr_contextType.Load) { saveAugTmps(node, 2); ctx = expr_contextType.Load; } } switch (ctx) { case Del: code.invokevirtual(p(PyObject.class), "__delattr__", sig(Void.TYPE, String.class)); return null; case Load: code.invokevirtual(p(PyObject.class), "__getattr__", sig(PyObject.class, String.class)); return null; case Param: case Store: code.aload(temporary); code.invokevirtual(p(PyObject.class), "__setattr__", sig(Void.TYPE, String.class, PyObject.class)); return null; } return null; }
// in src/org/python/compiler/CodeCompiler.java
public Object seqSet(java.util.List<expr> nodes) throws Exception { code.aload(temporary); code.iconst(nodes.size()); code.invokestatic(p(Py.class), "unpackSequence", sig(PyObject[].class, PyObject.class, Integer.TYPE)); int tmp = code.getLocal("[org/python/core/PyObject"); code.astore(tmp); for (int i = 0; i < nodes.size(); i++) { code.aload(tmp); code.iconst(i); code.aaload(); set(nodes.get(i)); } code.freeLocal(tmp); return null; }
// in src/org/python/compiler/CodeCompiler.java
public Object seqDel(java.util.List<expr> nodes) throws Exception { for (expr e : nodes) { visit(e); } return null; }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitTuple(Tuple node) throws Exception { if (node.getInternalCtx() == expr_contextType.Store) { return seqSet(node.getInternalElts()); } if (node.getInternalCtx() == expr_contextType.Del) { return seqDel(node.getInternalElts()); } int content = makeArray(node.getInternalElts()); code.new_(p(PyTuple.class)); code.dup(); code.aload(content); code.invokespecial(p(PyTuple.class), "<init>", sig(Void.TYPE, PyObject[].class)); freeArray(content); return null; }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitList(List node) throws Exception { if (node.getInternalCtx() == expr_contextType.Store) { return seqSet(node.getInternalElts()); } if (node.getInternalCtx() == expr_contextType.Del) { return seqDel(node.getInternalElts()); } int content = makeArray(node.getInternalElts()); code.new_(p(PyList.class)); code.dup(); code.aload(content); code.invokespecial(p(PyList.class), "<init>", sig(Void.TYPE, PyObject[].class)); freeArray(content); return null; }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitListComp(ListComp node) throws Exception { code.new_(p(PyList.class)); code.dup(); code.invokespecial(p(PyList.class), "<init>", sig(Void.TYPE)); code.dup(); code.ldc("append"); code.invokevirtual(p(PyObject.class), "__getattr__", sig(PyObject.class, String.class)); String tmp_append = "_[" + node.getLine() + "_" + node.getCharPositionInLine() + "]"; set(new Name(node, tmp_append, expr_contextType.Store)); java.util.List<expr> args = new ArrayList<expr>(); args.add(node.getInternalElt()); stmt n = new Expr(node, new Call(node, new Name(node, tmp_append, expr_contextType.Load), args, new ArrayList<keyword>(), null, null)); for (int i = node.getInternalGenerators().size() - 1; i >= 0; i--) { comprehension lc = node.getInternalGenerators().get(i); for (int j = lc.getInternalIfs().size() - 1; j >= 0; j--) { java.util.List<stmt> body = new ArrayList<stmt>(); body.add(n); n = new If(lc.getInternalIfs().get(j), lc.getInternalIfs().get(j), body, new ArrayList<stmt>()); } java.util.List<stmt> body = new ArrayList<stmt>(); body.add(n); n = new For(lc, lc.getInternalTarget(), lc.getInternalIter(), body, new ArrayList<stmt>()); } visit(n); java.util.List<expr> targets = new ArrayList<expr>(); targets.add(new Name(n, tmp_append, expr_contextType.Del)); visit(new Delete(n, targets)); return null; }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitDict(Dict node) throws Exception { java.util.List<PythonTree> elts = new ArrayList<PythonTree>(); for (int i = 0; i < node.getInternalKeys().size(); i++) { elts.add(node.getInternalKeys().get(i)); elts.add(node.getInternalValues().get(i)); } int content = makeArray(elts); code.new_(p(PyDictionary.class)); code.dup(); code.aload(content); code.invokespecial(p(PyDictionary.class), "<init>", sig(Void.TYPE, PyObject[].class)); freeArray(content); return null; }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitRepr(Repr node) throws Exception { visit(node.getInternalValue()); code.invokevirtual(p(PyObject.class), "__repr__", sig(PyString.class)); return null; }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitLambda(Lambda node) throws Exception { String name = "<lambda>"; //Add a return node onto the outside of suite; java.util.List<stmt> bod = new ArrayList<stmt>(); bod.add(new Return(node, node.getInternalBody())); mod retSuite = new Suite(node, bod); setline(node); ScopeInfo scope = module.getScopeInfo(node); int defaultsArray = makeArray(scope.ac.getDefaults()); code.new_(p(PyFunction.class)); code.dup(); code.aload(defaultsArray); code.freeLocal(defaultsArray); loadFrame(); code.getfield(p(PyFrame.class), "f_globals", ci(PyObject.class)); code.swap(); scope.setup_closure(); scope.dump(); module.codeConstant(retSuite, name, true, className, false, false, node.getLine(), scope, cflags).get(code); if (!makeClosure(scope)) { code.invokespecial(p(PyFunction.class), "<init>", sig(Void.TYPE, PyObject.class, PyObject[].class, PyCode.class)); } else { code.invokespecial(p(PyFunction.class), "<init>", sig(Void.TYPE, PyObject.class, PyObject[].class, PyCode.class, PyObject[].class)); } return null; }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitEllipsis(Ellipsis node) throws Exception { code.getstatic(p(Py.class), "Ellipsis", ci(PyObject.class)); return null; }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitSlice(Slice node) throws Exception { if (node.getInternalLower() == null) { getNone(); } else { visit(node.getInternalLower()); } stackProduce(); if (node.getInternalUpper() == null) { getNone(); } else { visit(node.getInternalUpper()); } stackProduce(); if (node.getInternalStep() == null) { getNone(); } else { visit(node.getInternalStep()); } int step = storeTop(); stackConsume(2); code.new_(p(PySlice.class)); code.dup(); code.dup2_x2(); code.pop2(); code.aload(step); code.freeLocal(step); code.invokespecial(p(PySlice.class), "<init>", sig(Void.TYPE, PyObject.class, PyObject.class, PyObject.class)); return null; }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitClassDef(ClassDef node) throws Exception { setline(node); int baseArray = makeArray(node.getInternalBases()); //Get class name String name = getName(node.getInternalName()); code.ldc(name); code.aload(baseArray); ScopeInfo scope = module.getScopeInfo(node); scope.setup_closure(); scope.dump(); //Make code object out of suite module.codeConstant(new Suite(node, node.getInternalBody()), name, false, name, getDocStr(node.getInternalBody()), true, false, node.getLine(), scope, cflags).get(code); //Make class out of name, bases, and code if (!makeClosure(scope)) { code.invokestatic(p(Py.class), "makeClass", sig(PyObject.class, String.class, PyObject[].class, PyCode.class)); } else { code.invokestatic(p(Py.class), "makeClass", sig(PyObject.class, String.class, PyObject[].class, PyCode.class, PyObject[].class)); } applyDecorators(node.getInternalDecorator_list()); //Assign this new class to the given name set(new Name(node, node.getInternalName(), expr_contextType.Store)); freeArray(baseArray); return null; }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitNum(Num node) throws Exception { if (node.getInternalN() instanceof PyInteger) { module.integerConstant(((PyInteger) node.getInternalN()).getValue()).get(code); } else if (node.getInternalN() instanceof PyLong) { module.longConstant(((PyObject) node.getInternalN()).__str__().toString()).get(code); } else if (node.getInternalN() instanceof PyFloat) { module.floatConstant(((PyFloat) node.getInternalN()).getValue()).get(code); } else if (node.getInternalN() instanceof PyComplex) { module.complexConstant(((PyComplex) node.getInternalN()).imag).get(code); } return null; }
// in src/org/python/compiler/CodeCompiler.java
void emitGetGlobal(String name) throws Exception { code.ldc(name); code.invokevirtual(p(PyFrame.class), "getglobal", sig(PyObject.class, String.class)); }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitName(Name node) throws Exception { String name; if (fast_locals) { name = node.getInternalId(); } else { name = getName(node.getInternalId()); } SymInfo syminf = tbl.get(name); expr_contextType ctx = node.getInternalCtx(); if (ctx == expr_contextType.AugStore) { ctx = augmode; } switch (ctx) { case Load: loadFrame(); if (syminf != null) { int flags = syminf.flags; if ((flags & ScopeInfo.GLOBAL) != 0 || optimizeGlobals && (flags & (ScopeInfo.BOUND | ScopeInfo.CELL | ScopeInfo.FREE)) == 0) { emitGetGlobal(name); return null; } if (fast_locals) { if ((flags & ScopeInfo.CELL) != 0) { code.iconst(syminf.env_index); code.invokevirtual(p(PyFrame.class), "getderef", sig(PyObject.class, Integer.TYPE)); return null; } if ((flags & ScopeInfo.BOUND) != 0) { code.iconst(syminf.locals_index); code.invokevirtual(p(PyFrame.class), "getlocal", sig(PyObject.class, Integer.TYPE)); return null; } } if ((flags & ScopeInfo.FREE) != 0 && (flags & ScopeInfo.BOUND) == 0) { code.iconst(syminf.env_index); code.invokevirtual(p(PyFrame.class), "getderef", sig(PyObject.class, Integer.TYPE)); return null; } } code.ldc(name); code.invokevirtual(p(PyFrame.class), "getname", sig(PyObject.class, String.class)); return null; case Param: case Store: loadFrame(); if (syminf != null && (syminf.flags & ScopeInfo.GLOBAL) != 0) { code.ldc(name); code.aload(temporary); code.invokevirtual(p(PyFrame.class), "setglobal", sig(Void.TYPE, String.class, PyObject.class)); } else { if (!fast_locals) { code.ldc(name); code.aload(temporary); code.invokevirtual(p(PyFrame.class), "setlocal", sig(Void.TYPE, String.class, PyObject.class)); } else { if (syminf == null) { throw new ParseException("internal compiler error", node); } if ((syminf.flags & ScopeInfo.CELL) != 0) { code.iconst(syminf.env_index); code.aload(temporary); code.invokevirtual(p(PyFrame.class), "setderef", sig(Void.TYPE, Integer.TYPE, PyObject.class)); } else { code.iconst(syminf.locals_index); code.aload(temporary); code.invokevirtual(p(PyFrame.class), "setlocal", sig(Void.TYPE, Integer.TYPE, PyObject.class)); } } } return null; case Del: { loadFrame(); if (syminf != null && (syminf.flags & ScopeInfo.GLOBAL) != 0) { code.ldc(name); code.invokevirtual(p(PyFrame.class), "delglobal", sig(Void.TYPE, String.class)); } else { if (!fast_locals) { code.ldc(name); code.invokevirtual(p(PyFrame.class), "dellocal", sig(Void.TYPE, String.class)); } else { if (syminf == null) { throw new ParseException("internal compiler error", node); } if ((syminf.flags & ScopeInfo.CELL) != 0) { module.error("can not delete variable '" + name + "' referenced in nested scope", true, node); } code.iconst(syminf.locals_index); code.invokevirtual(p(PyFrame.class), "dellocal", sig(Void.TYPE, Integer.TYPE)); } } return null; } } return null; }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitStr(Str node) throws Exception { PyString s = (PyString) node.getInternalS(); if (s instanceof PyUnicode) { module.unicodeConstant(s.asString()).get(code); } else { module.stringConstant(s.asString()).get(code); } return null; }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitGeneratorExp(GeneratorExp node) throws Exception { String bound_exp = "_(x)"; setline(node); code.new_(p(PyFunction.class)); code.dup(); loadFrame(); code.getfield(p(PyFrame.class), "f_globals", ci(PyObject.class)); ScopeInfo scope = module.getScopeInfo(node); int emptyArray = makeArray(new ArrayList<expr>()); code.aload(emptyArray); scope.setup_closure(); scope.dump(); stmt n = new Expr(node, new Yield(node, node.getInternalElt())); expr iter = null; for (int i = node.getInternalGenerators().size() - 1; i >= 0; i--) { comprehension comp = node.getInternalGenerators().get(i); for (int j = comp.getInternalIfs().size() - 1; j >= 0; j--) { java.util.List<stmt> bod = new ArrayList<stmt>(); bod.add(n); n = new If(comp.getInternalIfs().get(j), comp.getInternalIfs().get(j), bod, new ArrayList<stmt>()); } java.util.List<stmt> bod = new ArrayList<stmt>(); bod.add(n); if (i != 0) { n = new For(comp, comp.getInternalTarget(), comp.getInternalIter(), bod, new ArrayList<stmt>()); } else { n = new For(comp, comp.getInternalTarget(), new Name(node, bound_exp, expr_contextType.Load), bod, new ArrayList<stmt>()); iter = comp.getInternalIter(); } } java.util.List<stmt> bod = new ArrayList<stmt>(); bod.add(n); module.codeConstant(new Suite(node, bod), "<genexpr>", true, className, false, false, node.getLine(), scope, cflags).get(code); code.aconst_null(); if (!makeClosure(scope)) { code.invokespecial(p(PyFunction.class), "<init>", sig(Void.TYPE, PyObject.class, PyObject[].class, PyCode.class, PyObject.class)); } else { code.invokespecial(p(PyFunction.class), "<init>", sig(Void.TYPE, PyObject.class, PyObject[].class, PyCode.class, PyObject.class, PyObject[].class)); } int genExp = storeTop(); visit(iter); code.aload(genExp); code.freeLocal(genExp); code.swap(); code.invokevirtual(p(PyObject.class), "__iter__", sig(PyObject.class)); loadThreadState(); code.swap(); code.invokevirtual(p(PyObject.class), "__call__", sig(PyObject.class, ThreadState.class, PyObject.class)); freeArray(emptyArray); return null; }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitWith(With node) throws Exception { if (!module.getFutures().withStatementSupported()) { throw new ParseException("'with' will become a reserved keyword in Python 2.6", node); } final Label label_body_start = new Label(); final Label label_body_end = new Label(); final Label label_catch = new Label(); final Label label_end = new Label(); final Method contextGuard_getManager = Method.getMethod( "org.python.core.ContextManager getManager (org.python.core.PyObject)"); final Method __enter__ = Method.getMethod( "org.python.core.PyObject __enter__ (org.python.core.ThreadState)"); final Method __exit__ = Method.getMethod( "boolean __exit__ (org.python.core.ThreadState,org.python.core.PyException)"); // mgr = (EXPR) visit(node.getInternalContext_expr()); // wrap the manager with the ContextGuard (or get it directly if it // supports the ContextManager interface) code.invokestatic(Type.getType(ContextGuard.class).getInternalName(), contextGuard_getManager.getName(), contextGuard_getManager.getDescriptor()); code.dup(); final int mgr_tmp = code.getLocal(Type.getType(ContextManager.class).getInternalName()); code.astore(mgr_tmp); // value = mgr.__enter__() loadThreadState(); code.invokeinterface(Type.getType(ContextManager.class).getInternalName(), __enter__.getName(), __enter__.getDescriptor()); int value_tmp = code.getLocal(p(PyObject.class)); code.astore(value_tmp); // exc = True # not necessary, since we don't exec finally if exception // FINALLY (preparation) // ordinarily with a finally, we need to duplicate the code. that's not the case // here // # The normal and non-local-goto cases are handled here // if exc: # implicit // exit(None, None, None) ExceptionHandler normalExit = new ExceptionHandler() { @Override public boolean isFinallyHandler() { return true; } @Override public void finalBody(CodeCompiler compiler) throws Exception { compiler.code.aload(mgr_tmp); loadThreadState(); compiler.code.aconst_null(); compiler.code.invokeinterface(Type.getType(ContextManager.class).getInternalName(), __exit__.getName(), __exit__.getDescriptor()); compiler.code.pop(); } }; exceptionHandlers.push(normalExit); // try-catch block here ExceptionHandler handler = new ExceptionHandler(); exceptionHandlers.push(handler); handler.exceptionStarts.addElement(label_body_start); // VAR = value # Only if "as VAR" is present code.label(label_body_start); if (node.getInternalOptional_vars() != null) { set(node.getInternalOptional_vars(), value_tmp); } code.freeLocal(value_tmp); // BLOCK + FINALLY if non-local-goto Object blockResult = suite(node.getInternalBody()); normalExit.bodyDone = true; exceptionHandlers.pop(); exceptionHandlers.pop(); code.label(label_body_end); handler.exceptionEnds.addElement(label_body_end); // FINALLY if *not* non-local-goto if (blockResult == NoExit) { // BLOCK would have generated FINALLY for us if it exited (due to a break, // continue or return) inlineFinally(normalExit); code.goto_(label_end); } // CATCH code.label(label_catch); loadFrame(); code.invokestatic(p(Py.class), "setException", sig(PyException.class, Throwable.class, PyFrame.class)); code.aload(mgr_tmp); code.swap(); loadThreadState(); code.swap(); code.invokeinterface(Type.getType(ContextManager.class).getInternalName(), __exit__.getName(), __exit__.getDescriptor()); // # The exceptional case is handled here // exc = False # implicit // if not exit(*sys.exc_info()): code.ifne(label_end); // raise // # The exception is swallowed if exit() returns true code.invokestatic(p(Py.class), "makeException", sig(PyException.class)); code.checkcast(p(Throwable.class)); code.athrow(); code.label(label_end); code.freeLocal(mgr_tmp); handler.addExceptionHandlers(label_catch); return null; }
// in src/org/python/compiler/CodeCompiler.java
Override public void finalBody(CodeCompiler compiler) throws Exception { compiler.code.aload(mgr_tmp); loadThreadState(); compiler.code.aconst_null(); compiler.code.invokeinterface(Type.getType(ContextManager.class).getInternalName(), __exit__.getName(), __exit__.getDescriptor()); compiler.code.pop(); }
// in src/org/python/compiler/CodeCompiler.java
Override protected Object unhandled_node(PythonTree node) throws Exception { throw new Exception("Unhandled node " + node); }
// in src/org/python/compiler/CodeCompiler.java
public void addExceptionHandlers(Label handlerStart) throws Exception { for (int i = 0; i < exceptionStarts.size(); ++i) { Label start = exceptionStarts.elementAt(i); Label end = exceptionEnds.elementAt(i); //FIXME: not at all sure that getOffset() test is correct or necessary. if (start.getOffset() != end.getOffset()) { code.trycatch( exceptionStarts.elementAt(i), exceptionEnds.elementAt(i), handlerStart, p(Throwable.class)); } } }
// in src/org/python/compiler/CodeCompiler.java
public void finalBody(CodeCompiler compiler) throws Exception { if (node instanceof TryFinally) { suite(((TryFinally) node).getInternalFinalbody()); } }
// in src/org/python/compiler/JavaMaker.java
Override public void addConstructor(String name, Class<?>[] parameters, Class<?> ret, String sig, int access) throws Exception { /* Need a fancy constructor for the Java side of things */ Code code = classfile.addMethod("<init>", sig, access); callSuper(code, "<init>", name, parameters, null, sig); code.visitVarInsn(ALOAD, 0); getArgs(code, parameters); code.visitMethodInsn(INVOKEVIRTUAL, classfile.name, "__initProxy__", makeSig("V", $objArr)); code.visitInsn(RETURN); }
// in src/org/python/compiler/JavaMaker.java
Override public void addProxy() throws Exception { if (methods != null) super.addProxy(); // _initProxy method Code code = classfile.addMethod("__initProxy__", makeSig("V", $objArr), Modifier.PUBLIC); code.visitVarInsn(ALOAD, 0); code.visitLdcInsn(pythonModule); code.visitLdcInsn(pythonClass); code.visitVarInsn(ALOAD, 1); code.visitMethodInsn(INVOKESTATIC, "org/python/core/Py", "initProxy", makeSig("V", $pyProxy, $str, $str, $objArr)); code.visitInsn(RETURN); }
// in src/org/python/compiler/JavaMaker.java
Override public void addMethod(Method method, int access) throws Exception { if (Modifier.isAbstract(access)) { // Maybe throw an exception here??? super.addMethod(method, access); } else if (methods.__finditem__(method.getName().intern()) != null) { super.addMethod(method, access); } else if (Modifier.isProtected(method.getModifiers())) { addSuperMethod(method, access); } }
// in src/org/python/compiler/Module.java
PyCodeConstant codeConstant(mod tree, String name, boolean fast_locals, String className, boolean classBody, boolean printResults, int firstlineno, ScopeInfo scope, CompilerFlags cflags) throws Exception { return codeConstant(tree, name, fast_locals, className, null, classBody, printResults, firstlineno, scope, cflags); }
// in src/org/python/compiler/Module.java
PyCodeConstant codeConstant(mod tree, String name, boolean fast_locals, String className, Str classDoc, boolean classBody, boolean printResults, int firstlineno, ScopeInfo scope, CompilerFlags cflags) throws Exception { PyCodeConstant code = new PyCodeConstant(tree, name, fast_locals, className, classBody, printResults, firstlineno, scope, cflags, this); codes.add(code); CodeCompiler compiler = new CodeCompiler(this, printResults); Code c = classfile.addMethod( code.fname, sig(PyObject.class, PyFrame.class, ThreadState.class), ACC_PUBLIC); compiler.parse(tree, c, fast_locals, className, classDoc, classBody, scope, cflags); return code; }
// in src/org/python/compiler/Module.java
public void error(String msg, boolean err, PythonTree node) throws Exception { if (!err) { try { Py.warning(Py.SyntaxWarning, msg, (sfilename != null) ? sfilename : "?", node.getLine(), null, Py.None); return; } catch (PyException e) { if (!e.match(Py.SyntaxWarning)) { throw e; } } } throw new ParseException(msg, node); }
// in src/org/python/compiler/Module.java
public static void compile(mod node, OutputStream ostream, String name, String filename, boolean linenumbers, boolean printResults, CompilerFlags cflags) throws Exception { compile(node, ostream, name, filename, linenumbers, printResults, cflags, org.python.core.imp.NO_MTIME); }
// in src/org/python/compiler/Module.java
public static void compile(mod node, OutputStream ostream, String name, String filename, boolean linenumbers, boolean printResults, CompilerFlags cflags, long mtime) throws Exception { Module module = new Module(name, filename, linenumbers, mtime); if (cflags == null) { cflags = new CompilerFlags(); } module.futures.preprocessFutures(node, cflags); new ScopesCompiler(module, module.scopes).parse(node); //Add __doc__ if it exists Constant main = module.codeConstant(node, "<module>", false, null, false, printResults, 0, module.getScopeInfo(node), cflags); module.mainCode = main; module.write(ostream); }
// in src/org/python/compiler/LegacyCompiler.java
public PyCode loadCode() throws Exception { return BytecodeLoader.makeCode(name, ostream().toByteArray(), filename); }
// in src/org/python/compiler/LegacyCompiler.java
public void writeTo(OutputStream stream) throws Exception { if (this.ostream != null) { stream.write(ostream.toByteArray()); } else { Module.compile(node, stream, name, filename, linenumbers, printResults, cflags); } }
// in src/org/python/compiler/LegacyCompiler.java
public void saveCode(String directory) throws Exception { // FIXME: this is slightly broken, it should use the directory Py.saveClassFile(name, ostream()); }
// in src/org/python/compiler/LegacyCompiler.java
private ByteArrayOutputStream ostream() throws Exception { if (ostream == null) { ostream = new ByteArrayOutputStream(); Module.compile(node, ostream, name, filename, linenumbers, printResults, cflags); } return ostream; }
// in src/org/python/compiler/ArgListCompiler.java
public void visitArgs(arguments args) throws Exception { for (int i = 0; i < args.getInternalArgs().size(); i++) { String name = (String) visit(args.getInternalArgs().get(i)); names.add(name); if (args.getInternalArgs().get(i) instanceof Tuple) { List<expr> targets = new ArrayList<expr>(); targets.add(args.getInternalArgs().get(i)); Assign ass = new Assign(args.getInternalArgs().get(i), targets, new Name(args.getInternalArgs().get(i), name, expr_contextType.Load)); init_code.add(ass); } } if (args.getInternalVararg() != null) { arglist = true; names.add(args.getInternalVararg()); } if (args.getInternalKwarg() != null) { keywordlist = true; names.add(args.getInternalKwarg()); } defaults = args.getInternalDefaults(); for (int i = 0; i < defaults.size(); i++) { if (defaults.get(i) == null) throw new ParseException( "non-default argument follows default argument", args.getInternalArgs().get(args.getInternalArgs().size() - defaults.size() + i)); } }
// in src/org/python/compiler/ArgListCompiler.java
Override public Object visitName(Name node) throws Exception { //FIXME: do we need Store and Param, or just Param? if (node.getInternalCtx() != expr_contextType.Store && node.getInternalCtx() != expr_contextType.Param) { return null; } if (fpnames.contains(node.getInternalId())) { throw new ParseException("duplicate argument name found: " + node.getInternalId(), node); } fpnames.add(node.getInternalId()); return node.getInternalId(); }
// in src/org/python/compiler/ArgListCompiler.java
Override public Object visitTuple(Tuple node) throws Exception { StringBuffer name = new StringBuffer("("); int n = node.getInternalElts().size(); for (int i = 0; i < n-1; i++) { name.append(visit(node.getInternalElts().get(i))); name.append(", "); } name.append(visit(node.getInternalElts().get(n - 1))); name.append(")"); return name.toString(); }
// in src/org/python/compiler/ScopesCompiler.java
public void endScope() throws Exception { if (cur.kind == FUNCSCOPE) { func_level--; } level--; ScopeInfo up = null; if (!scopes.empty()) { up = scopes.pop(); } //Go into the stack to find a non class containing scope to use making the closure //See PEP 227 int dist = 1; ScopeInfo referenceable = up; for (int i = scopes.size() - 1; i >= 0 && referenceable.kind == CLASSSCOPE; i--, dist++) { referenceable = (scopes.get(i)); } cur.cook(referenceable, dist, code_compiler); cur.dump(); // debug cur = up; }
// in src/org/python/compiler/ScopesCompiler.java
public void parse(PythonTree node) throws Exception { try { visit(node); } catch (Throwable t) { throw ParserFacade.fixParseError(null, t, code_compiler.getFilename()); } }
// in src/org/python/compiler/ScopesCompiler.java
Override public Object visitInteractive(Interactive node) throws Exception { beginScope("<single-top>", TOPSCOPE, node, null); suite(node.getInternalBody()); endScope(); return null; }
// in src/org/python/compiler/ScopesCompiler.java
Override public Object visitModule(org.python.antlr.ast.Module node) throws Exception { beginScope("<file-top>", TOPSCOPE, node, null); suite(node.getInternalBody()); endScope(); return null; }
// in src/org/python/compiler/ScopesCompiler.java
Override public Object visitExpression(Expression node) throws Exception { beginScope("<eval-top>", TOPSCOPE, node, null); visit(new Return(node,node.getInternalBody())); endScope(); return null; }
// in src/org/python/compiler/ScopesCompiler.java
Override public Object visitFunctionDef(FunctionDef node) throws Exception { def(node.getInternalName()); ArgListCompiler ac = new ArgListCompiler(); ac.visitArgs(node.getInternalArgs()); List<expr> defaults = ac.getDefaults(); for (int i = 0; i < defaults.size(); i++) { visit(defaults.get(i)); } List<expr> decs = node.getInternalDecorator_list(); for (int i = decs.size() - 1; i >= 0; i--) { visit(decs.get(i)); } beginScope(node.getInternalName(), FUNCSCOPE, node, ac); int n = ac.names.size(); for (int i = 0; i < n; i++) { cur.addParam(ac.names.get(i)); } for (int i = 0; i < ac.init_code.size(); i++) { visit(ac.init_code.get(i)); } cur.markFromParam(); suite(node.getInternalBody()); endScope(); return null; }
// in src/org/python/compiler/ScopesCompiler.java
Override public Object visitLambda(Lambda node) throws Exception { ArgListCompiler ac = new ArgListCompiler(); ac.visitArgs(node.getInternalArgs()); List<? extends PythonTree> defaults = ac.getDefaults(); for (int i = 0; i < defaults.size(); i++) { visit(defaults.get(i)); } beginScope("<lambda>", FUNCSCOPE, node, ac); for (Object o : ac.names) { cur.addParam((String) o); } for (Object o : ac.init_code) { visit((stmt) o); } cur.markFromParam(); visit(node.getInternalBody()); endScope(); return null; }
// in src/org/python/compiler/ScopesCompiler.java
public void suite(List<stmt> stmts) throws Exception { for (int i = 0; i < stmts.size(); i++) visit(stmts.get(i)); }
// in src/org/python/compiler/ScopesCompiler.java
Override public Object visitImport(Import node) throws Exception { for (int i = 0; i < node.getInternalNames().size(); i++) { if (node.getInternalNames().get(i).getInternalAsname() != null) { cur.addBound(node.getInternalNames().get(i).getInternalAsname()); } else { String name = node.getInternalNames().get(i).getInternalName(); if (name.indexOf('.') > 0) { name = name.substring(0, name.indexOf('.')); } cur.addBound(name); } } return null; }
// in src/org/python/compiler/ScopesCompiler.java
Override public Object visitImportFrom(ImportFrom node) throws Exception { Future.checkFromFuture(node); // future stmt support int n = node.getInternalNames().size(); if (n == 0) { cur.from_import_star = true; return null; } for (int i = 0; i < n; i++) { if (node.getInternalNames().get(i).getInternalAsname() != null) { cur.addBound(node.getInternalNames().get(i).getInternalAsname()); } else { cur.addBound(node.getInternalNames().get(i).getInternalName()); } } return null; }
// in src/org/python/compiler/ScopesCompiler.java
Override public Object visitGlobal(Global node) throws Exception { int n = node.getInternalNames().size(); for (int i = 0; i < n; i++) { String name = node.getInternalNames().get(i); int prev = cur.addGlobal(name); if (prev >= 0) { if ((prev & FROM_PARAM) != 0) { code_compiler.error("name '" + name + "' is local and global", true, node); } if ((prev & GLOBAL) != 0) { continue; } String what; if ((prev & BOUND) != 0) { what = "assignment"; } else { what = "use"; } code_compiler.error("name '" + name + "' declared global after " + what, false, node); } } return null; }
// in src/org/python/compiler/ScopesCompiler.java
Override public Object visitExec(Exec node) throws Exception { cur.exec = true; if (node.getInternalGlobals() == null && node.getInternalLocals() == null) { cur.unqual_exec = true; } traverse(node); return null; }
// in src/org/python/compiler/ScopesCompiler.java
Override public Object visitClassDef(ClassDef node) throws Exception { def(node.getInternalName()); int n = node.getInternalBases().size(); for (int i = 0; i < n; i++) { visit(node.getInternalBases().get(i)); } beginScope(node.getInternalName(), CLASSSCOPE, node, null); suite(node.getInternalBody()); endScope(); return null; }
// in src/org/python/compiler/ScopesCompiler.java
Override public Object visitName(Name node) throws Exception { String name = node.getInternalId(); if (node.getInternalCtx() != expr_contextType.Load) { if (name.equals("__debug__")) { code_compiler.error("can not assign to __debug__", true, node); } cur.addBound(name); } else { cur.addUsed(name); } return null; }
// in src/org/python/compiler/ScopesCompiler.java
Override public Object visitListComp(ListComp node) throws Exception { String tmp = "_[" + node.getLine() + "_" + node.getCharPositionInLine() + "]"; cur.addBound(tmp); traverse(node); return null; }
// in src/org/python/compiler/ScopesCompiler.java
Override public Object visitYield(Yield node) throws Exception { cur.defineAsGenerator(node); cur.yield_count++; traverse(node); return null; }
// in src/org/python/compiler/ScopesCompiler.java
Override public Object visitReturn(Return node) throws Exception { if (node.getInternalValue() != null) { cur.noteReturnValue(node); } traverse(node); return null; }
// in src/org/python/compiler/ScopesCompiler.java
Override public Object visitGeneratorExp(GeneratorExp node) throws Exception { // The first iterator is evaluated in the outer scope if (node.getInternalGenerators() != null && node.getInternalGenerators().size() > 0) { visit(node.getInternalGenerators().get(0).getInternalIter()); } String bound_exp = "_(x)"; String tmp = "_(" + node.getLine() + "_" + node.getCharPositionInLine() + ")"; def(tmp); ArgListCompiler ac = new ArgListCompiler(); List<expr> args = new ArrayList<expr>(); args.add(new Name(node.getToken(), bound_exp, expr_contextType.Param)); ac.visitArgs(new arguments(node, args, null, null, new ArrayList<expr>())); beginScope(tmp, FUNCSCOPE, node, ac); cur.addParam(bound_exp); cur.markFromParam(); cur.defineAsGenerator(node); cur.yield_count++; // The reset of the iterators are evaluated in the inner scope if (node.getInternalElt() != null) { visit(node.getInternalElt()); } if (node.getInternalGenerators() != null) { for (int i = 0; i < node.getInternalGenerators().size(); i++) { if (node.getInternalGenerators().get(i) != null) { if (i == 0) { visit(node.getInternalGenerators().get(i).getInternalTarget()); if (node.getInternalGenerators().get(i).getInternalIfs() != null) { for (expr cond : node.getInternalGenerators().get(i).getInternalIfs()) { if (cond != null) { visit(cond); } } } } else { visit(node.getInternalGenerators().get(i)); } } } } endScope(); return null; }
// in src/org/python/compiler/ScopesCompiler.java
Override public Object visitWith(With node) throws Exception { cur.max_with_count++; traverse(node); return null; }
// in src/org/python/antlr/PythonTree.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { throw new RuntimeException("Unexpected node: " + this); }
// in src/org/python/antlr/PythonTree.java
public void traverse(VisitorIF<?> visitor) throws Exception { throw new RuntimeException("Cannot traverse node: " + this); }
// in src/org/python/antlr/ast/ClassDef.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { return visitor.visitClassDef(this); }
// in src/org/python/antlr/ast/ClassDef.java
public void traverse(VisitorIF<?> visitor) throws Exception { if (bases != null) { for (PythonTree t : bases) { if (t != null) t.accept(visitor); } } if (body != null) { for (PythonTree t : body) { if (t != null) t.accept(visitor); } } if (decorator_list != null) { for (PythonTree t : decorator_list) { if (t != null) t.accept(visitor); } } }
// in src/org/python/antlr/ast/Ellipsis.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { return visitor.visitEllipsis(this); }
// in src/org/python/antlr/ast/Ellipsis.java
public void traverse(VisitorIF<?> visitor) throws Exception { }
// in src/org/python/antlr/ast/ExtSlice.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { return visitor.visitExtSlice(this); }
// in src/org/python/antlr/ast/ExtSlice.java
public void traverse(VisitorIF<?> visitor) throws Exception { if (dims != null) { for (PythonTree t : dims) { if (t != null) t.accept(visitor); } } }
// in src/org/python/antlr/ast/Dict.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { return visitor.visitDict(this); }
// in src/org/python/antlr/ast/Dict.java
public void traverse(VisitorIF<?> visitor) throws Exception { if (keys != null) { for (PythonTree t : keys) { if (t != null) t.accept(visitor); } } if (values != null) { for (PythonTree t : values) { if (t != null) t.accept(visitor); } } }
// in src/org/python/antlr/ast/Assign.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { return visitor.visitAssign(this); }
// in src/org/python/antlr/ast/Assign.java
public void traverse(VisitorIF<?> visitor) throws Exception { if (targets != null) { for (PythonTree t : targets) { if (t != null) t.accept(visitor); } } if (value != null) value.accept(visitor); }
// in src/org/python/antlr/ast/Name.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { return visitor.visitName(this); }
// in src/org/python/antlr/ast/Name.java
public void traverse(VisitorIF<?> visitor) throws Exception { }
// in src/org/python/antlr/ast/UnaryOp.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { return visitor.visitUnaryOp(this); }
// in src/org/python/antlr/ast/UnaryOp.java
public void traverse(VisitorIF<?> visitor) throws Exception { if (operand != null) operand.accept(visitor); }
// in src/org/python/antlr/ast/Expr.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { return visitor.visitExpr(this); }
// in src/org/python/antlr/ast/Expr.java
public void traverse(VisitorIF<?> visitor) throws Exception { if (value != null) value.accept(visitor); }
// in src/org/python/antlr/ast/ImportFrom.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { return visitor.visitImportFrom(this); }
// in src/org/python/antlr/ast/ImportFrom.java
public void traverse(VisitorIF<?> visitor) throws Exception { if (names != null) { for (PythonTree t : names) { if (t != null) t.accept(visitor); } } }
// in src/org/python/antlr/ast/Subscript.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { return visitor.visitSubscript(this); }
// in src/org/python/antlr/ast/Subscript.java
public void traverse(VisitorIF<?> visitor) throws Exception { if (value != null) value.accept(visitor); if (slice != null) slice.accept(visitor); }
// in src/org/python/antlr/ast/FunctionDef.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { return visitor.visitFunctionDef(this); }
// in src/org/python/antlr/ast/FunctionDef.java
public void traverse(VisitorIF<?> visitor) throws Exception { if (args != null) args.accept(visitor); if (body != null) { for (PythonTree t : body) { if (t != null) t.accept(visitor); } } if (decorator_list != null) { for (PythonTree t : decorator_list) { if (t != null) t.accept(visitor); } } }
// in src/org/python/antlr/ast/Import.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { return visitor.visitImport(this); }
// in src/org/python/antlr/ast/Import.java
public void traverse(VisitorIF<?> visitor) throws Exception { if (names != null) { for (PythonTree t : names) { if (t != null) t.accept(visitor); } } }
// in src/org/python/antlr/ast/keyword.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { traverse(visitor); return null; }
// in src/org/python/antlr/ast/keyword.java
public void traverse(VisitorIF<?> visitor) throws Exception { if (value != null) value.accept(visitor); }
// in src/org/python/antlr/ast/Pass.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { return visitor.visitPass(this); }
// in src/org/python/antlr/ast/Pass.java
public void traverse(VisitorIF<?> visitor) throws Exception { }
// in src/org/python/antlr/ast/Num.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { return visitor.visitNum(this); }
// in src/org/python/antlr/ast/Num.java
public void traverse(VisitorIF<?> visitor) throws Exception { }
// in src/org/python/antlr/ast/List.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { return visitor.visitList(this); }
// in src/org/python/antlr/ast/List.java
public void traverse(VisitorIF<?> visitor) throws Exception { if (elts != null) { for (PythonTree t : elts) { if (t != null) t.accept(visitor); } } }
// in src/org/python/antlr/ast/comprehension.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { traverse(visitor); return null; }
// in src/org/python/antlr/ast/comprehension.java
public void traverse(VisitorIF<?> visitor) throws Exception { if (target != null) target.accept(visitor); if (iter != null) iter.accept(visitor); if (ifs != null) { for (PythonTree t : ifs) { if (t != null) t.accept(visitor); } } }
// in src/org/python/antlr/ast/ErrorSlice.java
public void traverse(VisitorIF visitor) throws Exception { //no op. }
// in src/org/python/antlr/ast/Break.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { return visitor.visitBreak(this); }
// in src/org/python/antlr/ast/Break.java
public void traverse(VisitorIF<?> visitor) throws Exception { }
// in src/org/python/antlr/ast/Compare.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { return visitor.visitCompare(this); }
// in src/org/python/antlr/ast/Compare.java
public void traverse(VisitorIF<?> visitor) throws Exception { if (left != null) left.accept(visitor); if (comparators != null) { for (PythonTree t : comparators) { if (t != null) t.accept(visitor); } } }
// in src/org/python/antlr/ast/Return.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { return visitor.visitReturn(this); }
// in src/org/python/antlr/ast/Return.java
public void traverse(VisitorIF<?> visitor) throws Exception { if (value != null) value.accept(visitor); }
// in src/org/python/antlr/ast/While.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { return visitor.visitWhile(this); }
// in src/org/python/antlr/ast/While.java
public void traverse(VisitorIF<?> visitor) throws Exception { if (test != null) test.accept(visitor); if (body != null) { for (PythonTree t : body) { if (t != null) t.accept(visitor); } } if (orelse != null) { for (PythonTree t : orelse) { if (t != null) t.accept(visitor); } } }
// in src/org/python/antlr/ast/ListComp.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { return visitor.visitListComp(this); }
// in src/org/python/antlr/ast/ListComp.java
public void traverse(VisitorIF<?> visitor) throws Exception { if (elt != null) elt.accept(visitor); if (generators != null) { for (PythonTree t : generators) { if (t != null) t.accept(visitor); } } }
// in src/org/python/antlr/ast/Yield.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { return visitor.visitYield(this); }
// in src/org/python/antlr/ast/Yield.java
public void traverse(VisitorIF<?> visitor) throws Exception { if (value != null) value.accept(visitor); }
// in src/org/python/antlr/ast/arguments.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { traverse(visitor); return null; }
// in src/org/python/antlr/ast/arguments.java
public void traverse(VisitorIF<?> visitor) throws Exception { if (args != null) { for (PythonTree t : args) { if (t != null) t.accept(visitor); } } if (defaults != null) { for (PythonTree t : defaults) { if (t != null) t.accept(visitor); } } }
// in src/org/python/antlr/ast/alias.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { traverse(visitor); return null; }
// in src/org/python/antlr/ast/alias.java
public void traverse(VisitorIF<?> visitor) throws Exception { }
// in src/org/python/antlr/ast/Delete.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { return visitor.visitDelete(this); }
// in src/org/python/antlr/ast/Delete.java
public void traverse(VisitorIF<?> visitor) throws Exception { if (targets != null) { for (PythonTree t : targets) { if (t != null) t.accept(visitor); } } }
// in src/org/python/antlr/ast/Interactive.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { return visitor.visitInteractive(this); }
// in src/org/python/antlr/ast/Interactive.java
public void traverse(VisitorIF<?> visitor) throws Exception { if (body != null) { for (PythonTree t : body) { if (t != null) t.accept(visitor); } } }
// in src/org/python/antlr/ast/Module.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { return visitor.visitModule(this); }
// in src/org/python/antlr/ast/Module.java
public void traverse(VisitorIF<?> visitor) throws Exception { if (body != null) { for (PythonTree t : body) { if (t != null) t.accept(visitor); } } }
// in src/org/python/antlr/ast/IfExp.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { return visitor.visitIfExp(this); }
// in src/org/python/antlr/ast/IfExp.java
public void traverse(VisitorIF<?> visitor) throws Exception { if (test != null) test.accept(visitor); if (body != null) body.accept(visitor); if (orelse != null) orelse.accept(visitor); }
// in src/org/python/antlr/ast/TryFinally.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { return visitor.visitTryFinally(this); }
// in src/org/python/antlr/ast/TryFinally.java
public void traverse(VisitorIF<?> visitor) throws Exception { if (body != null) { for (PythonTree t : body) { if (t != null) t.accept(visitor); } } if (finalbody != null) { for (PythonTree t : finalbody) { if (t != null) t.accept(visitor); } } }
// in src/org/python/antlr/ast/ErrorStmt.java
public void traverse(VisitorIF visitor) throws Exception { //no op. }
// in src/org/python/antlr/ast/If.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { return visitor.visitIf(this); }
// in src/org/python/antlr/ast/If.java
public void traverse(VisitorIF<?> visitor) throws Exception { if (test != null) test.accept(visitor); if (body != null) { for (PythonTree t : body) { if (t != null) t.accept(visitor); } } if (orelse != null) { for (PythonTree t : orelse) { if (t != null) t.accept(visitor); } } }
// in src/org/python/antlr/ast/Suite.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { return visitor.visitSuite(this); }
// in src/org/python/antlr/ast/Suite.java
public void traverse(VisitorIF<?> visitor) throws Exception { if (body != null) { for (PythonTree t : body) { if (t != null) t.accept(visitor); } } }
// in src/org/python/antlr/ast/Attribute.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { return visitor.visitAttribute(this); }
// in src/org/python/antlr/ast/Attribute.java
public void traverse(VisitorIF<?> visitor) throws Exception { if (value != null) value.accept(visitor); }
// in src/org/python/antlr/ast/ErrorExpr.java
public void traverse(VisitorIF visitor) throws Exception { //no op. }
// in src/org/python/antlr/ast/BinOp.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { return visitor.visitBinOp(this); }
// in src/org/python/antlr/ast/BinOp.java
public void traverse(VisitorIF<?> visitor) throws Exception { if (left != null) left.accept(visitor); if (right != null) right.accept(visitor); }
// in src/org/python/antlr/ast/Lambda.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { return visitor.visitLambda(this); }
// in src/org/python/antlr/ast/Lambda.java
public void traverse(VisitorIF<?> visitor) throws Exception { if (args != null) args.accept(visitor); if (body != null) body.accept(visitor); }
// in src/org/python/antlr/ast/Call.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { return visitor.visitCall(this); }
// in src/org/python/antlr/ast/Call.java
public void traverse(VisitorIF<?> visitor) throws Exception { if (func != null) func.accept(visitor); if (args != null) { for (PythonTree t : args) { if (t != null) t.accept(visitor); } } if (keywords != null) { for (PythonTree t : keywords) { if (t != null) t.accept(visitor); } } if (starargs != null) starargs.accept(visitor); if (kwargs != null) kwargs.accept(visitor); }
// in src/org/python/antlr/ast/VisitorBase.java
public R visitModule(Module node) throws Exception { R ret = unhandled_node(node); traverse(node); return ret; }
// in src/org/python/antlr/ast/VisitorBase.java
public R visitInteractive(Interactive node) throws Exception { R ret = unhandled_node(node); traverse(node); return ret; }
// in src/org/python/antlr/ast/VisitorBase.java
public R visitExpression(Expression node) throws Exception { R ret = unhandled_node(node); traverse(node); return ret; }
// in src/org/python/antlr/ast/VisitorBase.java
public R visitSuite(Suite node) throws Exception { R ret = unhandled_node(node); traverse(node); return ret; }
// in src/org/python/antlr/ast/VisitorBase.java
public R visitFunctionDef(FunctionDef node) throws Exception { R ret = unhandled_node(node); traverse(node); return ret; }
// in src/org/python/antlr/ast/VisitorBase.java
public R visitClassDef(ClassDef node) throws Exception { R ret = unhandled_node(node); traverse(node); return ret; }
// in src/org/python/antlr/ast/VisitorBase.java
public R visitReturn(Return node) throws Exception { R ret = unhandled_node(node); traverse(node); return ret; }
// in src/org/python/antlr/ast/VisitorBase.java
public R visitDelete(Delete node) throws Exception { R ret = unhandled_node(node); traverse(node); return ret; }
// in src/org/python/antlr/ast/VisitorBase.java
public R visitAssign(Assign node) throws Exception { R ret = unhandled_node(node); traverse(node); return ret; }
// in src/org/python/antlr/ast/VisitorBase.java
public R visitAugAssign(AugAssign node) throws Exception { R ret = unhandled_node(node); traverse(node); return ret; }
// in src/org/python/antlr/ast/VisitorBase.java
public R visitPrint(Print node) throws Exception { R ret = unhandled_node(node); traverse(node); return ret; }
// in src/org/python/antlr/ast/VisitorBase.java
public R visitFor(For node) throws Exception { R ret = unhandled_node(node); traverse(node); return ret; }
// in src/org/python/antlr/ast/VisitorBase.java
public R visitWhile(While node) throws Exception { R ret = unhandled_node(node); traverse(node); return ret; }
// in src/org/python/antlr/ast/VisitorBase.java
public R visitIf(If node) throws Exception { R ret = unhandled_node(node); traverse(node); return ret; }
// in src/org/python/antlr/ast/VisitorBase.java
public R visitWith(With node) throws Exception { R ret = unhandled_node(node); traverse(node); return ret; }
// in src/org/python/antlr/ast/VisitorBase.java
public R visitRaise(Raise node) throws Exception { R ret = unhandled_node(node); traverse(node); return ret; }
// in src/org/python/antlr/ast/VisitorBase.java
public R visitTryExcept(TryExcept node) throws Exception { R ret = unhandled_node(node); traverse(node); return ret; }
// in src/org/python/antlr/ast/VisitorBase.java
public R visitTryFinally(TryFinally node) throws Exception { R ret = unhandled_node(node); traverse(node); return ret; }
// in src/org/python/antlr/ast/VisitorBase.java
public R visitAssert(Assert node) throws Exception { R ret = unhandled_node(node); traverse(node); return ret; }
// in src/org/python/antlr/ast/VisitorBase.java
public R visitImport(Import node) throws Exception { R ret = unhandled_node(node); traverse(node); return ret; }
// in src/org/python/antlr/ast/VisitorBase.java
public R visitImportFrom(ImportFrom node) throws Exception { R ret = unhandled_node(node); traverse(node); return ret; }
// in src/org/python/antlr/ast/VisitorBase.java
public R visitExec(Exec node) throws Exception { R ret = unhandled_node(node); traverse(node); return ret; }
// in src/org/python/antlr/ast/VisitorBase.java
public R visitGlobal(Global node) throws Exception { R ret = unhandled_node(node); traverse(node); return ret; }
// in src/org/python/antlr/ast/VisitorBase.java
public R visitExpr(Expr node) throws Exception { R ret = unhandled_node(node); traverse(node); return ret; }
// in src/org/python/antlr/ast/VisitorBase.java
public R visitPass(Pass node) throws Exception { R ret = unhandled_node(node); traverse(node); return ret; }
// in src/org/python/antlr/ast/VisitorBase.java
public R visitBreak(Break node) throws Exception { R ret = unhandled_node(node); traverse(node); return ret; }
// in src/org/python/antlr/ast/VisitorBase.java
public R visitContinue(Continue node) throws Exception { R ret = unhandled_node(node); traverse(node); return ret; }
// in src/org/python/antlr/ast/VisitorBase.java
public R visitBoolOp(BoolOp node) throws Exception { R ret = unhandled_node(node); traverse(node); return ret; }
// in src/org/python/antlr/ast/VisitorBase.java
public R visitBinOp(BinOp node) throws Exception { R ret = unhandled_node(node); traverse(node); return ret; }
// in src/org/python/antlr/ast/VisitorBase.java
public R visitUnaryOp(UnaryOp node) throws Exception { R ret = unhandled_node(node); traverse(node); return ret; }
// in src/org/python/antlr/ast/VisitorBase.java
public R visitLambda(Lambda node) throws Exception { R ret = unhandled_node(node); traverse(node); return ret; }
// in src/org/python/antlr/ast/VisitorBase.java
public R visitIfExp(IfExp node) throws Exception { R ret = unhandled_node(node); traverse(node); return ret; }
// in src/org/python/antlr/ast/VisitorBase.java
public R visitDict(Dict node) throws Exception { R ret = unhandled_node(node); traverse(node); return ret; }
// in src/org/python/antlr/ast/VisitorBase.java
public R visitListComp(ListComp node) throws Exception { R ret = unhandled_node(node); traverse(node); return ret; }
// in src/org/python/antlr/ast/VisitorBase.java
public R visitGeneratorExp(GeneratorExp node) throws Exception { R ret = unhandled_node(node); traverse(node); return ret; }
// in src/org/python/antlr/ast/VisitorBase.java
public R visitYield(Yield node) throws Exception { R ret = unhandled_node(node); traverse(node); return ret; }
// in src/org/python/antlr/ast/VisitorBase.java
public R visitCompare(Compare node) throws Exception { R ret = unhandled_node(node); traverse(node); return ret; }
// in src/org/python/antlr/ast/VisitorBase.java
public R visitCall(Call node) throws Exception { R ret = unhandled_node(node); traverse(node); return ret; }
// in src/org/python/antlr/ast/VisitorBase.java
public R visitRepr(Repr node) throws Exception { R ret = unhandled_node(node); traverse(node); return ret; }
// in src/org/python/antlr/ast/VisitorBase.java
public R visitNum(Num node) throws Exception { R ret = unhandled_node(node); traverse(node); return ret; }
// in src/org/python/antlr/ast/VisitorBase.java
public R visitStr(Str node) throws Exception { R ret = unhandled_node(node); traverse(node); return ret; }
// in src/org/python/antlr/ast/VisitorBase.java
public R visitAttribute(Attribute node) throws Exception { R ret = unhandled_node(node); traverse(node); return ret; }
// in src/org/python/antlr/ast/VisitorBase.java
public R visitSubscript(Subscript node) throws Exception { R ret = unhandled_node(node); traverse(node); return ret; }
// in src/org/python/antlr/ast/VisitorBase.java
public R visitName(Name node) throws Exception { R ret = unhandled_node(node); traverse(node); return ret; }
// in src/org/python/antlr/ast/VisitorBase.java
public R visitList(List node) throws Exception { R ret = unhandled_node(node); traverse(node); return ret; }
// in src/org/python/antlr/ast/VisitorBase.java
public R visitTuple(Tuple node) throws Exception { R ret = unhandled_node(node); traverse(node); return ret; }
// in src/org/python/antlr/ast/VisitorBase.java
public R visitEllipsis(Ellipsis node) throws Exception { R ret = unhandled_node(node); traverse(node); return ret; }
// in src/org/python/antlr/ast/VisitorBase.java
public R visitSlice(Slice node) throws Exception { R ret = unhandled_node(node); traverse(node); return ret; }
// in src/org/python/antlr/ast/VisitorBase.java
public R visitExtSlice(ExtSlice node) throws Exception { R ret = unhandled_node(node); traverse(node); return ret; }
// in src/org/python/antlr/ast/VisitorBase.java
public R visitIndex(Index node) throws Exception { R ret = unhandled_node(node); traverse(node); return ret; }
// in src/org/python/antlr/ast/VisitorBase.java
public R visitExceptHandler(ExceptHandler node) throws Exception { R ret = unhandled_node(node); traverse(node); return ret; }
// in src/org/python/antlr/ast/Global.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { return visitor.visitGlobal(this); }
// in src/org/python/antlr/ast/Global.java
public void traverse(VisitorIF<?> visitor) throws Exception { }
// in src/org/python/antlr/ast/Tuple.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { return visitor.visitTuple(this); }
// in src/org/python/antlr/ast/Tuple.java
public void traverse(VisitorIF<?> visitor) throws Exception { if (elts != null) { for (PythonTree t : elts) { if (t != null) t.accept(visitor); } } }
// in src/org/python/antlr/ast/ExceptHandler.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { return visitor.visitExceptHandler(this); }
// in src/org/python/antlr/ast/ExceptHandler.java
public void traverse(VisitorIF<?> visitor) throws Exception { if (type != null) type.accept(visitor); if (name != null) name.accept(visitor); if (body != null) { for (PythonTree t : body) { if (t != null) t.accept(visitor); } } }
// in src/org/python/antlr/ast/With.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { return visitor.visitWith(this); }
// in src/org/python/antlr/ast/With.java
public void traverse(VisitorIF<?> visitor) throws Exception { if (context_expr != null) context_expr.accept(visitor); if (optional_vars != null) optional_vars.accept(visitor); if (body != null) { for (PythonTree t : body) { if (t != null) t.accept(visitor); } } }
// in src/org/python/antlr/ast/Repr.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { return visitor.visitRepr(this); }
// in src/org/python/antlr/ast/Repr.java
public void traverse(VisitorIF<?> visitor) throws Exception { if (value != null) value.accept(visitor); }
// in src/org/python/antlr/ast/Slice.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { return visitor.visitSlice(this); }
// in src/org/python/antlr/ast/Slice.java
public void traverse(VisitorIF<?> visitor) throws Exception { if (lower != null) lower.accept(visitor); if (upper != null) upper.accept(visitor); if (step != null) step.accept(visitor); }
// in src/org/python/antlr/ast/TryExcept.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { return visitor.visitTryExcept(this); }
// in src/org/python/antlr/ast/TryExcept.java
public void traverse(VisitorIF<?> visitor) throws Exception { if (body != null) { for (PythonTree t : body) { if (t != null) t.accept(visitor); } } if (handlers != null) { for (PythonTree t : handlers) { if (t != null) t.accept(visitor); } } if (orelse != null) { for (PythonTree t : orelse) { if (t != null) t.accept(visitor); } } }
// in src/org/python/antlr/ast/Str.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { return visitor.visitStr(this); }
// in src/org/python/antlr/ast/Str.java
public void traverse(VisitorIF<?> visitor) throws Exception { }
// in src/org/python/antlr/ast/Exec.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { return visitor.visitExec(this); }
// in src/org/python/antlr/ast/Exec.java
public void traverse(VisitorIF<?> visitor) throws Exception { if (body != null) body.accept(visitor); if (globals != null) globals.accept(visitor); if (locals != null) locals.accept(visitor); }
// in src/org/python/antlr/ast/Raise.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { return visitor.visitRaise(this); }
// in src/org/python/antlr/ast/Raise.java
public void traverse(VisitorIF<?> visitor) throws Exception { if (type != null) type.accept(visitor); if (inst != null) inst.accept(visitor); if (tback != null) tback.accept(visitor); }
// in src/org/python/antlr/ast/Continue.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { return visitor.visitContinue(this); }
// in src/org/python/antlr/ast/Continue.java
public void traverse(VisitorIF<?> visitor) throws Exception { }
// in src/org/python/antlr/ast/BoolOp.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { return visitor.visitBoolOp(this); }
// in src/org/python/antlr/ast/BoolOp.java
public void traverse(VisitorIF<?> visitor) throws Exception { if (values != null) { for (PythonTree t : values) { if (t != null) t.accept(visitor); } } }
// in src/org/python/antlr/ast/GeneratorExp.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { return visitor.visitGeneratorExp(this); }
// in src/org/python/antlr/ast/GeneratorExp.java
public void traverse(VisitorIF<?> visitor) throws Exception { if (elt != null) elt.accept(visitor); if (generators != null) { for (PythonTree t : generators) { if (t != null) t.accept(visitor); } } }
// in src/org/python/antlr/ast/AugAssign.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { return visitor.visitAugAssign(this); }
// in src/org/python/antlr/ast/AugAssign.java
public void traverse(VisitorIF<?> visitor) throws Exception { if (target != null) target.accept(visitor); if (value != null) value.accept(visitor); }
// in src/org/python/antlr/ast/ErrorMod.java
public void traverse(VisitorIF visitor) throws Exception { //no op. }
// in src/org/python/antlr/ast/Assert.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { return visitor.visitAssert(this); }
// in src/org/python/antlr/ast/Assert.java
public void traverse(VisitorIF<?> visitor) throws Exception { if (test != null) test.accept(visitor); if (msg != null) msg.accept(visitor); }
// in src/org/python/antlr/ast/Print.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { return visitor.visitPrint(this); }
// in src/org/python/antlr/ast/Print.java
public void traverse(VisitorIF<?> visitor) throws Exception { if (dest != null) dest.accept(visitor); if (values != null) { for (PythonTree t : values) { if (t != null) t.accept(visitor); } } }
// in src/org/python/antlr/ast/For.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { return visitor.visitFor(this); }
// in src/org/python/antlr/ast/For.java
public void traverse(VisitorIF<?> visitor) throws Exception { if (target != null) target.accept(visitor); if (iter != null) iter.accept(visitor); if (body != null) { for (PythonTree t : body) { if (t != null) t.accept(visitor); } } if (orelse != null) { for (PythonTree t : orelse) { if (t != null) t.accept(visitor); } } }
// in src/org/python/antlr/ast/Expression.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { return visitor.visitExpression(this); }
// in src/org/python/antlr/ast/Expression.java
public void traverse(VisitorIF<?> visitor) throws Exception { if (body != null) body.accept(visitor); }
// in src/org/python/antlr/ast/Index.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { return visitor.visitIndex(this); }
// in src/org/python/antlr/ast/Index.java
public void traverse(VisitorIF<?> visitor) throws Exception { if (value != null) value.accept(visitor); }
// in src/org/python/antlr/Visitor.java
public void traverse(PythonTree node) throws Exception { node.traverse(this); }
// in src/org/python/antlr/Visitor.java
public void visit(PythonTree[] nodes) throws Exception { for (int i = 0; i < nodes.length; i++) { visit(nodes[i]); } }
// in src/org/python/antlr/Visitor.java
public Object visit(PythonTree node) throws Exception { Object ret = node.accept(this); return ret; }
// in src/org/python/antlr/Visitor.java
protected Object unhandled_node(PythonTree node) throws Exception { return this; }
// in src/org/python/modules/ucnhash.java
public static void loadTables() throws Exception { InputStream instream = ucnhash.class. getResourceAsStream("ucnhash.dat"); if (instream == null) throw new IOException("Unicode name database not found: " + "ucnhash.dat"); DataInputStream in = new DataInputStream( new BufferedInputStream(instream)); n = in.readShort(); m = in.readShort(); minchar= in.readShort(); maxchar = in.readShort(); alphasz = in.readShort(); maxlen = in.readShort(); maxidx = maxlen*alphasz-minchar; G = readShortTable(in); if (in.readShort() != 3) throw new IOException("UnicodeNameMap file corrupt, " + "unknown dimension"); T0 = readShortTable(in); T1 = readShortTable(in); T2 = readShortTable(in); wordoffs = readShortTable(in); worddata = readByteTable(in); wordstart = in.readShort(); wordcutoff = in.readShort(); maxklen = in.readShort(); rawdata = readByteTable(in); rawindex = readCharTable(in); codepoint = readCharTable(in); }
// in src/org/python/modules/ucnhash.java
public static void main(String[] args) throws Exception { loadTables(); debug = true; /* System.out.println(getWord(hash("ARABIC"))); System.out.println(getWord(hash("SMALL"))); System.out.println(getWord(hash("YI"))); System.out.println(getWord(hash("SYLLABLE"))); System.out.println(getWord(hash("WITH"))); System.out.println(getWord(hash("LETTER"))); System.out.println(lookup("NULL")); System.out.println(lookup("LATIN CAPITAL LETTER AFRICAN D")); System.out.println(lookup("GURMUKHI TIPPI")); System.out.println(lookup("TIBETAN MARK GTER YIG MGO -UM " + "RNAM BCAD MA")); System.out.println(lookup("HANGUL CHOSEONG PIEUP")); System.out.println(lookup("SINGLE LOW-9 QUOTATION MARK")); */ System.out.println(lookup("BACKSPACE")); // System.out.println(lookup("ACTIVATE SYMMETRIC SWAPPING")); /* System.out.println(lookup("LATIN CAPITAL LETTER A")); System.out.println(lookup("GREATER-THAN SIGN")); System.out.println(lookup("EURO-CURRENCY SIGN")); */ }
// in src/org/python/core/Py.java
public static void runMain(PyRunnable main, String[] args) throws Exception { runMain(new PyRunnableBootstrap(main), args); }
// in src/org/python/core/Py.java
public static void runMain(CodeBootstrap main, String[] args) throws Exception { PySystemState.initialize(null, null, args, main.getClass().getClassLoader()); try { imp.createFromCode("__main__", CodeLoader.loadCode(main)); } catch (PyException e) { Py.getSystemState().callExitFunc(); if (e.match(Py.SystemExit)) { return; } throw e; } Py.getSystemState().callExitFunc(); }
58
            
// in src/com/ziclix/python/sql/DataHandler.java
catch (Exception e) { SQLException cause = null, ex = new SQLException("error setting index [" + index + "]"); if (e instanceof SQLException) { cause = (SQLException) e; } else { cause = new SQLException(e.getMessage()); } ex.setNextException(cause); throw ex; }
// in src/com/ziclix/python/sql/DataHandler.java
catch (Exception e) { SQLException cause = null, ex = new SQLException("error setting index [" + index + "], type [" + type + "]"); if (e instanceof SQLException) { cause = (SQLException) e; } else { cause = new SQLException(e.getMessage()); } ex.setNextException(cause); throw ex; }
// in src/com/ziclix/python/sql/Jython22DataHandler.java
catch (Exception e) { SQLException cause = null, ex = new SQLException("error setting index [" + index + "]"); if (e instanceof SQLException) { cause = (SQLException) e; } else { cause = new SQLException(e.getMessage()); } ex.setNextException(cause); throw ex; }
// in src/com/ziclix/python/sql/Jython22DataHandler.java
catch (Exception e) { SQLException cause = null, ex = new SQLException("error setting index [" + index + "], type [" + type + "]"); if (e instanceof SQLException) { cause = (SQLException) e; } else { cause = new SQLException(e.getMessage()); } ex.setNextException(cause); throw ex; }
// in src/com/ziclix/python/sql/connect/Connectx.java
catch (Exception e) { throw zxJDBC.makeException(zxJDBC.DatabaseError, "unable to instantiate datasource"); }
// in src/com/ziclix/python/sql/pipe/db/DBSink.java
catch (Exception e) { // either a KeyError or this.bindings is None or null this.indexedBindings.__setitem__(pyIndex, entry.__getitem__(1)); }
// in src/com/ziclix/python/sql/pipe/db/DBSink.java
catch (Exception e) { // either a KeyError or this.bindings is None or null this.indexedBindings.__setitem__(pyIndex, entry.__getitem__(1)); }
// in src/com/ziclix/python/sql/pipe/db/BaseDB.java
catch (Exception e) { return cursor; }
// in src/com/ziclix/python/sql/pipe/db/BaseDB.java
catch (Exception e) { return cursor; }
// in src/com/ziclix/python/sql/Procedure.java
catch (SQLException e) { if (statement != null) { try { statement.close(); } catch (Exception ex) { } } throw e; }
// in src/com/ziclix/python/sql/Procedure.java
catch (Exception ex) { }
// in src/org/python/indexer/ast/BindingFinder.java
catch (Exception x) { Indexer.idx.handleException("error binding names for " + n, x); }
// in src/org/python/indexer/ast/NNode.java
catch (Exception x) { return handleExceptionInResolve(n, x); }
// in src/org/python/indexer/AstCache.java
catch (Exception x) { severe("Failed to clear disk cache: " + x); return false; }
// in src/org/python/indexer/AstCache.java
catch (Exception x) { fine("parse for " + filename + " failed: " + x); }
// in src/org/python/indexer/AstCache.java
catch (Exception x) { severe("Failed to deserialize " + sourcePath + ": " + x); return null; }
// in src/org/python/indexer/demos/Linker.java
catch (Exception x) { System.err.println("path problem: dest=" + destPath + ", root=" + rootPath + ": " + x); return null; }
// in src/org/python/expose/generate/TypeExposer.java
catch(Exception e) { // If we're unable to create the generated class, the process is // definitely ill, but that shouldn't be the case most of the time // so make this a runtime exception throw new RuntimeException("Unable to create generated builder", e); }
// in src/org/python/antlr/AnalyzingParser.java
catch (Exception x) { x.printStackTrace(); }
// in src/org/python/jsr223/PyScriptEngine.java
catch (Exception ee) { se = new ScriptException(pye); }
// in src/org/python/modules/_weakref/AbstractReference.java
catch (Exception exc) { Py.writeUnraisable(exc, callback); }
// in src/org/python/modules/ucnhash.java
catch (Exception exc) { return false; }
// in src/org/python/modules/_collections/PyDefaultDict.java
catch (Exception ex) { throw Py.KeyError(key); }
// in src/org/python/core/PyBeanProperty.java
catch (Exception e) { throw Py.JavaError(e); }
// in src/org/python/core/PyBeanProperty.java
catch (Exception e) { throw Py.JavaError(e); }
// in src/org/python/core/PyObject.java
catch (Exception exc) { throw Py.JavaError(exc); }
// in src/org/python/core/SyspathJavaLoader.java
catch (Exception e) { return path; }
// in src/org/python/core/PySystemState.java
catch (Exception exc) { return null; }
// in src/org/python/core/PySystemState.java
catch (Exception exc) { }
// in src/org/python/core/PySystemState.java
catch (Exception e) { // ignore any exception }
// in src/org/python/core/PySystemState.java
catch (Exception e) { Py.writeWarning("initializer", "Unexpected exception thrown while trying to use initializer service"); e.printStackTrace(System.err); }
// in src/org/python/core/PySystemState.java
catch (Exception e) { Py.writeWarning("initializer", "Failed initializing with class '" + className + "', continuing"); e.printStackTrace(System.err); return false; }
// in src/org/python/core/PySystemState.java
catch (Exception e) {}
// in src/org/python/core/PySystemState.java
catch (Exception e) { // just continue, nothing we can do }
// in src/org/python/core/PySystemState.java
catch (Exception e) { // continue - nothing we can do now! }
// in src/org/python/core/MakeProxies.java
catch (Exception exc) { throw Py.JavaError(exc); }
// in src/org/python/core/MakeProxies.java
catch (Exception exc) { throw Py.JavaError(exc); }
// in src/org/python/core/BytecodeLoader.java
catch (Exception e) { throw Py.JavaError(e); }
// in src/org/python/core/PyReflectedFunction.java
catch (Exception e) { throw Py.JavaError(e); }
// in src/org/python/core/PyBeanEventProperty.java
catch (Exception exc) { throw Py.JavaError(exc); }
// in src/org/python/core/PyBeanEventProperty.java
catch (Exception e) { throw Py.JavaError(e); }
// in src/org/python/core/PyBeanEventProperty.java
catch (Exception exc) { throw Py.JavaError(exc); }
// in src/org/python/core/PyBeanEvent.java
catch (Exception e) { throw Py.JavaError(e); }
// in src/org/python/core/io/StreamIO.java
catch (Exception e) { // XXX: masking other exceptions }
// in src/org/python/core/io/StreamIO.java
catch (Exception e) { // XXX: masking other exceptions }
// in src/org/python/core/PyRunnableBootstrap.java
catch (Exception e) { throw new IllegalArgumentException( "PyRunnable class does not specify apropriate constructor.", e); }
// in src/org/python/core/PyRunnableBootstrap.java
catch (Exception e) { throw new IllegalArgumentException( "PyRunnable class constructor does not support instantiation protocol.", e); }
// in src/org/python/core/exceptions.java
catch (Exception e) { throw Py.JavaError(e); }
// in src/org/python/core/PyJavaType.java
catch (Exception exc) { throw Py.JavaError(exc); }
// in src/org/python/core/PyJavaType.java
catch (Exception ex) { throw Py.TypeError("Could not copy Java object"); }
// in src/org/python/core/PyJavaType.java
catch (Exception ex) { throw Py.TypeError("Could not copy Java object"); }
// in src/org/python/core/PyJavaType.java
catch (Exception e) { throw Py.JavaError(e); }
// in src/org/python/core/CodeLoader.java
catch (Exception e) { return false; }
// in src/org/python/core/ParserFacade.java
catch (Exception e) { return lexer.eofWhileNested; }
// in src/org/python/core/imp.java
catch (Exception exc) { continue; }
// in src/org/python/core/NewCompilerResources.java
catch (Exception exc) { continue; }
// in src/org/python/util/JythoncAntTask.java
catch (Exception e) { // Have to catch this because of the semantics of calling main() String msg = "Exception while calling " + JYTHON_CLASS + ". Details: " + e.toString(); throw new BuildException(msg, e); }
// in src/org/python/util/JLineConsole.java
catch (Exception ex) { System.err.println(ex); }
// in src/org/python/util/JLineConsole.java
catch (IOException ioe) { if (!fromSuspend(ioe)) { throw Py.IOError(ioe); } // Hopefully an IOException caused by ctrl-z (seems only BSD throws this). // Must reset jline to continue try { reader.getTerminal().initializeTerminal(); } catch (Exception e) { throw Py.IOError(e.getMessage()); } // Don't redisplay the prompt promptString = ""; }
// in src/org/python/util/JLineConsole.java
catch (Exception e) { throw Py.IOError(e.getMessage()); }
27
            
// in src/com/ziclix/python/sql/DataHandler.java
catch (Exception e) { SQLException cause = null, ex = new SQLException("error setting index [" + index + "]"); if (e instanceof SQLException) { cause = (SQLException) e; } else { cause = new SQLException(e.getMessage()); } ex.setNextException(cause); throw ex; }
// in src/com/ziclix/python/sql/DataHandler.java
catch (Exception e) { SQLException cause = null, ex = new SQLException("error setting index [" + index + "], type [" + type + "]"); if (e instanceof SQLException) { cause = (SQLException) e; } else { cause = new SQLException(e.getMessage()); } ex.setNextException(cause); throw ex; }
// in src/com/ziclix/python/sql/Jython22DataHandler.java
catch (Exception e) { SQLException cause = null, ex = new SQLException("error setting index [" + index + "]"); if (e instanceof SQLException) { cause = (SQLException) e; } else { cause = new SQLException(e.getMessage()); } ex.setNextException(cause); throw ex; }
// in src/com/ziclix/python/sql/Jython22DataHandler.java
catch (Exception e) { SQLException cause = null, ex = new SQLException("error setting index [" + index + "], type [" + type + "]"); if (e instanceof SQLException) { cause = (SQLException) e; } else { cause = new SQLException(e.getMessage()); } ex.setNextException(cause); throw ex; }
// in src/com/ziclix/python/sql/connect/Connectx.java
catch (Exception e) { throw zxJDBC.makeException(zxJDBC.DatabaseError, "unable to instantiate datasource"); }
// in src/com/ziclix/python/sql/Procedure.java
catch (SQLException e) { if (statement != null) { try { statement.close(); } catch (Exception ex) { } } throw e; }
// in src/org/python/expose/generate/TypeExposer.java
catch(Exception e) { // If we're unable to create the generated class, the process is // definitely ill, but that shouldn't be the case most of the time // so make this a runtime exception throw new RuntimeException("Unable to create generated builder", e); }
// in src/org/python/modules/_collections/PyDefaultDict.java
catch (Exception ex) { throw Py.KeyError(key); }
// in src/org/python/core/PyBeanProperty.java
catch (Exception e) { throw Py.JavaError(e); }
// in src/org/python/core/PyBeanProperty.java
catch (Exception e) { throw Py.JavaError(e); }
// in src/org/python/core/PyObject.java
catch (Exception exc) { throw Py.JavaError(exc); }
// in src/org/python/core/MakeProxies.java
catch (Exception exc) { throw Py.JavaError(exc); }
// in src/org/python/core/MakeProxies.java
catch (Exception exc) { throw Py.JavaError(exc); }
// in src/org/python/core/BytecodeLoader.java
catch (Exception e) { throw Py.JavaError(e); }
// in src/org/python/core/PyReflectedFunction.java
catch (Exception e) { throw Py.JavaError(e); }
// in src/org/python/core/PyBeanEventProperty.java
catch (Exception exc) { throw Py.JavaError(exc); }
// in src/org/python/core/PyBeanEventProperty.java
catch (Exception e) { throw Py.JavaError(e); }
// in src/org/python/core/PyBeanEventProperty.java
catch (Exception exc) { throw Py.JavaError(exc); }
// in src/org/python/core/PyBeanEvent.java
catch (Exception e) { throw Py.JavaError(e); }
// in src/org/python/core/PyRunnableBootstrap.java
catch (Exception e) { throw new IllegalArgumentException( "PyRunnable class does not specify apropriate constructor.", e); }
// in src/org/python/core/PyRunnableBootstrap.java
catch (Exception e) { throw new IllegalArgumentException( "PyRunnable class constructor does not support instantiation protocol.", e); }
// in src/org/python/core/exceptions.java
catch (Exception e) { throw Py.JavaError(e); }
// in src/org/python/core/PyJavaType.java
catch (Exception exc) { throw Py.JavaError(exc); }
// in src/org/python/core/PyJavaType.java
catch (Exception ex) { throw Py.TypeError("Could not copy Java object"); }
// in src/org/python/core/PyJavaType.java
catch (Exception ex) { throw Py.TypeError("Could not copy Java object"); }
// in src/org/python/core/PyJavaType.java
catch (Exception e) { throw Py.JavaError(e); }
// in src/org/python/util/JythoncAntTask.java
catch (Exception e) { // Have to catch this because of the semantics of calling main() String msg = "Exception while calling " + JYTHON_CLASS + ". Details: " + e.toString(); throw new BuildException(msg, e); }
// in src/org/python/util/JLineConsole.java
catch (IOException ioe) { if (!fromSuspend(ioe)) { throw Py.IOError(ioe); } // Hopefully an IOException caused by ctrl-z (seems only BSD throws this). // Must reset jline to continue try { reader.getTerminal().initializeTerminal(); } catch (Exception e) { throw Py.IOError(e.getMessage()); } // Don't redisplay the prompt promptString = ""; }
// in src/org/python/util/JLineConsole.java
catch (Exception e) { throw Py.IOError(e.getMessage()); }
3
unknown (Lib) ExceptionInInitializerError 0 0 0 1
            
// in src/org/python/core/PyType.java
catch (ExceptionInInitializerError e) { throw Py.JavaError(e); }
1
            
// in src/org/python/core/PyType.java
catch (ExceptionInInitializerError e) { throw Py.JavaError(e); }
0
unknown (Lib) FileNotFoundException 1
            
// in src/org/python/core/io/FileIO.java
private void fromRandomAccessFile(File absPath) throws FileNotFoundException { String rafMode = "r" + (writing ? "w" : ""); if (plus && reading && !absPath.isFile()) { // suppress "permission denied" writing = false; throw new FileNotFoundException(""); } file = new RandomAccessFile(absPath, rafMode); fileChannel = file.getChannel(); }
0 2
            
// in src/org/python/core/io/FileIO.java
private void fromRandomAccessFile(File absPath) throws FileNotFoundException { String rafMode = "r" + (writing ? "w" : ""); if (plus && reading && !absPath.isFile()) { // suppress "permission denied" writing = false; throw new FileNotFoundException(""); } file = new RandomAccessFile(absPath, rafMode); fileChannel = file.getChannel(); }
// in src/org/python/core/io/FileIO.java
private void fromFileOutputStream(File absPath) throws FileNotFoundException { fileOutputStream = new FileOutputStream(absPath, true); fileChannel = fileOutputStream.getChannel(); }
6
            
// in src/org/python/modules/posix/PosixModule.java
catch (FileNotFoundException fnfe) { throw Py.OSError(file.isDirectory() ? Errno.EISDIR : Errno.ENOENT, path); }
// in src/org/python/core/SyspathJavaLoader.java
catch (FileNotFoundException e) { return null; }
// in src/org/python/core/io/FileIO.java
catch (FileNotFoundException fnfe) { if (absPath.isDirectory()) { throw Py.IOError(Errno.EISDIR, name); } if ((writing && !absPath.canWrite()) || fnfe.getMessage().endsWith("(Permission denied)")) { throw Py.IOError(Errno.EACCES, name); } throw Py.IOError(Errno.ENOENT, name); }
// in src/org/python/core/__builtin__.java
catch (FileNotFoundException e) { throw Py.IOError(e); }
// in src/org/python/util/JLineConsole.java
catch (FileNotFoundException fnfe) { // Shouldn't really ever happen fnfe.printStackTrace(); }
// in src/org/python/util/jython.java
catch (FileNotFoundException e) { throw Py.IOError(e); }
6
            
// in src/org/python/modules/posix/PosixModule.java
catch (FileNotFoundException fnfe) { throw Py.OSError(file.isDirectory() ? Errno.EISDIR : Errno.ENOENT, path); }
// in src/org/python/core/io/FileIO.java
catch (FileNotFoundException fnfe) { if (absPath.isDirectory()) { throw Py.IOError(Errno.EISDIR, name); } if ((writing && !absPath.canWrite()) || fnfe.getMessage().endsWith("(Permission denied)")) { throw Py.IOError(Errno.EACCES, name); } throw Py.IOError(Errno.ENOENT, name); }
// in src/org/python/core/__builtin__.java
catch (FileNotFoundException e) { throw Py.IOError(e); }
// in src/org/python/util/jython.java
catch (FileNotFoundException e) { throw Py.IOError(e); }
0
checked (Lib) IOException 8
            
// in src/org/python/indexer/Util.java
public static byte[] getBytesFromFile(File file) throws IOException { InputStream is = null; try { is = new FileInputStream(file); long length = file.length(); if (length > Integer.MAX_VALUE) { throw new IOException("file too large: " + file); } byte[] bytes = new byte[(int)length]; int offset = 0; int numRead = 0; while (offset < bytes.length && (numRead = is.read(bytes, offset, bytes.length-offset)) >= 0) { offset += numRead; } if (offset < bytes.length) { throw new IOException("Failed to read whole file " + file); } return bytes; } finally { if (is != null) { is.close(); } } }
// in src/org/python/modules/ucnhash.java
public static void loadTables() throws Exception { InputStream instream = ucnhash.class. getResourceAsStream("ucnhash.dat"); if (instream == null) throw new IOException("Unicode name database not found: " + "ucnhash.dat"); DataInputStream in = new DataInputStream( new BufferedInputStream(instream)); n = in.readShort(); m = in.readShort(); minchar= in.readShort(); maxchar = in.readShort(); alphasz = in.readShort(); maxlen = in.readShort(); maxidx = maxlen*alphasz-minchar; G = readShortTable(in); if (in.readShort() != 3) throw new IOException("UnicodeNameMap file corrupt, " + "unknown dimension"); T0 = readShortTable(in); T1 = readShortTable(in); T2 = readShortTable(in); wordoffs = readShortTable(in); worddata = readByteTable(in); wordstart = in.readShort(); wordcutoff = in.readShort(); maxklen = in.readShort(); rawdata = readByteTable(in); rawindex = readCharTable(in); codepoint = readCharTable(in); }
// in src/org/python/modules/ucnhash.java
private static short[] readShortTable(DataInputStream in) throws IOException { if (in.read() != 't') throw new IOException("UnicodeNameMap file corrupt, shorttable"); int n = in.readUnsignedShort() / 2; short[] table = new short[n]; for (int i = 0; i < n; i++) { table[i] = in.readShort(); } return table; }
// in src/org/python/modules/ucnhash.java
private static char[] readCharTable(DataInputStream in) throws IOException { if (in.read() != 't') throw new IOException("UnicodeNameMap file corrupt, chartable"); int n = in.readUnsignedShort() / 2; char[] table = new char[n]; for (int i = 0; i < n; i++) { table[i] = in.readChar(); } return table; }
// in src/org/python/modules/ucnhash.java
private static byte[] readByteTable(DataInputStream in) throws IOException { if (in.read() != 't') throw new IOException("UnicodeNameMap file corrupt, byte table"); int n = in.readUnsignedShort(); byte[] table = new byte[n]; in.readFully(table); return table; }
0 94
            
// in src/com/xhaus/modjy/ModjyJServlet.java
Override public void service(HttpServletRequest req, HttpServletResponse resp) throws ServletException, IOException { modjyServlet.service(req, resp); }
// in src/org/python/indexer/Indexer.java
public void setProjectDir(String cd) throws IOException { projDir = Util.canonicalize(cd); }
// in src/org/python/indexer/Indexer.java
public void addPaths(List<String> p) throws IOException { for (String s : p) { addPath(s); } }
// in src/org/python/indexer/Indexer.java
public void addPath(String p) throws IOException { path.add(Util.canonicalize(p)); }
// in src/org/python/indexer/Indexer.java
public void setPath(List<String> path) throws IOException { this.path = new ArrayList<String>(path.size()); addPaths(path); }
// in src/org/python/indexer/Util.java
public static byte[] getBytesFromFile(File file) throws IOException { InputStream is = null; try { is = new FileInputStream(file); long length = file.length(); if (length > Integer.MAX_VALUE) { throw new IOException("file too large: " + file); } byte[] bytes = new byte[(int)length]; int offset = 0; int numRead = 0; while (offset < bytes.length && (numRead = is.read(bytes, offset, bytes.length-offset)) >= 0) { offset += numRead; } if (offset < bytes.length) { throw new IOException("Failed to read whole file " + file); } return bytes; } finally { if (is != null) { is.close(); } } }
// in src/org/python/compiler/ClassFile.java
public void addInterface(String name) throws IOException { String[] new_interfaces = new String[interfaces.length+1]; System.arraycopy(interfaces, 0, new_interfaces, 0, interfaces.length); new_interfaces[interfaces.length] = name; interfaces = new_interfaces; }
// in src/org/python/compiler/ClassFile.java
public Code addMethod(String name, String type, int access) throws IOException { MethodVisitor mv = cw.visitMethod(access, name, type, null, null); Code pmv = new Code(mv, type, access); methodVisitors.add(pmv); return pmv; }
// in src/org/python/compiler/ClassFile.java
public void addField(String name, String type, int access) throws IOException { FieldVisitor fv = cw.visitField(access, name, type, null, null); fieldVisitors.add(fv); }
// in src/org/python/compiler/ClassFile.java
public void endFields() throws IOException { for (FieldVisitor fv : fieldVisitors) { fv.visitEnd(); } }
// in src/org/python/compiler/ClassFile.java
public void endMethods() throws IOException { for (int i=0; i<methodVisitors.size(); i++) { MethodVisitor mv = methodVisitors.get(i); mv.visitMaxs(0,0); mv.visitEnd(); } }
// in src/org/python/compiler/ClassFile.java
public void write(OutputStream stream) throws IOException { cw.visit(Opcodes.V1_5, Opcodes.ACC_PUBLIC + Opcodes.ACC_SUPER, this.name, null, this.superclass, interfaces); AnnotationVisitor av = cw.visitAnnotation("Lorg/python/compiler/APIVersion;", true); // XXX: should imp.java really house this value or should imp.java point into // org.python.compiler? av.visit("value", new Integer(imp.getAPIVersion())); av.visitEnd(); av = cw.visitAnnotation("Lorg/python/compiler/MTime;", true); av.visit("value", new Long(mtime)); av.visitEnd(); if (sfilename != null) { cw.visitSource(sfilename, null); } endFields(); endMethods(); byte[] ba = cw.toByteArray(); //fos = io.FileOutputStream("%s.class" % self.name) ByteArrayOutputStream baos = new ByteArrayOutputStream(ba.length); baos.write(ba, 0, ba.length); baos.writeTo(stream); //debug(baos); baos.close(); }
// in src/org/python/compiler/CodeCompiler.java
public void getNone() throws IOException { code.getstatic(p(Py.class), "None", ci(PyObject.class)); }
// in src/org/python/compiler/CodeCompiler.java
static int makeStrings(Code c, Collection<String> names) throws IOException { if (names != null) { c.iconst(names.size()); } else { c.iconst_0(); } c.anewarray(p(String.class)); int strings = c.getLocal(ci(String[].class)); c.astore(strings); if (names != null) { int i = 0; for (String name : names) { c.aload(strings); c.iconst(i); c.ldc(name); c.aastore(); i++; } } return strings; }
// in src/org/python/compiler/Module.java
void get(Code c) throws IOException { c.getstatic(module.classfile.name, name, ci(PyInteger.class)); }
// in src/org/python/compiler/Module.java
void put(Code c) throws IOException { module.classfile.addField(name, ci(PyInteger.class), access); c.iconst(value); c.invokestatic(p(Py.class), "newInteger", sig(PyInteger.class, Integer.TYPE)); c.putstatic(module.classfile.name, name, ci(PyInteger.class)); }
// in src/org/python/compiler/Module.java
void get(Code c) throws IOException { c.getstatic(module.classfile.name, name, ci(PyFloat.class)); }
// in src/org/python/compiler/Module.java
void put(Code c) throws IOException { module.classfile.addField(name, ci(PyFloat.class), access); c.ldc(new Double(value)); c.invokestatic(p(Py.class), "newFloat", sig(PyFloat.class, Double.TYPE)); c.putstatic(module.classfile.name, name, ci(PyFloat.class)); }
// in src/org/python/compiler/Module.java
void get(Code c) throws IOException { c.getstatic(module.classfile.name, name, ci(PyComplex.class)); }
// in src/org/python/compiler/Module.java
void put(Code c) throws IOException { module.classfile.addField(name, ci(PyComplex.class), access); c.ldc(new Double(value)); c.invokestatic(p(Py.class), "newImaginary", sig(PyComplex.class, Double.TYPE)); c.putstatic(module.classfile.name, name, ci(PyComplex.class)); }
// in src/org/python/compiler/Module.java
void get(Code c) throws IOException { c.getstatic(module.classfile.name, name, ci(PyString.class)); }
// in src/org/python/compiler/Module.java
void put(Code c) throws IOException { module.classfile.addField(name, ci(PyString.class), access); c.ldc(value); c.invokestatic(p(PyString.class), "fromInterned", sig(PyString.class, String.class)); c.putstatic(module.classfile.name, name, ci(PyString.class)); }
// in src/org/python/compiler/Module.java
void get(Code c) throws IOException { c.getstatic(module.classfile.name, name, ci(PyUnicode.class)); }
// in src/org/python/compiler/Module.java
void put(Code c) throws IOException { module.classfile.addField(name, ci(PyUnicode.class), access); c.ldc(value); c.invokestatic(p(PyUnicode.class), "fromInterned", sig(PyUnicode.class, String.class)); c.putstatic(module.classfile.name, name, ci(PyUnicode.class)); }
// in src/org/python/compiler/Module.java
void get(Code c) throws IOException { c.getstatic(module.classfile.name, name, ci(PyLong.class)); }
// in src/org/python/compiler/Module.java
void put(Code c) throws IOException { module.classfile.addField(name, ci(PyLong.class), access); c.ldc(value); c.invokestatic(p(Py.class), "newLong", sig(PyLong.class, String.class)); c.putstatic(module.classfile.name, name, ci(PyLong.class)); }
// in src/org/python/compiler/Module.java
void get(Code c) throws IOException { c.getstatic(module.classfile.name, name, ci(PyCode.class)); }
// in src/org/python/compiler/Module.java
void put(Code c) throws IOException { module.classfile.addField(name, ci(PyCode.class), access); c.iconst(argcount); //Make all names int nameArray; if (names != null) { nameArray = CodeCompiler.makeStrings(c, names); } else { // classdef nameArray = CodeCompiler.makeStrings(c, null); } c.aload(nameArray); c.freeLocal(nameArray); c.aload(1); c.ldc(co_name); c.iconst(co_firstlineno); c.iconst(arglist ? 1 : 0); c.iconst(keywordlist ? 1 : 0); c.getstatic(module.classfile.name, "self", "L" + module.classfile.name + ";"); c.iconst(id); if (cellvars != null) { int strArray = CodeCompiler.makeStrings(c, cellvars); c.aload(strArray); c.freeLocal(strArray); } else { c.aconst_null(); } if (freevars != null) { int strArray = CodeCompiler.makeStrings(c, freevars); c.aload(strArray); c.freeLocal(strArray); } else { c.aconst_null(); } c.iconst(jy_npurecell); c.iconst(moreflags); c.invokestatic(p(Py.class), "newCode", sig(PyCode.class, Integer.TYPE, String[].class, String.class, String.class, Integer.TYPE, Boolean.TYPE, Boolean.TYPE, PyFunctionTable.class, Integer.TYPE, String[].class, String[].class, Integer.TYPE, Integer.TYPE)); c.putstatic(module.classfile.name, name, ci(PyCode.class)); }
// in src/org/python/compiler/Module.java
public void addInit() throws IOException { Code c = classfile.addMethod("<init>", sig(Void.TYPE, String.class), ACC_PUBLIC); c.aload(0); c.invokespecial(p(PyFunctionTable.class), "<init>", sig(Void.TYPE)); addConstants(c); }
// in src/org/python/compiler/Module.java
public void addRunnable() throws IOException { Code c = classfile.addMethod("getMain", sig(PyCode.class), ACC_PUBLIC); mainCode.get(c); c.areturn(); }
// in src/org/python/compiler/Module.java
public void addMain() throws IOException { Code c = classfile.addMethod("main", sig(Void.TYPE, String[].class), ACC_PUBLIC | ACC_STATIC); c.new_(classfile.name); c.dup(); c.ldc(classfile.name); c.invokespecial(classfile.name, "<init>", sig(Void.TYPE, String.class)); c.invokevirtual(classfile.name, "getMain", sig(PyCode.class)); c.invokestatic(p(CodeLoader.class), CodeLoader.SIMPLE_FACTORY_METHOD_NAME, sig(CodeBootstrap.class, PyCode.class)); c.aload(0); c.invokestatic(p(Py.class), "runMain", sig(Void.TYPE, CodeBootstrap.class, String[].class)); c.return_(); }
// in src/org/python/compiler/Module.java
public void addBootstrap() throws IOException { Code c = classfile.addMethod(CodeLoader.GET_BOOTSTRAP_METHOD_NAME, sig(CodeBootstrap.class), ACC_PUBLIC | ACC_STATIC); c.ldc(Type.getType("L" + classfile.name + ";")); c.invokestatic(p(PyRunnableBootstrap.class), PyRunnableBootstrap.REFLECTION_METHOD_NAME, sig(CodeBootstrap.class, Class.class)); c.areturn(); }
// in src/org/python/compiler/Module.java
void addConstants(Code c) throws IOException { classfile.addField("self", "L" + classfile.name + ";", ACC_STATIC); c.aload(0); c.putstatic(classfile.name, "self", "L" + classfile.name + ";"); Enumeration e = constants.elements(); while (e.hasMoreElements()) { Constant constant = (Constant) e.nextElement(); constant.put(c); } for (int i = 0; i < codes.size(); i++) { PyCodeConstant pyc = codes.get(i); pyc.put(c); } c.return_(); }
// in src/org/python/compiler/Module.java
public void addFunctions() throws IOException { Code code = classfile.addMethod("call_function", sig(PyObject.class, Integer.TYPE, PyFrame.class, ThreadState.class), ACC_PUBLIC); code.aload(0); // this code.aload(2); // frame code.aload(3); // thread state Label def = new Label(); Label[] labels = new Label[codes.size()]; int i; for (i = 0; i < labels.length; i++) { labels[i] = new Label(); } //Get index for function to call code.iload(1); code.tableswitch(0, labels.length - 1, def, labels); for (i = 0; i < labels.length; i++) { code.label(labels[i]); code.invokevirtual(classfile.name, (codes.get(i)).fname, sig(PyObject.class, PyFrame.class, ThreadState.class)); code.areturn(); } code.label(def); //Should probably throw internal exception here code.aconst_null(); code.areturn(); }
// in src/org/python/compiler/Module.java
public void write(OutputStream stream) throws IOException { addInit(); addRunnable(); addMain(); addBootstrap(); addFunctions(); classfile.addInterface(p(PyRunnable.class)); if (sfilename != null) { classfile.setSource(sfilename); } classfile.write(stream); }
// in src/org/python/compiler/LineNumberTable.java
public void write(DataOutputStream stream) throws IOException { stream.writeShort(attName); int n = lines.size(); stream.writeInt(n * 2 + 2); stream.writeShort(n / 2); for (int i = 0; i < n; i += 2) { Short startpc = lines.elementAt(i); Short lineno = lines.elementAt(i+1); stream.writeShort(startpc.shortValue()); stream.writeShort(lineno.shortValue()); } }
// in src/org/python/antlr/NoCloseReaderStream.java
public void load(Reader r, int size, int readChunkSize) throws IOException { if ( r==null ) { return; } if ( size<=0 ) { size = INITIAL_BUFFER_SIZE; } if ( readChunkSize<=0 ) { readChunkSize = READ_BUFFER_SIZE; } data = new char[size]; // read all the data in chunks of readChunkSize int numRead=0; int p = 0; do { if ( p+readChunkSize > data.length ) { // overflow? char[] newdata = new char[data.length*2]; // resize System.arraycopy(data, 0, newdata, 0, data.length); data = newdata; } numRead = r.read(data, p, readChunkSize); p += numRead; } while (numRead!=-1); // while not EOF // set the actual size of the data available; // EOF subtracted one above in p+=numRead; add one back super.n = p+1; }
// in src/org/python/modules/ucnhash.java
private static short[] readShortTable(DataInputStream in) throws IOException { if (in.read() != 't') throw new IOException("UnicodeNameMap file corrupt, shorttable"); int n = in.readUnsignedShort() / 2; short[] table = new short[n]; for (int i = 0; i < n; i++) { table[i] = in.readShort(); } return table; }
// in src/org/python/modules/ucnhash.java
private static char[] readCharTable(DataInputStream in) throws IOException { if (in.read() != 't') throw new IOException("UnicodeNameMap file corrupt, chartable"); int n = in.readUnsignedShort() / 2; char[] table = new char[n]; for (int i = 0; i < n; i++) { table[i] = in.readChar(); } return table; }
// in src/org/python/modules/ucnhash.java
private static byte[] readByteTable(DataInputStream in) throws IOException { if (in.read() != 't') throw new IOException("UnicodeNameMap file corrupt, byte table"); int n = in.readUnsignedShort(); byte[] table = new byte[n]; in.readFully(table); return table; }
// in src/org/python/core/FilelikeInputStream.java
public int read() throws IOException { byte[] oneB = new byte[1]; int numread = read(oneB, 0, 1); if(numread == -1) { return -1; } return oneB[0]; }
// in src/org/python/core/FilelikeInputStream.java
public int read(byte b[], int off, int len) throws IOException { if(b == null) { throw new NullPointerException(); } else if((off < 0) || (off > b.length) || (len < 0) || ((off + len) > b.length) || ((off + len) < 0)) { throw new IndexOutOfBoundsException(); } else if(len == 0) { return 0; } String result = ((PyString) filelike.__getattr__("read") .__call__(new PyInteger(len))).getString(); if(result.length() == 0) { return -1; } System.arraycopy(StringUtil.toBytes(result), 0, b, off, result.length()); return result.length(); }
// in src/org/python/core/FilelikeInputStream.java
public void close() throws IOException { filelike.__getattr__("close").__call__(); }
// in src/org/python/core/PyInstance.java
private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException { in.defaultReadObject(); String module = in.readUTF(); String name = in.readUTF(); /* Check for types and missing members here */ //System.out.println("module: "+module+", "+name); PyObject mod = imp.importName(module.intern(), false); PyClass pyc = (PyClass)mod.__getattr__(name.intern()); instclass = pyc; }
// in src/org/python/core/PyInstance.java
private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException { //System.out.println("writing: "+getClass().getName()); out.defaultWriteObject(); PyObject name = instclass.__findattr__("__module__"); if (!(name instanceof PyString) || name == Py.None) { throw Py.ValueError("Can't find module for class: "+ instclass.__name__); } out.writeUTF(name.toString()); name = instclass.__findattr__("__name__"); if (!(name instanceof PyString) || name == Py.None) { throw Py.ValueError("Can't find module for class with no name"); } out.writeUTF(name.toString()); }
// in src/org/python/core/io/StreamIO.java
private static FileDescriptor getInputFileDescriptor(InputStream stream) throws IOException { if (stream == null) { return null; } if (stream instanceof FileInputStream) { return ((FileInputStream)stream).getFD(); } if (stream instanceof FilterInputStream) { Field inField = null; try { inField = FilterInputStream.class.getDeclaredField("in"); inField.setAccessible(true); return getInputFileDescriptor((InputStream)inField.get(stream)); } catch (Exception e) { // XXX: masking other exceptions } finally { if (inField != null && inField.isAccessible()) { inField.setAccessible(false); } } } return null; }
// in src/org/python/core/io/StreamIO.java
private static FileDescriptor getOutputFileDescriptor(OutputStream stream) throws IOException { if (stream == null) { return null; } if (stream instanceof FileOutputStream) { return ((FileOutputStream)stream).getFD(); } if (stream instanceof FilterOutputStream) { Field outField = null; try { outField = FilterOutputStream.class.getDeclaredField("out"); outField.setAccessible(true); return getOutputFileDescriptor((OutputStream)outField.get(stream)); } catch (Exception e) { // XXX: masking other exceptions } finally { if (outField != null && outField.isAccessible()) { outField.setAccessible(false); } } } return null; }
// in src/org/python/core/io/FileIO.java
private long writeAppend(ByteBuffer[] bufs) throws IOException { long count = 0; int bufCount; for (ByteBuffer buf : bufs) { if (!buf.hasRemaining()) { continue; } if ((bufCount = fileChannel.write(buf, fileChannel.position())) == 0) { break; } count += bufCount; } return count; }
// in src/org/python/core/io/TextIOInputStream.java
Override public int read() throws IOException { String result = textIO.read(1); if (result.length() == 0) { return -1; } return (int)result.charAt(0); }
// in src/org/python/core/io/TextIOInputStream.java
Override public int read(byte[] b, int off, int len) throws IOException { if (b == null) { throw new NullPointerException(); } else if ((off < 0) || (off > b.length) || (len < 0) || ((off + len) > b.length) || ((off + len) < 0)) { throw new IndexOutOfBoundsException(); } else if (len == 0) { return 0; } String result = textIO.read(len); len = result.length(); for (int i = 0; i < len; i++) { b[off + i] = (byte)result.charAt(i); } return len == 0 ? -1 : len; }
// in src/org/python/core/io/TextIOInputStream.java
Override public void close() throws IOException { textIO.close(); }
// in src/org/python/core/io/TextIOInputStream.java
Override public long skip(long n) throws IOException { return textIO.seek(n, 1); }
// in src/org/python/core/PyArray.java
private int fromStream(InputStream is) throws IOException, EOFException { return fromStream(is, is.available() / getStorageSize()); }
// in src/org/python/core/PyArray.java
private int fromStream(InputStream is, int count) throws IOException, EOFException { DataInputStream dis = new DataInputStream(is); // current number of items present int origsize = delegate.getSize(); // position to start inserting into int index = origsize; // create capacity for 'count' items delegate.ensureCapacity(index + count); if (type.isPrimitive()) { switch (typecode.charAt(0)) { case 'z': for (int i = 0; i < count; i++, index++) { Array.setBoolean(data, index, dis.readBoolean()); delegate.size++; } break; case 'b': for (int i = 0; i < count; i++, index++) { Array.setByte(data, index, dis.readByte()); delegate.size++; } break; case 'B': for (int i = 0; i < count; i++, index++) { Array.setShort(data, index, unsignedByte(dis.readByte())); delegate.size++; } break; case 'u': // use 32-bit integers since we want UCS-4 storage for (int i = 0; i < count; i++, index++) { Array.setInt(data, index, dis.readInt()); delegate.size++; } break; case 'c': for (int i = 0; i < count; i++, index++) { Array.setChar(data, index, (char) (dis.readByte() & 0xff)); delegate.size++; } break; case 'h': for (int i = 0; i < count; i++, index++) { Array.setShort(data, index, dis.readShort()); delegate.size++; } break; case 'H': for (int i = 0; i < count; i++, index++) { Array.setInt(data, index, unsignedShort(dis.readShort())); delegate.size++; } break; case 'i': for (int i = 0; i < count; i++, index++) { Array.setInt(data, index, dis.readInt()); delegate.size++; } break; case 'I': for (int i = 0; i < count; i++, index++) { Array.setLong(data, index, unsignedInt(dis.readInt())); delegate.size++; } break; case 'l': for (int i = 0; i < count; i++, index++) { Array.setLong(data, index, dis.readLong()); delegate.size++; } break; case 'L': // faking it for (int i = 0; i < count; i++, index++) { Array.setLong(data, index, dis.readLong()); delegate.size++; } break; case 'f': for (int i = 0; i < count; i++, index++) { Array.setFloat(data, index, dis.readFloat()); delegate.size++; } break; case 'd': for (int i = 0; i < count; i++, index++) { Array.setDouble(data, index, dis.readDouble()); delegate.size++; } break; } } dis.close(); return (index - origsize); }
// in src/org/python/core/PyArray.java
private int toStream(OutputStream os) throws IOException { DataOutputStream dos = new DataOutputStream(os); switch (typecode.charAt(0)) { case 'z': for(int i = 0; i < delegate.getSize(); i++) dos.writeBoolean(Array.getBoolean(data, i)); break; case 'b': for(int i = 0; i < delegate.getSize(); i++) dos.writeByte(Array.getByte(data, i)); break; case 'B': for(int i = 0; i < delegate.getSize(); i++) dos.writeByte(signedByte(Array.getShort(data, i))); break; case 'u': // use 32-bit integers since we want UCS-4 storage for(int i = 0; i < delegate.getSize(); i++) dos.writeInt(Array.getInt(data, i)); break; case 'c': for(int i = 0; i < delegate.getSize(); i++) dos.writeByte((byte)Array.getChar(data, i)); break; case 'h': for(int i = 0; i < delegate.getSize(); i++) dos.writeShort(Array.getShort(data, i)); break; case 'H': for(int i = 0; i < delegate.getSize(); i++) dos.writeShort(signedShort(Array.getInt(data, i))); break; case 'i': for(int i = 0; i < delegate.getSize(); i++) dos.writeInt(Array.getInt(data, i)); break; case 'I': for(int i = 0; i < delegate.getSize(); i++) dos.writeInt(signedInt(Array.getLong(data, i))); break; case 'l': for(int i = 0; i < delegate.getSize(); i++) dos.writeLong(Array.getLong(data, i)); break; case 'L': // faking it for(int i = 0; i < delegate.getSize(); i++) dos.writeLong(Array.getLong(data, i)); break; case 'f': for(int i = 0; i < delegate.getSize(); i++) dos.writeFloat(Array.getFloat(data, i)); break; case 'd': for(int i = 0; i < delegate.getSize(); i++) dos.writeDouble(Array.getDouble(data, i)); break; } return dos.size(); }
// in src/org/python/core/PyJavaType.java
private static <T> T cloneX(T x) throws IOException, ClassNotFoundException { ByteArrayOutputStream bout = new ByteArrayOutputStream(); CloneOutput cout = new CloneOutput(bout); cout.writeObject(x); byte[] bytes = bout.toByteArray(); ByteArrayInputStream bin = new ByteArrayInputStream(bytes); CloneInput cin = new CloneInput(bin, cout); @SuppressWarnings("unchecked") // thanks to Bas de Bakker for the tip! T clone = (T) cin.readObject(); return clone; }
// in src/org/python/core/PyJavaType.java
Override protected Class<?> resolveClass(ObjectStreamClass osc) throws IOException, ClassNotFoundException { Class<?> c = output.classQueue.poll(); String expected = osc.getName(); String found = (c == null) ? null : c.getName(); if (!expected.equals(found)) { throw new InvalidClassException("Classes desynchronized: " + "found " + found + " when expecting " + expected); } return c; }
// in src/org/python/core/PyJavaType.java
Override protected Class<?> resolveProxyClass(String[] interfaceNames) throws IOException, ClassNotFoundException { return output.classQueue.poll(); }
// in src/org/python/core/ParserFacade.java
private static ExpectedEncodingBufferedReader prepBufReader(Reader reader, CompilerFlags cflags, String filename) throws IOException { cflags.source_is_utf8 = true; cflags.encoding = "utf-8"; BufferedReader bufferedReader = new BufferedReader(reader); bufferedReader.mark(MARK_LIMIT); if (findEncoding(bufferedReader) != null) throw new ParseException("encoding declaration in Unicode string"); bufferedReader.reset(); return new ExpectedEncodingBufferedReader(bufferedReader, null); }
// in src/org/python/core/ParserFacade.java
private static ExpectedEncodingBufferedReader prepBufReader(InputStream input, CompilerFlags cflags, String filename, boolean fromString) throws IOException { return prepBufReader(input, cflags, filename, fromString, true); }
// in src/org/python/core/ParserFacade.java
private static ExpectedEncodingBufferedReader prepBufReader(InputStream input, CompilerFlags cflags, String filename, boolean fromString, boolean universalNewlines) throws IOException { input = new BufferedInputStream(input); boolean bom = adjustForBOM(input); String encoding = readEncoding(input); if (encoding == null) { if (bom) { encoding = "utf-8"; } else if (cflags != null && cflags.encoding != null) { encoding = cflags.encoding; } } if (cflags.source_is_utf8) { if (encoding != null) { throw new ParseException("encoding declaration in Unicode string"); } encoding = "utf-8"; } cflags.encoding = encoding; if (universalNewlines) { // Enable universal newlines mode on the input StreamIO rawIO = new StreamIO(input, true); org.python.core.io.BufferedReader bufferedIO = new org.python.core.io.BufferedReader(rawIO, 0); UniversalIOWrapper textIO = new UniversalIOWrapper(bufferedIO); input = new TextIOInputStream(textIO); } Charset cs; try { // Use ascii for the raw bytes when no encoding was specified if (encoding == null) { if (fromString) { cs = Charset.forName("ISO-8859-1"); } else { cs = Charset.forName("ascii"); } } else { cs = Charset.forName(encoding); } } catch (UnsupportedCharsetException exc) { throw new PySyntaxError("Unknown encoding: " + encoding, 1, 0, "", filename); } CharsetDecoder dec = cs.newDecoder(); dec.onMalformedInput(CodingErrorAction.REPORT); dec.onUnmappableCharacter(CodingErrorAction.REPORT); return new ExpectedEncodingBufferedReader(new InputStreamReader(input, dec), encoding); }
// in src/org/python/core/ParserFacade.java
private static ExpectedEncodingBufferedReader prepBufReader(String string, CompilerFlags cflags, String filename) throws IOException { if (cflags.source_is_utf8) return prepBufReader(new StringReader(string), cflags, filename); byte[] stringBytes = StringUtil.toBytes(string); return prepBufReader(new ByteArrayInputStream(stringBytes), cflags, filename, true, false); }
// in src/org/python/core/ParserFacade.java
private static boolean adjustForBOM(InputStream stream) throws IOException { stream.mark(3); int ch = stream.read(); if (ch == 0xEF) { if (stream.read() != 0xBB) { throw new ParseException("Incomplete BOM at beginning of file"); } if (stream.read() != 0xBF) { throw new ParseException("Incomplete BOM at beginning of file"); } return true; } stream.reset(); return false; }
// in src/org/python/core/ParserFacade.java
private static String readEncoding(InputStream stream) throws IOException { stream.mark(MARK_LIMIT); String encoding = null; BufferedReader br = new BufferedReader(new InputStreamReader(stream, "ISO-8859-1"), 512); encoding = findEncoding(br); // XXX: reset() can still raise an IOException if a line exceeds our large mark // limit stream.reset(); return encodingMap(encoding); }
// in src/org/python/core/ParserFacade.java
private static String findEncoding(BufferedReader br) throws IOException { String encoding = null; for (int i = 0; i < 2; i++) { String strLine = br.readLine(); if (strLine == null) { break; } String result = matchEncoding(strLine); if (result != null) { encoding = result; break; } } return encoding; }
// in src/org/python/core/SyspathArchive.java
InputStream getInputStream(ZipEntry entry) throws IOException { InputStream istream = this.zipFile.getInputStream(entry); // Some jdk1.1 VMs have problems with detecting the end of a zip // stream correctly. If you read beyond the end, you get a // EOFException("Unexpected end of ZLIB input stream"), not a // -1 return value. // XXX: Since 1.1 is no longer supported, we should review the usefulness // of this workaround. // As a workaround we read the file fully here, but only getSize() // bytes. int len = (int) entry.getSize(); byte[] buffer = new byte[len]; int off = 0; while (len > 0) { int l = istream.read(buffer, off, buffer.length - off); if (l < 0) return null; off += l; len -= l; } istream.close(); return new ByteArrayInputStream(buffer); }
// in src/org/python/core/imp.java
public static byte[] readCode(String name, InputStream fp, boolean testing) throws IOException { return readCode(name, fp, testing, NO_MTIME); }
// in src/org/python/core/imp.java
public static byte[] readCode(String name, InputStream fp, boolean testing, long mtime) throws IOException { byte[] data = readBytes(fp); int api; AnnotationReader ar = new AnnotationReader(data); api = ar.getVersion(); if (api != APIVersion) { if (testing) { return null; } else { throw Py.ImportError("invalid api version(" + api + " != " + APIVersion + ") in: " + name); } } if (testing && mtime != NO_MTIME) { long time = ar.getMTime(); if (mtime != time) { return null; } } return data; }
// in src/org/python/core/util/FileUtil.java
public static byte[] readBytes(InputStream in) throws IOException { final int bufsize = 8192; // nice buffer size used in JDK byte[] buf = new byte[bufsize]; ByteArrayOutputStream out = new ByteArrayOutputStream(bufsize); int count; while (true) { count = in.read(buf, 0, bufsize); if (count < 0) { break; } out.write(buf, 0, count); } return out.toByteArray(); }
// in src/org/python/core/packagecache/PackageManager.java
static protected int checkAccess(java.io.InputStream cstream) throws java.io.IOException { java.io.DataInputStream istream = new java.io.DataInputStream(cstream); try { int magic = istream.readInt(); if (magic != 0xcafebabe) { return -1; } } catch (EOFException eof) { //Empty or 1 byte file. return -1; } //int minor = istream.readShort(); //int major = istream.readShort(); // Check versions??? // System.out.println("magic: "+magic+", "+major+", "+minor); int nconstants = istream.readShort(); for (int i = 1; i < nconstants; i++) { int cid = istream.readByte(); // System.out.println(""+i+" : "+cid); switch (cid) { case 7: istream.skipBytes(2); break; case 9: case 10: case 11: istream.skipBytes(4); break; case 8: istream.skipBytes(2); break; case 3: case 4: istream.skipBytes(4); break; case 5: case 6: istream.skipBytes(8); i++; break; case 12: istream.skipBytes(4); break; case 1: // System.out.println("utf: "+istream.readUTF()+";"); int slength = istream.readUnsignedShort(); istream.skipBytes(slength); break; default: // System.err.println("unexpected cid: "+cid+", "+i+", "+ // nconstants); // for (int j=0; j<10; j++) // System.err.print(", "+istream.readByte()); // System.err.println(); return -1; } } return istream.readShort(); }
// in src/org/python/core/packagecache/CachedJarsPackageManager.java
private void addZipEntry(Map<String, List<String>[]> zipPackages, ZipEntry entry, ZipInputStream zip) throws IOException { String name = entry.getName(); // System.err.println("entry: "+name); if (!name.endsWith(".class")) { return; } char sep = '/'; int breakPoint = name.lastIndexOf(sep); if (breakPoint == -1) { breakPoint = name.lastIndexOf('\\'); sep = '\\'; } String packageName; if (breakPoint == -1) { packageName = ""; } else { packageName = name.substring(0, breakPoint).replace(sep, '.'); } String className = name.substring(breakPoint + 1, name.length() - 6); if (filterByName(className, false)) { return; } List<String>[] vec = zipPackages.get(packageName); if (vec == null) { vec = createGenericStringListArray(); zipPackages.put(packageName, vec); } int access = checkAccess(zip); if ((access != -1) && !filterByAccess(name, access)) { vec[0].add(className); } else { vec[1].add(className); } }
// in src/org/python/core/packagecache/CachedJarsPackageManager.java
private Map<String, String> getZipPackages(InputStream jarin) throws IOException { Map<String, List<String>[]> zipPackages = Generic.map(); ZipInputStream zip = new ZipInputStream(jarin); ZipEntry entry; while ((entry = zip.getNextEntry()) != null) { addZipEntry(zipPackages, entry, zip); zip.closeEntry(); } // Turn each vector into a comma-separated String Map<String, String> transformed = Generic.map(); for (Entry<String,List<String>[]> kv : zipPackages.entrySet()) { List<String>[] vec = kv.getValue(); String classes = listToString(vec[0]); if (vec[1].size() > 0) { classes += '@' + listToString(vec[1]); } transformed.put(kv.getKey(), classes); } return transformed; }
// in src/org/python/core/packagecache/CachedJarsPackageManager.java
protected DataInputStream inOpenIndex() throws IOException { File indexFile = new File(this.cachedir, "packages.idx"); if (!indexFile.exists()) { return null; } DataInputStream istream = new DataInputStream(new BufferedInputStream( new FileInputStream(indexFile))); return istream; }
// in src/org/python/core/packagecache/CachedJarsPackageManager.java
protected DataOutputStream outOpenIndex() throws IOException { File indexFile = new File(this.cachedir, "packages.idx"); return new DataOutputStream(new BufferedOutputStream( new FileOutputStream(indexFile))); }
// in src/org/python/core/packagecache/CachedJarsPackageManager.java
protected DataInputStream inOpenCacheFile(String cachefile) throws IOException { return new DataInputStream(new BufferedInputStream(new FileInputStream( cachefile))); }
// in src/org/python/core/packagecache/CachedJarsPackageManager.java
protected DataOutputStream outCreateCacheFile(JarXEntry entry, boolean create) throws IOException { File cachefile = null; if (create) { int index = 1; String suffix = ""; String jarname = entry.cachefile; while (true) { cachefile = new File(this.cachedir, jarname + suffix + ".pkc"); // System.err.println("try cachefile: "+cachefile); if (!cachefile.exists()) { break; } suffix = "$" + index; index += 1; } entry.cachefile = cachefile.getCanonicalPath(); } else cachefile = new File(entry.cachefile); return new DataOutputStream(new BufferedOutputStream( new FileOutputStream(cachefile))); }
// in src/org/python/util/PyFilter.java
public void doFilter(ServletRequest request, ServletResponse response, FilterChain chain) throws IOException, ServletException { request.setAttribute("pyfilter", this); getFilter().doFilter(request, response, chain); }
// in src/org/python/util/PyFilter.java
private Filter getFilter() throws ServletException, IOException { if (cached == null || source.lastModified() > loadedMtime) { return loadFilter(); } return cached; }
// in src/org/python/util/PyFilter.java
private Filter loadFilter() throws ServletException, IOException { loadedMtime = source.lastModified(); cached = PyServlet.createInstance(interp, source, Filter.class); try { cached.init(config); } catch (PyException e) { throw new ServletException(e); } return cached; }
// in src/org/python/util/PythonObjectInputStream.java
protected Class<?> resolveClass(ObjectStreamClass v) throws IOException, ClassNotFoundException { String clsName = v.getName(); if (clsName.startsWith("org.python.proxies")) { int idx = clsName.lastIndexOf('$'); if (idx > 19) { clsName = clsName.substring(19, idx); } idx = clsName.indexOf('$'); if (idx >= 0) { String mod = clsName.substring(0, idx); clsName = clsName.substring(idx + 1); PyObject module = importModule(mod); PyType pycls = (PyType)module.__getattr__(clsName.intern()); return pycls.getProxyType(); } } try { return super.resolveClass(v); } catch (ClassNotFoundException exc) { PyObject m = importModule(clsName); Object cls = m.__tojava__(Class.class); if (cls != null && cls != Py.NoConversion) { return (Class<?>)cls; } throw exc; } }
// in src/org/python/util/PyServlet.java
Override public void service(ServletRequest req, ServletResponse res) throws ServletException, IOException { req.setAttribute("pyservlet", this); String spath = (String) req.getAttribute("javax.servlet.include.servlet_path"); if (spath == null) { spath = ((HttpServletRequest)req).getServletPath(); if (spath == null || spath.length() == 0) { // Servlet 2.1 puts the path of an extension-matched servlet in PathInfo. spath = ((HttpServletRequest)req).getPathInfo(); } } String rpath = getServletContext().getRealPath(spath); getServlet(rpath).service(req, res); }
// in src/org/python/util/PyServlet.java
private synchronized HttpServlet getServlet(String path) throws ServletException, IOException { CacheEntry entry = cache.get(path); if (entry == null || new File(path).lastModified() > entry.date) { return loadServlet(path); } return entry.servlet; }
// in src/org/python/util/PyServlet.java
private HttpServlet loadServlet(String path) throws ServletException, IOException { File file = new File(path); HttpServlet servlet = createInstance(interp, file, HttpServlet.class); try { servlet.init(getServletConfig()); } catch (PyException e) { throw new ServletException(e); } cache.put(path, new CacheEntry(servlet, file.lastModified())); return servlet; }
// in src/org/python/util/Generic.java
private void readObject(ObjectInputStream in) throws IOException, ClassNotFoundException { in.defaultReadObject(); keySet = map.keySet(); }
93
            
// in src/com/ziclix/python/sql/DataHandler.java
catch (IOException ioe) { throw zxJDBC.makeException(ioe); }
// in src/com/ziclix/python/sql/DataHandler.java
catch (IOException ioe) { throw zxJDBC.makeException(ioe); }
// in src/com/ziclix/python/sql/DataHandler.java
catch (IOException ioe) { throw zxJDBC.makeException(ioe); }
// in src/com/ziclix/python/sql/DataHandler.java
catch (IOException ioe) { throw zxJDBC.makeException(ioe); }
// in src/com/xhaus/modjy/ModjyJServlet.java
catch (IOException iox) { System.err.println("IOException: " + iox.toString()); }
// in src/org/python/indexer/AstCache.java
catch (IOException iox) { fine(filename + ": " + iox); return null; }
// in src/org/python/expose/generate/ExposeTask.java
catch (IOException e) { throw new BuildException("Unable to read '" + f + "' to expose it", e); }
// in src/org/python/expose/generate/ExposeTask.java
catch (IOException e) { throw new BuildException("Unable to write to '" + dest + "'", e); }
// in src/org/python/expose/generate/ExposeTask.java
catch (IOException e) { // Le sigh... }
// in src/org/python/Version.java
catch (IOException ioe) { System.err.println("There was a problem loading ".concat(versionProperties) .concat(":")); ioe.printStackTrace(); }
// in src/org/python/Version.java
catch (IOException ioe) { // ok }
// in src/org/python/modules/zipimport/zipimporter.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/modules/zipimport/zipimporter.java
catch (IOException ioe) { throw zipimport.ZipImportError("zipimport: can not open file: " + archive); }
// in src/org/python/modules/zipimport/zipimporter.java
catch (IOException ioe) { Py.writeDebug("import", "zipimporter.getDataStream exception: " + ioe.toString()); throw zipimport.ZipImportError("zipimport: can not open file: " + archive); }
// in src/org/python/modules/zipimport/zipimporter.java
catch (IOException ioe) { throw zipimport.ZipImportError(String.format("can't read Zip file: '%s'", archive)); }
// in src/org/python/modules/zipimport/zipimporter.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/modules/zipimport/zipimporter.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/modules/posix/PosixModule.java
catch (IOException ioe) { throw Py.OSError(ioe); }
// in src/org/python/modules/posix/PosixModule.java
catch (IOException ioe) { throw Py.OSError(ioe); }
// in src/org/python/modules/posix/PosixModule.java
catch (IOException ioe) { throw Py.OSError(ioe); }
// in src/org/python/modules/random/PyRandom.java
catch (IOException e) { throw Py.SystemError("state vector invalid: "+e.getMessage()); }
// in src/org/python/modules/random/PyRandom.java
catch (IOException e) { throw Py.SystemError("creation of state vector failed: "+ e.getMessage()); }
// in src/org/python/modules/imp.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/SyspathJavaLoader.java
catch (IOException exc) { return null; }
// in src/org/python/core/SyspathJavaLoader.java
catch (IOException e) { // Nothing to do }
// in src/org/python/core/SyspathJavaLoader.java
catch (IOException e) { return null; }
// in src/org/python/core/PySystemState.java
catch (IOException ioe) { return rootFile.getAbsolutePath(); }
// in src/org/python/core/PySystemState.java
catch (IOException e) { System.err.println("couldn't open registry file: " + file.toString()); }
// in src/org/python/core/PySystemState.java
catch (IOException e) { Py.writeWarning("initializer", "Failed reading '" + INITIALIZER_SERVICE + "' from " + initializerClassLoader); e.printStackTrace(System.err); return false; }
// in src/org/python/core/PySystemState.java
catch (IOException ioe) { executableFile = executableFile.getAbsoluteFile(); }
// in src/org/python/core/PySystemState.java
catch (IOException ioe) { }
// in src/org/python/core/PySystemState.java
catch (IOException e) { }
// in src/org/python/core/PyFileWriter.java
catch (IOException e) { throw Py.IOError(e); }
// in src/org/python/core/PyFileWriter.java
catch (IOException e) { throw Py.IOError(e); }
// in src/org/python/core/PyFileWriter.java
catch (IOException e) { throw Py.IOError(e); }
// in src/org/python/core/io/StreamIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/StreamIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/StreamIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/StreamIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/StreamIO.java
catch (IOException e) { return false; }
// in src/org/python/core/io/SocketIOBase.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/FileIO.java
catch (IOException ioe) { // On Solaris and Linux, ftruncate(3C) returns EINVAL if not a regular // file whereas, e.g., open(os.devnull, "w") works. Because we have to // simulate the "w" mode in Java, we suppress the exception. // Likewise Windows returns ERROR_INVALID_FUNCTION in that case and // ERROR_INVALID_HANDLE on ttys. Identifying those by the IOException // message is tedious as their messages are localized, so we suppress them // all =[ if (Platform.IS_WINDOWS || ((Platform.IS_SOLARIS || Platform.IS_LINUX) && Errno.EINVAL.description().equals(ioe.getMessage()))) { return; } throw Py.IOError(ioe); }
// in src/org/python/core/io/FileIO.java
catch (IOException e) { return false; }
// in src/org/python/core/io/FileIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/FileIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/FileIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/FileIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/FileIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/FileIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/FileIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/FileIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/FileIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/DatagramSocketIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/DatagramSocketIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/DatagramSocketIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/DatagramSocketIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/SocketIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/SocketIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/SocketIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/SocketIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/PyArray.java
catch(IOException e) { // discard anything successfully loaded delegate.setSize(origsize); throw Py.IOError(e); }
// in src/org/python/core/PyArray.java
catch(IOException e) { throw Py.IOError(e); }
// in src/org/python/core/PyFileReader.java
catch (IOException e) { throw Py.IOError(e); }
// in src/org/python/core/PyFileReader.java
catch (IOException e) { throw Py.IOError(e); }
// in src/org/python/core/PyFileReader.java
catch (IOException e) { throw Py.IOError(e); }
// in src/org/python/core/PyFileReader.java
catch (IOException e) { throw Py.IOError(e); }
// in src/org/python/core/__builtin__.java
catch (IOException e) { throw Py.IOError(e); }
// in src/org/python/core/ParserFacade.java
catch (IOException ioe) { }
// in src/org/python/core/ParserFacade.java
catch (IOException e) { reader = null; }
// in src/org/python/core/ParserFacade.java
catch (IOException i) { // XXX: Log the error? }
// in src/org/python/core/ClasspathPyImporter.java
catch (IOException e) { throw Py.JavaError(e); }
// in src/org/python/core/imp.java
catch(IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/imp.java
catch(IOException e) { throw Py.IOError(e); }
// in src/org/python/core/imp.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/imp.java
catch (IOException ioe) { if (!testing) { throw Py.ImportError(ioe.getMessage() + "[name=" + name + ", source=" + sourceName + ", compiled=" + compiledName + "]"); } }
// in src/org/python/core/imp.java
catch(IOException exc) { // If we can't write the cache file, just log and continue Py.writeDebug(IMPORT_LOG, "Unable to write to source cache file '" + compiledFilename + "' due to " + exc); return null; }
// in src/org/python/core/imp.java
catch(IOException e) { Py.writeDebug(IMPORT_LOG, "Unable to close source cache file '" + compiledFilename + "' due to " + e); }
// in src/org/python/core/imp.java
catch (IOException exc) { return false; }
// in src/org/python/core/util/importer.java
catch (IOException ioe) { throw Py.ImportError(ioe.getMessage() + "[path=" + fullSearchPath + "]"); }
// in src/org/python/core/packagecache/PathPackageManager.java
catch (IOException e) { continue; }
// in src/org/python/core/packagecache/PathPackageManager.java
catch (IOException e) { warning("skipping bad directory, '" + dir + "'"); }
// in src/org/python/core/packagecache/CachedJarsPackageManager.java
catch (IOException ioe) { // silently skip any bad directories warning("skipping bad jar, '" + (jarfile != null ? jarfile.toString() : jarurl.toString()) + "'"); }
// in src/org/python/core/packagecache/CachedJarsPackageManager.java
catch (IOException ioe) { // if (cachefile.exists()) cachefile.delete(); return null; }
// in src/org/python/core/packagecache/CachedJarsPackageManager.java
catch (IOException ioe) { warning("can't write cache file for '" + jarcanon + "'"); }
// in src/org/python/core/packagecache/CachedJarsPackageManager.java
catch (IOException ioe) { warning("invalid index file"); }
// in src/org/python/core/packagecache/CachedJarsPackageManager.java
catch (IOException ioe) { warning("can't write index file"); }
// in src/org/python/util/TemplateAntTask.java
catch(IOException e2) { throw new BuildException(e2.toString(), e2); }
// in src/org/python/util/JLineConsole.java
catch (IOException e) { // oh well, no history from file }
// in src/org/python/util/JLineConsole.java
catch (IOException e) { throw new RuntimeException(e); }
// in src/org/python/util/JLineConsole.java
catch (IOException ioe) { if (!fromSuspend(ioe)) { throw Py.IOError(ioe); } // Hopefully an IOException caused by ctrl-z (seems only BSD throws this). // Must reset jline to continue try { reader.getTerminal().initializeTerminal(); } catch (Exception e) { throw Py.IOError(e.getMessage()); } // Don't redisplay the prompt promptString = ""; }
// in src/org/python/util/jython.java
catch (IOException e) { throw Py.IOError(e); }
// in src/org/python/util/jython.java
catch (IOException ioe) { path = new File(opts.filename).getAbsoluteFile().getParent(); }
// in src/org/python/util/ReadlineConsole.java
catch(IOException ioe) { throw new PyException(Py.IOError); }
63
            
// in src/com/ziclix/python/sql/DataHandler.java
catch (IOException ioe) { throw zxJDBC.makeException(ioe); }
// in src/com/ziclix/python/sql/DataHandler.java
catch (IOException ioe) { throw zxJDBC.makeException(ioe); }
// in src/com/ziclix/python/sql/DataHandler.java
catch (IOException ioe) { throw zxJDBC.makeException(ioe); }
// in src/com/ziclix/python/sql/DataHandler.java
catch (IOException ioe) { throw zxJDBC.makeException(ioe); }
// in src/org/python/expose/generate/ExposeTask.java
catch (IOException e) { throw new BuildException("Unable to read '" + f + "' to expose it", e); }
// in src/org/python/expose/generate/ExposeTask.java
catch (IOException e) { throw new BuildException("Unable to write to '" + dest + "'", e); }
// in src/org/python/modules/zipimport/zipimporter.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/modules/zipimport/zipimporter.java
catch (IOException ioe) { throw zipimport.ZipImportError("zipimport: can not open file: " + archive); }
// in src/org/python/modules/zipimport/zipimporter.java
catch (IOException ioe) { Py.writeDebug("import", "zipimporter.getDataStream exception: " + ioe.toString()); throw zipimport.ZipImportError("zipimport: can not open file: " + archive); }
// in src/org/python/modules/zipimport/zipimporter.java
catch (IOException ioe) { throw zipimport.ZipImportError(String.format("can't read Zip file: '%s'", archive)); }
// in src/org/python/modules/zipimport/zipimporter.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/modules/zipimport/zipimporter.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/modules/posix/PosixModule.java
catch (IOException ioe) { throw Py.OSError(ioe); }
// in src/org/python/modules/posix/PosixModule.java
catch (IOException ioe) { throw Py.OSError(ioe); }
// in src/org/python/modules/posix/PosixModule.java
catch (IOException ioe) { throw Py.OSError(ioe); }
// in src/org/python/modules/random/PyRandom.java
catch (IOException e) { throw Py.SystemError("state vector invalid: "+e.getMessage()); }
// in src/org/python/modules/random/PyRandom.java
catch (IOException e) { throw Py.SystemError("creation of state vector failed: "+ e.getMessage()); }
// in src/org/python/modules/imp.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/PyFileWriter.java
catch (IOException e) { throw Py.IOError(e); }
// in src/org/python/core/PyFileWriter.java
catch (IOException e) { throw Py.IOError(e); }
// in src/org/python/core/PyFileWriter.java
catch (IOException e) { throw Py.IOError(e); }
// in src/org/python/core/io/StreamIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/StreamIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/StreamIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/StreamIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/SocketIOBase.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/FileIO.java
catch (IOException ioe) { // On Solaris and Linux, ftruncate(3C) returns EINVAL if not a regular // file whereas, e.g., open(os.devnull, "w") works. Because we have to // simulate the "w" mode in Java, we suppress the exception. // Likewise Windows returns ERROR_INVALID_FUNCTION in that case and // ERROR_INVALID_HANDLE on ttys. Identifying those by the IOException // message is tedious as their messages are localized, so we suppress them // all =[ if (Platform.IS_WINDOWS || ((Platform.IS_SOLARIS || Platform.IS_LINUX) && Errno.EINVAL.description().equals(ioe.getMessage()))) { return; } throw Py.IOError(ioe); }
// in src/org/python/core/io/FileIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/FileIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/FileIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/FileIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/FileIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/FileIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/FileIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/FileIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/FileIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/DatagramSocketIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/DatagramSocketIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/DatagramSocketIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/DatagramSocketIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/SocketIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/SocketIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/SocketIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/io/SocketIO.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/PyArray.java
catch(IOException e) { // discard anything successfully loaded delegate.setSize(origsize); throw Py.IOError(e); }
// in src/org/python/core/PyArray.java
catch(IOException e) { throw Py.IOError(e); }
// in src/org/python/core/PyFileReader.java
catch (IOException e) { throw Py.IOError(e); }
// in src/org/python/core/PyFileReader.java
catch (IOException e) { throw Py.IOError(e); }
// in src/org/python/core/PyFileReader.java
catch (IOException e) { throw Py.IOError(e); }
// in src/org/python/core/PyFileReader.java
catch (IOException e) { throw Py.IOError(e); }
// in src/org/python/core/__builtin__.java
catch (IOException e) { throw Py.IOError(e); }
// in src/org/python/core/ClasspathPyImporter.java
catch (IOException e) { throw Py.JavaError(e); }
// in src/org/python/core/imp.java
catch(IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/imp.java
catch(IOException e) { throw Py.IOError(e); }
// in src/org/python/core/imp.java
catch (IOException ioe) { throw Py.IOError(ioe); }
// in src/org/python/core/imp.java
catch (IOException ioe) { if (!testing) { throw Py.ImportError(ioe.getMessage() + "[name=" + name + ", source=" + sourceName + ", compiled=" + compiledName + "]"); } }
// in src/org/python/core/util/importer.java
catch (IOException ioe) { throw Py.ImportError(ioe.getMessage() + "[path=" + fullSearchPath + "]"); }
// in src/org/python/util/TemplateAntTask.java
catch(IOException e2) { throw new BuildException(e2.toString(), e2); }
// in src/org/python/util/JLineConsole.java
catch (IOException e) { throw new RuntimeException(e); }
// in src/org/python/util/JLineConsole.java
catch (IOException ioe) { if (!fromSuspend(ioe)) { throw Py.IOError(ioe); } // Hopefully an IOException caused by ctrl-z (seems only BSD throws this). // Must reset jline to continue try { reader.getTerminal().initializeTerminal(); } catch (Exception e) { throw Py.IOError(e.getMessage()); } // Don't redisplay the prompt promptString = ""; }
// in src/org/python/util/jython.java
catch (IOException e) { throw Py.IOError(e); }
// in src/org/python/util/ReadlineConsole.java
catch(IOException ioe) { throw new PyException(Py.IOError); }
2
unknown (Lib) IllegalAccessException 0 0 2
            
// in src/org/python/core/CodeLoader.java
public static PyCode loadCode(Class<?> cls, String name, String filename) throws SecurityException, NoSuchMethodException, IllegalArgumentException, IllegalAccessException, InvocationTargetException { Method getBootstrap = cls.getMethod(GET_BOOTSTRAP_METHOD_NAME); CodeBootstrap bootstrap = (CodeBootstrap) getBootstrap.invoke(null); return loadCode(bootstrap, name, filename); }
// in src/org/python/core/CodeLoader.java
public static PyCode loadCode(Class<?> cls) throws SecurityException, IllegalArgumentException, NoSuchMethodException, IllegalAccessException, InvocationTargetException { return loadCode(cls, null, null); }
7
            
// in src/com/ziclix/python/sql/connect/Connectx.java
catch (IllegalAccessException e) { throw zxJDBC.makeException("illegal access for " + exceptionMsg); }
// in src/com/ziclix/python/sql/connect/Connectx.java
catch (NoSuchMethodException e) { Class<?> primitive = null; try { Field f = valueClass.getField("TYPE"); primitive = (Class<?>) f.get(valueClass); } catch (NoSuchFieldException ex) { } catch (IllegalAccessException ex) { } catch (ClassCastException ex) { } if (primitive != null && primitive.isPrimitive()) { return getMethod(srcClass, methodName, primitive); } }
// in src/com/ziclix/python/sql/connect/Connectx.java
catch (IllegalAccessException ex) { }
// in src/com/ziclix/python/sql/connect/Lookup.java
catch (IllegalAccessException e) { throw zxJDBC.makeException(zxJDBC.ProgrammingError, e); }
// in src/org/python/core/PyReflectedField.java
catch (IllegalAccessException exc) { throw Py.JavaError(exc); }
// in src/org/python/core/PyReflectedField.java
catch (IllegalAccessException exc) { throw Py.JavaError(exc); }
// in src/org/python/core/PyJavaType.java
catch (IllegalAccessException e) { throw Py.JavaError(e); }
// in src/org/python/core/imp.java
catch (IllegalAccessException e) { throw Py.JavaError(e); }
6
            
// in src/com/ziclix/python/sql/connect/Connectx.java
catch (IllegalAccessException e) { throw zxJDBC.makeException("illegal access for " + exceptionMsg); }
// in src/com/ziclix/python/sql/connect/Lookup.java
catch (IllegalAccessException e) { throw zxJDBC.makeException(zxJDBC.ProgrammingError, e); }
// in src/org/python/core/PyReflectedField.java
catch (IllegalAccessException exc) { throw Py.JavaError(exc); }
// in src/org/python/core/PyReflectedField.java
catch (IllegalAccessException exc) { throw Py.JavaError(exc); }
// in src/org/python/core/PyJavaType.java
catch (IllegalAccessException e) { throw Py.JavaError(e); }
// in src/org/python/core/imp.java
catch (IllegalAccessException e) { throw Py.JavaError(e); }
0
runtime (Lib) IllegalArgumentException 61
            
// in src/org/python/indexer/Indexer.java
public void setLogger(Logger logger) { if (logger == null) { throw new IllegalArgumentException("null logger param"); } logger = logger; }
// in src/org/python/indexer/Indexer.java
public NBinding putBinding(NBinding b) { if (b == null) { throw new IllegalArgumentException("null binding arg"); } String qname = b.getQname(); if (qname == null || qname.length() == 0) { throw new IllegalArgumentException("Null/empty qname: " + b); } NBinding existing = allBindings.get(qname); if (existing == b) { return b; } if (existing != null) { duplicateBindingFailure(b, existing); // A bad edge case was triggered by an __init__.py that defined a // "Parser" binding (type unknown), and there was a Parser.py in the // same directory. Loading Parser.py resulted in infinite recursion. // // XXX: need to revisit this logic. It seems that bindings made in // __init__.py probably (?) ought to have __init__ in their qnames // to avoid dup-binding conflicts. The Indexer module table also // probably ought not be a normal scope -- it's different enough that // overloading it to handle modules is making the logic rather twisty. if (b.getKind() == NBinding.Kind.MODULE) { return b; } return existing; } allBindings.put(qname, b); return b; }
// in src/org/python/indexer/Outliner.java
public void setQname(String qname) { if (qname == null) { throw new IllegalArgumentException("qname param cannot be null"); } this.qname = qname; }
// in src/org/python/indexer/Outliner.java
public void setKind(NBinding.Kind kind) { if (kind == null) { throw new IllegalArgumentException("kind param cannot be null"); } this.kind = kind; }
// in src/org/python/indexer/types/NUnionType.java
public void addType(NType t) { if (t == null) { throw new IllegalArgumentException("null type"); } if (t.isUnionType()) { types.addAll(t.asUnionType().types); } else { types.add(t); } }
// in src/org/python/indexer/ast/NAttribute.java
public void setAttr(NName attr) { if (attr == null) { throw new IllegalArgumentException("param cannot be null"); } this.attr = attr; }
// in src/org/python/indexer/ast/NAttribute.java
public void setTarget(NNode target) { if (target == null) { throw new IllegalArgumentException("param cannot be null"); } this.target = target; }
// in src/org/python/indexer/ast/NNode.java
public NType setType(NType newType) { if (newType == null) { throw new IllegalArgumentException(); } return type = newType; }
// in src/org/python/indexer/ast/NNode.java
public NType addType(NType newType) { if (newType == null) { throw new IllegalArgumentException(); } return type = NUnionType.union(getType(), newType); }
// in src/org/python/indexer/AstCache.java
public NModule getAST(String path) throws Exception { if (path == null) throw new IllegalArgumentException("null path"); return fetch(path); }
// in src/org/python/indexer/AstCache.java
public NModule getAST(String path, String contents) throws Exception { if (path == null) throw new IllegalArgumentException("null path"); if (contents == null) throw new IllegalArgumentException("null contents"); // Cache stores null value if the parse failed. if (cache.containsKey(path)) { return cache.get(path); } NModule mod = null; try { mod = parse(path, contents); if (mod != null) { mod.setFileAndMD5(path, Util.getMD5(contents.getBytes("UTF-8"))); } } finally { cache.put(path, mod); // may be null } return mod; }
// in src/org/python/indexer/Scope.java
public NBinding put(String id, NNode loc, NType type, NBinding.Kind kind) { if (type == null) { throw new IllegalArgumentException("Null type: id=" + id + ", loc=" + loc); } NBinding b = lookupScope(id); return insertOrUpdate(b, id, loc, type, kind); }
// in src/org/python/indexer/Scope.java
public NBinding putAttr(String id, NNode loc, NType type, NBinding.Kind kind) { if (type == null) { throw new IllegalArgumentException("Null type: id=" + id + ", loc=" + loc); } // Attributes are always part of a qualified name. If there is no qname // on the target type, it's a bug (we forgot to set the path somewhere.) if ("".equals(path)) { Indexer.idx.reportFailedAssertion( "Attempting to set attr '" + id + "' at location " + loc + (loc != null ? loc.getFile() : "") + " in scope with no path (qname) set: " + this.toShortString()); return null; } NBinding b = lookupAttr(id); return insertOrUpdate(b, id, loc, type, kind); }
// in src/org/python/indexer/Scope.java
public NBinding update(String id, NNode loc, NType type, NBinding.Kind kind) { if (type == null) { throw new IllegalArgumentException("Null type: id=" + id + ", loc=" + loc); } return update(id, new Def(loc), type, kind); }
// in src/org/python/indexer/Scope.java
public NBinding update(String id, Def loc, NType type, NBinding.Kind kind) { if (type == null) { throw new IllegalArgumentException("Null type: id=" + id + ", loc=" + loc); } NBinding b = lookupScope(id); if (b == null) { return insertBinding(new NBinding(id, loc, type, kind)); } b.getDefs().clear(); // XXX: what about updating refs & idx.locations? b.addDef(loc); b.setType(type); // XXX: is this a bug? I think he meant to do this check before the // line above that sets b.type, if it's supposed to be like put(). if (b.getType().isUnknownType()) { b.setKind(kind); } return b; }
// in src/org/python/indexer/Scope.java
public void setPath(String path) { if (path == null) { throw new IllegalArgumentException("'path' param cannot be null"); } this.path = path; }
// in src/org/python/expose/generate/RestrictiveAnnotationVisitor.java
public AnnotationVisitor visitAnnotation(String name, String desc) { throw new IllegalArgumentException("Unknown annotation field '" + name + "'"); }
// in src/org/python/expose/generate/RestrictiveAnnotationVisitor.java
public AnnotationVisitor visitArray(String name) { throw new IllegalArgumentException("Unknown annotation field '" + name + "'"); }
// in src/org/python/expose/generate/RestrictiveAnnotationVisitor.java
public void visitEnum(String name, String desc, String value) { throw new IllegalArgumentException("Unknown annotation field '" + name + "'"); }
// in src/org/python/expose/generate/RestrictiveAnnotationVisitor.java
public void visit(String name, Object value) { throw new IllegalArgumentException("Unknown annotation field '" + name + "'"); }
// in src/org/python/antlr/PythonTree.java
public void setChild(int i, PythonTree t) { if ( t==null ) { return; } if ( t.isNil() ) { throw new IllegalArgumentException("Can't set single child to a list"); } if ( children==null ) { children = createChildrenList(); } children.set(i, t); t.setParent(this); t.setChildIndex(i); }
// in src/org/python/antlr/PythonTree.java
public void replaceChildren(int startChildIndex, int stopChildIndex, Object t) { if ( children==null ) { throw new IllegalArgumentException("indexes invalid; no children in list"); } int replacingHowMany = stopChildIndex - startChildIndex + 1; int replacingWithHowMany; PythonTree newTree = (PythonTree)t; List<PythonTree> newChildren = null; // normalize to a list of children to add: newChildren if ( newTree.isNil() ) { newChildren = newTree.children; } else { newChildren = new ArrayList<PythonTree>(1); newChildren.add(newTree); } replacingWithHowMany = newChildren.size(); int numNewChildren = newChildren.size(); int delta = replacingHowMany - replacingWithHowMany; // if same number of nodes, do direct replace if ( delta == 0 ) { int j = 0; // index into new children for (int i=startChildIndex; i<=stopChildIndex; i++) { PythonTree child = newChildren.get(j); children.set(i, child); child.setParent(this); child.setChildIndex(i); j++; } } else if ( delta > 0 ) { // fewer new nodes than there were // set children and then delete extra for (int j=0; j<numNewChildren; j++) { children.set(startChildIndex+j, newChildren.get(j)); } int indexToDelete = startChildIndex+numNewChildren; for (int c=indexToDelete; c<=stopChildIndex; c++) { // delete same index, shifting everybody down each time PythonTree killed = children.remove(indexToDelete); } freshenParentAndChildIndexes(startChildIndex); } else { // more new nodes than were there before // fill in as many children as we can (replacingHowMany) w/o moving data for (int j=0; j<replacingHowMany; j++) { children.set(startChildIndex+j, newChildren.get(j)); } int numToInsert = replacingWithHowMany-replacingHowMany; for (int j=replacingHowMany; j<replacingWithHowMany; j++) { children.add(startChildIndex+j, newChildren.get(j)); } freshenParentAndChildIndexes(startChildIndex); } }
// in src/org/python/jsr223/PyScriptEngine.java
public <T> T getInterface(Object obj, Class<T> clazz) { if (obj == null) { throw new IllegalArgumentException("object expected"); } if (clazz == null || !clazz.isInterface()) { throw new IllegalArgumentException("interface expected"); } interp.setLocals(new PyScriptEngineScope(this, context)); final PyObject thiz = Py.java2py(obj); @SuppressWarnings("unchecked") T proxy = (T) Proxy.newProxyInstance( clazz.getClassLoader(), new Class[] { clazz }, new InvocationHandler() { public Object invoke(Object proxy, Method method, Object[] args) throws Throwable { try { interp.setLocals(new PyScriptEngineScope(PyScriptEngine.this, context)); PyObject pyMethod = thiz.__findattr__(method.getName()); if (pyMethod == null) throw new NoSuchMethodException(method.getName()); PyObject result = pyMethod.__call__(Py.javas2pys(args)); return result.__tojava__(Object.class); } catch (PyException pye) { throw scriptException(pye); } } }); return proxy; }
// in src/org/python/modules/jffi/FastIntInvokerFactory.java
final IntResultConverter getIntResultConverter(NativeType type) { switch (type) { case VOID: return VoidResultConverter.INSTANCE; case BYTE: return Signed8ResultConverter.INSTANCE; case UBYTE: return Unsigned8ResultConverter.INSTANCE; case SHORT: return Signed16ResultConverter.INSTANCE; case USHORT: return Unsigned16ResultConverter.INSTANCE; case INT: return Signed32ResultConverter.INSTANCE; case UINT: return Unsigned32ResultConverter.INSTANCE; case LONG: if (Platform.getPlatform().longSize() == 32) { return Signed32ResultConverter.INSTANCE; } break; case ULONG: if (Platform.getPlatform().longSize() == 32) { return Unsigned32ResultConverter.INSTANCE; } break; case STRING: if (Platform.getPlatform().addressSize() == 32) { return StringResultConverter.INSTANCE; } break; default: break; } throw new IllegalArgumentException("Cannot convert objects of type " + type + " from int"); }
// in src/org/python/core/PyTuple.java
public List subList(int fromIndex, int toIndex) { if (fromIndex < 0 || toIndex > size()) { throw new IndexOutOfBoundsException(); } else if (fromIndex > toIndex) { throw new IllegalArgumentException(); } PyObject elements[] = new PyObject[toIndex - fromIndex]; for (int i = 0, j = fromIndex; i < elements.length; i++, j++) { elements[i] = array[j]; } return new PyTuple(elements); }
// in src/org/python/core/AbstractArray.java
public void replaceSubArray(int thisStart, int thisStop, Object srcArray, int srcStart, int srcStop) { this.modCountIncr = 0; if (!srcArray.getClass().isArray()) { throw new IllegalArgumentException("'array' must be an array type"); } int replacedLen = thisStop - thisStart; if (thisStart < 0 || replacedLen < 0 || thisStop > this.size) { String message = null; if (thisStart < 0) { message = "thisStart < 0 (thisStart = " + thisStart + ")"; } else if (replacedLen < 0) { message = "thisStart > thistStop (thisStart = " + thisStart + ", thisStop = " + thisStop + ")"; } else if (thisStop > this.size) { message = "thisStop > size (thisStop = " + thisStop + ", size = " + this.size + ")"; } else { throw new InternalError("Incorrect validation logic"); } throw new ArrayIndexOutOfBoundsException(message); } int srcLen = Array.getLength(srcArray); int replacementLen = srcStop - srcStart; if (srcStart < 0 || replacementLen < 0 || srcStop > srcLen) { String message = null; if (srcStart < 0) { message = "srcStart < 0 (srcStart = " + srcStart +")"; } else if (replacementLen < 0) { message = "srcStart > srcStop (srcStart = " + srcStart + ", srcStop = " + srcStop + ")"; } else if (srcStop > srcLen) { message = "srcStop > srcArray length (srcStop = " + srcStop + ", srcArray length = " +srcLen + ")"; } else { throw new InternalError("Incorrect validation logic"); } throw new IllegalArgumentException("start, stop and array must follow:\n\t" + "0 <= start <= stop <= array length\nBut found\n\t" + message); } int lengthChange = replacementLen - replacedLen; // Adjust array size if needed. if (lengthChange < 0) { remove(thisStop + lengthChange, thisStop); } else if (lengthChange > 0) { makeInsertSpace(thisStop, lengthChange); } try { this.modCountIncr = 1; System.arraycopy(srcArray, srcStart, getArray(), thisStart, replacementLen); } catch (ArrayStoreException e) { throw new IllegalArgumentException("'ofArrayType' must be compatible with existing array type of " + getArray().getClass().getName() + "\tsee java.lang.Class.getName()."); } }
// in src/org/python/core/stringlib/MarkupIterator.java
public Chunk nextChunk() { if (index == markup.length()) { return null; } Chunk result = new Chunk(); int pos = index; while (true) { pos = indexOfFirst(markup, pos, '{', '}'); if (pos >= 0 && pos < markup.length() - 1 && markup.charAt(pos + 1) == markup.charAt(pos)) { // skip escaped bracket pos += 2; } else if (pos >= 0 && markup.charAt(pos) == '}') { throw new IllegalArgumentException("Single '}' encountered in format string"); } else { break; } } if (pos < 0) { result.literalText = unescapeBraces(markup.substring(index)); result.fieldName = ""; index = markup.length(); } else { result.literalText = unescapeBraces(markup.substring(index, pos)); pos++; int fieldStart = pos; int count = 1; while (pos < markup.length()) { if (markup.charAt(pos) == '{') { count++; result.formatSpecNeedsExpanding = true; } else if (markup.charAt(pos) == '}') { count--; if (count == 0) { parseField(result, markup.substring(fieldStart, pos)); pos++; break; } } pos++; } if (count > 0) { throw new IllegalArgumentException("Single '{' encountered in format string"); } index = pos; } return result; }
// in src/org/python/core/stringlib/MarkupIterator.java
private void parseField(Chunk result, String fieldMarkup) { int pos = indexOfFirst(fieldMarkup, 0, '!', ':'); if (pos >= 0) { result.fieldName = fieldMarkup.substring(0, pos); if (fieldMarkup.charAt(pos) == '!') { if (pos == fieldMarkup.length() - 1) { throw new IllegalArgumentException("end of format while " + "looking for conversion specifier"); } result.conversion = fieldMarkup.substring(pos + 1, pos + 2); pos += 2; if (pos < fieldMarkup.length()) { if (fieldMarkup.charAt(pos) != ':') { throw new IllegalArgumentException("expected ':' " + "after conversion specifier"); } result.formatSpec = fieldMarkup.substring(pos + 1); } } else { result.formatSpec = fieldMarkup.substring(pos + 1); } } else { result.fieldName = fieldMarkup; } }
// in src/org/python/core/stringlib/InternalFormatSpecParser.java
public InternalFormatSpec parse() { InternalFormatSpec result = new InternalFormatSpec(); if (spec.length() >= 1 && isAlign(spec.charAt(0))) { result.align = spec.charAt(index); index++; } else if (spec.length() >= 2 && isAlign(spec.charAt(1))) { result.fill_char = spec.charAt(0); result.align = spec.charAt(1); index += 2; } if (isAt("+- ")) { result.sign = spec.charAt(index); index++; } if (isAt("#")) { result.alternate = true; index++; } if (isAt("0")) { result.align = '='; result.fill_char = '0'; index++; } result.width = getInteger(); if (isAt(".")) { index++; result.precision = getInteger(); if (result.precision == -1) { throw new IllegalArgumentException("Format specifier missing precision"); } } if (index < spec.length()) { result.type = spec.charAt(index); if (index + 1 != spec.length()) { throw new IllegalArgumentException("Invalid conversion specification"); } } return result; }
// in src/org/python/core/stringlib/FieldNameIterator.java
private void parseItemChunk(Chunk chunk) { chunk.is_attr = false; int endBracket = markup.indexOf(']', index+1); if (endBracket < 0) { throw new IllegalArgumentException("Missing ']' in format string"); } String itemValue = markup.substring(index + 1, endBracket); if (itemValue.length() == 0) { throw new IllegalArgumentException("Empty attribute in format string"); } try { chunk.value = Integer.parseInt(itemValue); } catch (NumberFormatException e) { chunk.value = itemValue; } index = endBracket + 1; }
// in src/org/python/core/stringlib/FieldNameIterator.java
private void parseAttrChunk(Chunk chunk) { index++; // skip dot chunk.is_attr = true; int pos = nextDotOrBracket(markup); if (pos == index) { throw new IllegalArgumentException("Empty attribute in format string"); } chunk.value = markup.substring(index, pos); index = pos; }
// in src/org/python/core/PyRunnableBootstrap.java
public static CodeBootstrap getFilenameConstructorReflectionBootstrap( Class<? extends PyRunnable> cls) { final Constructor<? extends PyRunnable> constructor; try { constructor = cls.getConstructor(String.class); } catch (Exception e) { throw new IllegalArgumentException( "PyRunnable class does not specify apropriate constructor.", e); } return new CodeBootstrap() { public PyCode loadCode(CodeLoader loader) { try { return constructor.newInstance(loader.filename).getMain(); } catch (Exception e) { throw new IllegalArgumentException( "PyRunnable class constructor does not support instantiation protocol.", e); } } }; }
// in src/org/python/core/PyRunnableBootstrap.java
public PyCode loadCode(CodeLoader loader) { try { return constructor.newInstance(loader.filename).getMain(); } catch (Exception e) { throw new IllegalArgumentException( "PyRunnable class constructor does not support instantiation protocol.", e); } }
// in src/org/python/core/Py.java
static final PyString makeCharacter(int codepoint, boolean toUnicode) { if (toUnicode) { return new PyUnicode(codepoint); } else if (codepoint > 65536) { throw new IllegalArgumentException(String.format("Codepoint > 65536 (%d) requires " + "toUnicode argument", codepoint)); } else if (codepoint > 256) { return new PyString((char)codepoint); } return letters[codepoint]; }
// in src/org/python/core/PyInteger.java
public static String formatIntOrLong(Object value, InternalFormatSpec spec) { if (spec.precision != -1) { throw new IllegalArgumentException("Precision not allowed in integer format specifier"); } int sign; if (value instanceof Integer) { int intValue = (Integer) value; sign = intValue < 0 ? -1 : intValue == 0 ? 0 : 1; } else { sign = ((BigInteger) value).signum(); } String strValue; if (spec.type == 'c') { if (spec.sign != '\0') { throw new IllegalArgumentException("Sign not allowed with integer format " + "specifier 'c'"); } if (value instanceof Integer) { int intValue = (Integer) value; if (intValue > 0xffff) { throw new IllegalArgumentException("%c arg not in range(0x10000)"); } strValue = Character.toString((char) intValue); } else { BigInteger bigInt = (BigInteger) value; if (bigInt.intValue() > 0xffff || bigInt.bitCount() > 16) { throw new IllegalArgumentException("%c arg not in range(0x10000)"); } strValue = Character.toString((char) bigInt.intValue()); } } else { int radix = 10; if (spec.type == 'o') { radix = 8; } else if (spec.type == 'x' || spec.type == 'X') { radix = 16; } else if (spec.type == 'b') { radix = 2; } // TODO locale-specific formatting for 'n' if (value instanceof BigInteger) { strValue = ((BigInteger) value).toString(radix); } else { strValue = Integer.toString((Integer) value, radix); } if (spec.alternate) { if (radix == 2) { strValue = "0b" + strValue; } else if (radix == 8) { strValue = "0o" + strValue; } else if (radix == 16) { strValue = "0x" + strValue; } } if (spec.type == 'X') { strValue = strValue.toUpperCase(); } if (sign >= 0) { if (spec.sign == '+') { strValue = "+" + strValue; } else if (spec.sign == ' ') { strValue = " " + strValue; } } } if (spec.align == '=' && (sign < 0 || spec.sign == '+' || spec.sign == ' ')) { char signChar = strValue.charAt(0); return signChar + spec.pad(strValue.substring(1), '>', 1); } return spec.pad(strValue, '>', 0); }
3
            
// in src/org/python/core/AbstractArray.java
catch (ArrayStoreException e) { throw new IllegalArgumentException("'ofArrayType' must be compatible with existing array type of " + getArray().getClass().getName() + "\tsee java.lang.Class.getName()."); }
// in src/org/python/core/PyRunnableBootstrap.java
catch (Exception e) { throw new IllegalArgumentException( "PyRunnable class does not specify apropriate constructor.", e); }
// in src/org/python/core/PyRunnableBootstrap.java
catch (Exception e) { throw new IllegalArgumentException( "PyRunnable class constructor does not support instantiation protocol.", e); }
2
            
// in src/org/python/core/CodeLoader.java
public static PyCode loadCode(Class<?> cls, String name, String filename) throws SecurityException, NoSuchMethodException, IllegalArgumentException, IllegalAccessException, InvocationTargetException { Method getBootstrap = cls.getMethod(GET_BOOTSTRAP_METHOD_NAME); CodeBootstrap bootstrap = (CodeBootstrap) getBootstrap.invoke(null); return loadCode(bootstrap, name, filename); }
// in src/org/python/core/CodeLoader.java
public static PyCode loadCode(Class<?> cls) throws SecurityException, IllegalArgumentException, NoSuchMethodException, IllegalAccessException, InvocationTargetException { return loadCode(cls, null, null); }
8
            
// in src/org/python/core/FutureFeature.java
catch (IllegalArgumentException ex) { throw new ParseException("future feature " + featureName + " is not defined"); }
// in src/org/python/core/stringlib/MarkupIterator.java
catch (IllegalArgumentException e) { throw Py.ValueError(e.getMessage()); }
// in src/org/python/core/PyArray.java
catch(IllegalArgumentException e) { throw Py.TypeError("Slice typecode '" + array.typecode + "' is not compatible with this array (typecode '" + this.typecode + "')"); }
// in src/org/python/core/Py.java
catch (IllegalArgumentException e) { // e.printStackTrace(); return null; }
// in src/org/python/core/Py.java
catch (IllegalArgumentException e) { throw JavaError(e); }
// in src/org/python/core/PyInteger.java
catch (IllegalArgumentException e) { throw Py.ValueError(e.getMessage()); }
// in src/org/python/core/PyString.java
catch (IllegalArgumentException e) { throw Py.ValueError(e.getMessage()); }
// in src/org/python/core/PyString.java
catch (IllegalArgumentException e) { throw Py.ValueError(e.getMessage()); }
7
            
// in src/org/python/core/FutureFeature.java
catch (IllegalArgumentException ex) { throw new ParseException("future feature " + featureName + " is not defined"); }
// in src/org/python/core/stringlib/MarkupIterator.java
catch (IllegalArgumentException e) { throw Py.ValueError(e.getMessage()); }
// in src/org/python/core/PyArray.java
catch(IllegalArgumentException e) { throw Py.TypeError("Slice typecode '" + array.typecode + "' is not compatible with this array (typecode '" + this.typecode + "')"); }
// in src/org/python/core/Py.java
catch (IllegalArgumentException e) { throw JavaError(e); }
// in src/org/python/core/PyInteger.java
catch (IllegalArgumentException e) { throw Py.ValueError(e.getMessage()); }
// in src/org/python/core/PyString.java
catch (IllegalArgumentException e) { throw Py.ValueError(e.getMessage()); }
// in src/org/python/core/PyString.java
catch (IllegalArgumentException e) { throw Py.ValueError(e.getMessage()); }
1
unknown (Lib) IllegalMonitorStateException 0 0 0 1
            
// in src/org/python/modules/imp.java
catch(IllegalMonitorStateException e){ throw Py.RuntimeError("not holding the import lock"); }
1
            
// in src/org/python/modules/imp.java
catch(IllegalMonitorStateException e){ throw Py.RuntimeError("not holding the import lock"); }
0
runtime (Lib) IllegalStateException 8
            
// in src/org/python/indexer/Util.java
public static String moduleNameFor(String path) { File f = new File(path); if (f.isDirectory()) { throw new IllegalStateException("failed assertion: " + path); } String fname = f.getName(); if (fname.equals("__init__.py")) { return f.getParentFile().getName(); } return fname.substring(0, fname.lastIndexOf('.')); }
// in src/org/python/indexer/Scope.java
public String extendPathForParam(String name) { if (path.equals("")) { throw new IllegalStateException("Not inside a function"); } return path + "@" + name; }
// in src/org/python/expose/generate/Exposer.java
public void pushArgs() { if(types.length > 0) { throw new IllegalStateException("If the constuctor takes types as indicated by " + "passing their types to Instantiator, pushArgs must be overriden to put " + "those args on the stack before the call"); } }
// in src/org/python/antlr/PythonTokenSource.java
protected void push(int i) { if (sp >= MAX_INDENTS) { throw new IllegalStateException("stack overflow"); } sp++; indentStack[sp] = i; }
// in src/org/python/antlr/PythonTokenSource.java
protected int pop() { if (sp<0) { throw new IllegalStateException("stack underflow"); } int top = indentStack[sp]; sp--; return top; }
// in src/org/python/modules/sre/SRE_STATE.java
final int SRE_MATCH(int[] pattern, int pidx, int level) { /* check if string matches the given pattern. returns <0 for error, 0 for failure, and 1 for success */ int end = this.end; int ptr = this.ptr; int i, count; int chr; int lastmark, lastindex, mark_stack_base = 0; TRACE(pidx, ptr, "ENTER " + level); if (level > USE_RECURSION_LIMIT) return SRE_ERROR_RECURSION_LIMIT; if (pattern[pidx] == SRE_OP_INFO) { /* optimization info block */ /* args: <1=skip> <2=flags> <3=min> ... */ if (pattern[pidx+3] != 0 && (end - ptr) < pattern[pidx+3]) { return 0; } pidx += pattern[pidx+1] + 1; } for (;;) { switch (pattern[pidx++]) { case SRE_OP_MARK: /* set mark */ /* <MARK> <gid> */ TRACE(pidx, ptr, "MARK " + pattern[pidx]); i = pattern[pidx]; if ((i & 1) != 0) this.lastindex = i / 2 + 1; if (i > this.lastmark) this.lastmark = i; mark[i] = ptr; pidx++; break; case SRE_OP_LITERAL: /* match literal character */ /* <LITERAL> <code> */ TRACE(pidx, ptr, "LITERAL " + pattern[pidx]); if (ptr >= end || str[ptr] != pattern[pidx]) return 0; pidx++; ptr++; break; case SRE_OP_NOT_LITERAL: /* match anything that is not literal character */ /* args: <code> */ TRACE(pidx, ptr, "NOT_LITERAL " + pattern[pidx]); if (ptr >= end || str[ptr] == pattern[pidx]) return 0; pidx++; ptr++; break; case SRE_OP_SUCCESS: /* end of pattern */ TRACE(pidx, ptr, "SUCCESS"); this.ptr = ptr; return 1; case SRE_OP_AT: /* match at given position */ /* <AT> <code> */ TRACE(pidx, ptr, "AT " + pattern[pidx]); if (!SRE_AT(ptr, pattern[pidx])) return 0; pidx++; break; case SRE_OP_CATEGORY: /* match at given category */ /* <CATEGORY> <code> */ TRACE(pidx, ptr, "CATEGORY " + pattern[pidx]); if (ptr >= end || !sre_category(pattern[pidx], str[ptr])) return 0; pidx++; ptr++; break; case SRE_OP_ANY: /* match anything */ TRACE(pidx, ptr, "ANY"); if (ptr >= end || SRE_IS_LINEBREAK(str[ptr])) return 0; ptr++; break; case SRE_OP_ANY_ALL: /* match anything */ /* <ANY_ALL> */ TRACE(pidx, ptr, "ANY_ALL"); if (ptr >= end) return 0; ptr++; break; case SRE_OP_IN: /* match set member (or non_member) */ /* <IN> <skip> <set> */ TRACE(pidx, ptr, "IN"); if (ptr >= end || !SRE_CHARSET(pattern, pidx + 1, str[ptr])) return 0; pidx += pattern[pidx]; ptr++; break; case SRE_OP_LITERAL_IGNORE: TRACE(pidx, ptr, "LITERAL_IGNORE " + pattern[pidx]); if (ptr >= end || lower(str[ptr]) != lower(pattern[pidx])) return 0; pidx++; ptr++; break; case SRE_OP_NOT_LITERAL_IGNORE: TRACE(pidx, ptr, "NOT_LITERAL_IGNORE " + pattern[pidx]); if (ptr >= end || lower(str[ptr]) == lower(pattern[pidx])) return 0; pidx++; ptr++; break; case SRE_OP_IN_IGNORE: TRACE(pidx, ptr, "IN_IGNORE"); if (ptr >= end || !SRE_CHARSET(pattern, pidx + 1, lower(str[ptr]))) return 0; pidx += pattern[pidx]; ptr++; break; case SRE_OP_JUMP: case SRE_OP_INFO: /* jump forward */ /* <JUMP> <offset> */ TRACE(pidx, ptr, "JUMP " + pattern[pidx]); pidx += pattern[pidx]; break; case SRE_OP_BRANCH: /* try an alternate branch */ /* <BRANCH> <0=skip> code <JUMP> ... <NULL> */ // TRACE(pidx, ptr, "BRANCH"); lastmark = this.lastmark; lastindex = this.lastindex; if(this.repeat != null) { mark_stack_base = mark_save(0, lastmark); } for(; pattern[pidx] != 0; pidx += pattern[pidx]) { if(pattern[pidx + 1] == SRE_OP_LITERAL && (ptr >= end || str[ptr] != pattern[pidx + 2])) continue; if(pattern[pidx + 1] == SRE_OP_IN && (ptr >= end || !SRE_CHARSET(pattern, pidx + 3, str[ptr]))) continue; this.ptr = ptr; i = SRE_MATCH(pattern, pidx + 1, level + 1); if(i != 0) return i; if(this.repeat != null) { mark_restore(0, lastmark, mark_stack_base); } LASTMARK_RESTORE(lastmark, lastindex); } return 0; case SRE_OP_REPEAT_ONE: /* match repeated sequence (maximizing regexp) */ /* this operator only works if the repeated item is exactly one character wide, and we're not already collecting backtracking points. for other cases, use the MAX_REPEAT operator */ /* <REPEAT_ONE> <skip> <1=min> <2=max> item <SUCCESS> tail */ int mincount = pattern[pidx+1]; TRACE(pidx, ptr, "REPEAT_ONE " + mincount + " " + pattern[pidx+2]); if (ptr + mincount > end) return 0; /* cannot match */ this.ptr = ptr; count = SRE_COUNT(pattern, pidx + 3, pattern[pidx+2], level + 1); if (count < 0) return count; ptr += count; /* when we arrive here, count contains the number of matches, and ptr points to the tail of the target string. check if the rest of the pattern matches, and backtrack if not. */ if (count < mincount) return 0; if (pattern[pidx + pattern[pidx]] == SRE_OP_SUCCESS) { /* tail is empty. we're finished */ this.ptr = ptr; return 1; } lastmark = this.lastmark; lastindex = this.lastindex; if (pattern[pidx + pattern[pidx]] == SRE_OP_LITERAL) { /* tail starts with a literal. skip positions where the rest of the pattern cannot possibly match */ chr = pattern[pidx + pattern[pidx]+1]; for (;;) { while (count >= mincount && (ptr >= end || str[ptr] != chr)) { ptr--; count--; } if (count < mincount) break; this.ptr = ptr; i = SRE_MATCH(pattern, pidx + pattern[pidx], level + 1); if (i != 0) return 1; ptr--; count--; LASTMARK_RESTORE(lastmark, lastindex); } } else { /* general case */ lastmark = this.lastmark; while (count >= mincount) { this.ptr = ptr; i = SRE_MATCH(pattern, pidx + pattern[pidx], level + 1); if (i != 0) return i; ptr--; count--; LASTMARK_RESTORE(lastmark, lastindex); } } return 0; case SRE_OP_MIN_REPEAT_ONE: /* match repeated sequence (minimizing regexp) */ /* this operator only works if the repeated item is exactly one character wide, and we're not already collecting backtracking points. for other cases, use the MIN_REPEAT operator */ /* <MIN_REPEAT_ONE> <skip> <1=min> <2=max> item <SUCCESS> tail */ TRACE(pidx, ptr, "MIN_REPEAT_ONE"); if (ptr + pattern[pidx+1] > end) return 0; /* cannot match */ this.ptr = ptr; if (pattern[pidx+1] == 0) count = 0; else { count = SRE_COUNT(pattern, pidx + 3, pattern[pidx+1], level + 1); if (count < 0) return count; /* exception */ if (count < pattern[pidx+1]) return 0; /* did not match minimum number of times */ ptr += count; /* advance past minimum matches of repeat */ } if (pattern[pidx + pattern[pidx]] == SRE_OP_SUCCESS) { /* tail is empty. we're finished */ this.ptr = ptr; return 1; } else { /* general case */ boolean matchmax = (pattern[pidx + 2] == 65535); int c; lastmark = this.lastmark; lastindex = this.lastindex; while (matchmax || count <= pattern[pidx + 2]) { this.ptr = ptr; i = SRE_MATCH(pattern, pidx + pattern[pidx], level + 1); if (i != 0) return i; this.ptr = ptr; c = SRE_COUNT(pattern, pidx+3, 1, level+1); if (c < 0) return c; if (c == 0) break; if(c != 1){ throw new IllegalStateException("c should be 1!"); } ptr++; count++; LASTMARK_RESTORE(lastmark, lastindex); } } return 0; case SRE_OP_REPEAT: /* create repeat context. all the hard work is done by the UNTIL operator (MAX_UNTIL, MIN_UNTIL) */ /* <REPEAT> <skip> <1=min> <2=max> item <UNTIL> tail */ TRACE(pidx, ptr, "REPEAT " + pattern[pidx+1] + " " + pattern[pidx+2]); SRE_REPEAT rep = new SRE_REPEAT(repeat); rep.count = -1; rep.pidx = pidx; repeat = rep; this.ptr = ptr; i = SRE_MATCH(pattern, pidx + pattern[pidx], level + 1); repeat = rep.prev; return i; case SRE_OP_MAX_UNTIL: /* maximizing repeat */ /* <REPEAT> <skip> <1=min> <2=max> item <MAX_UNTIL> tail */ /* FIXME: we probably need to deal with zero-width matches in here... */ SRE_REPEAT rp = this.repeat; if (rp == null) return SRE_ERROR_STATE; this.ptr = ptr; count = rp.count + 1; TRACE(pidx, ptr, "MAX_UNTIL " + count); if (count < pattern[rp.pidx + 1]) { /* not enough matches */ rp.count = count; i = SRE_MATCH(pattern, rp.pidx + 3, level + 1); if (i != 0) return i; rp.count = count - 1; this.ptr = ptr; return 0; } if (count < pattern[rp.pidx+2] || pattern[rp.pidx+2] == 65535) { /* we may have enough matches, but if we can match another item, do so */ rp.count = count; lastmark = this.lastmark; lastindex = this.lastindex; mark_stack_base = mark_save(0, lastmark); /* RECURSIVE */ i = SRE_MATCH(pattern, rp.pidx + 3, level + 1); if (i != 0) return i; mark_restore(0, lastmark, mark_stack_base); LASTMARK_RESTORE(lastmark, lastindex); rp.count = count - 1; this.ptr = ptr; } /* cannot match more repeated items here. make sure the tail matches */ this.repeat = rp.prev; /* RECURSIVE */ i = SRE_MATCH(pattern, pidx, level + 1); if (i != 0) return i; this.repeat = rp; this.ptr = ptr; return 0; case SRE_OP_MIN_UNTIL: /* minimizing repeat */ /* <REPEAT> <skip> <1=min> <2=max> item <MIN_UNTIL> tail */ rp = this.repeat; if (rp == null) return SRE_ERROR_STATE; this.ptr = ptr; count = rp.count + 1; TRACE(pidx, ptr, "MIN_UNTIL " + count + " " + rp.pidx); if (count < pattern[rp.pidx + 1]) { /* not enough matches */ rp.count = count; /* RECURSIVE */ i = SRE_MATCH(pattern, rp.pidx + 3, level + 1); if (i != 0) return i; rp.count = count-1; this.ptr = ptr; return 0; } lastmark = this.lastmark; lastindex = this.lastindex; /* see if the tail matches */ this.repeat = rp.prev; i = SRE_MATCH(pattern, pidx, level + 1); if (i != 0) return i; this.ptr = ptr; this.repeat = rp; if (count >= pattern[rp.pidx+2] && pattern[rp.pidx+2] != 65535) return 0; LASTMARK_RESTORE(lastmark, lastindex); rp.count = count; /* RECURSIVE */ i = SRE_MATCH(pattern, rp.pidx + 3, level + 1); if (i != 0) return i; rp.count = count - 1; this.ptr = ptr; return 0; case SRE_OP_GROUPREF: /* match backreference */ i = pattern[pidx]; TRACE(pidx, ptr, "GROUPREF " + i); int p = mark[i+i]; int e = mark[i+i+1]; if (p == -1 || e == -1 || e < p) return 0; while (p < e) { if (ptr >= end || str[ptr] != str[p]) return 0; p++; ptr++; } pidx++; break; case SRE_OP_GROUPREF_IGNORE: /* match backreference */ i = pattern[pidx]; TRACE(pidx, ptr, "GROUPREF_IGNORE " + i); p = mark[i+i]; e = mark[i+i+1]; if (p == -1 || e == -1 || e < p) return 0; while (p < e) { if (ptr >= end || lower(str[ptr]) != lower(str[p])) return 0; p++; ptr++; } pidx++; break; case SRE_OP_GROUPREF_EXISTS: i = pattern[pidx]; TRACE(pidx, ptr, "GROUPREF_EXISTS " + i); p = mark[i+i]; e = mark[i+i+1]; if (p == -1 || e == -1 || e < p) { pidx += pattern[pidx + 1]; break; } pidx += 2; break; case SRE_OP_ASSERT: /* assert subpattern */ /* args: <skip> <back> <pattern> */ TRACE(pidx, ptr, "ASSERT " + pattern[pidx+1]); this.ptr = ptr - pattern[pidx + 1]; if (this.ptr < this.beginning) return 0; i = SRE_MATCH(pattern, pidx + 2, level + 1); if (i <= 0) return i; pidx += pattern[pidx]; break; case SRE_OP_ASSERT_NOT: /* assert not subpattern */ /* args: <skip> <pattern> */ TRACE(pidx, ptr, "ASSERT_NOT " + pattern[pidx]); this.ptr = ptr - pattern[pidx + 1]; if (this.ptr >= this.beginning) { i = SRE_MATCH(pattern, pidx + 2, level + 1); if (i < 0) return i; if (i != 0) return 0; } pidx += pattern[pidx]; break; case SRE_OP_FAILURE: /* immediate failure */ TRACE(pidx, ptr, "FAILURE"); return 0; default: TRACE(pidx, ptr, "UNKNOWN " + pattern[pidx-1]); return SRE_ERROR_ILLEGAL; } } /* can't end up here */ /* return SRE_ERROR_ILLEGAL; -- see python-dev discussion */ }
// in src/org/python/core/AbstractArray.java
public void remove(int index) { if (index >= 0 && index < this.size) { this.size = this.size - 1; if (index < this.size) { Object base = getArray(); System.arraycopy(base, index + 1, base, index, this.size - index); clearRangeInternal(this.size, this.size); } } else { if (this.size == 0) { throw new IllegalStateException("Cannot remove data from an empty array"); } throw new IndexOutOfBoundsException("Index must be between 0 and " + (this.size - 1) + ", but was " + index); } }
// in src/org/python/core/CodeFlag.java
public CodeFlag next() { if (hasNext()) try { return next; } finally { next = null; } throw new IllegalStateException(); }
0 0 1
            
// in src/org/python/core/PySystemState.java
catch (IllegalStateException e) { // JVM is already shutting down, so we cannot remove this shutdown hook anyway }
0 0
unknown (Lib) IndexOutOfBoundsException 5
            
// in src/org/python/core/FilelikeInputStream.java
public int read(byte b[], int off, int len) throws IOException { if(b == null) { throw new NullPointerException(); } else if((off < 0) || (off > b.length) || (len < 0) || ((off + len) > b.length) || ((off + len) < 0)) { throw new IndexOutOfBoundsException(); } else if(len == 0) { return 0; } String result = ((PyString) filelike.__getattr__("read") .__call__(new PyInteger(len))).getString(); if(result.length() == 0) { return -1; } System.arraycopy(StringUtil.toBytes(result), 0, b, off, result.length()); return result.length(); }
// in src/org/python/core/PyTuple.java
public List subList(int fromIndex, int toIndex) { if (fromIndex < 0 || toIndex > size()) { throw new IndexOutOfBoundsException(); } else if (fromIndex > toIndex) { throw new IllegalArgumentException(); } PyObject elements[] = new PyObject[toIndex - fromIndex]; for (int i = 0, j = fromIndex; i < elements.length; i++, j++) { elements[i] = array[j]; } return new PyTuple(elements); }
// in src/org/python/core/AbstractArray.java
public void remove(int index) { if (index >= 0 && index < this.size) { this.size = this.size - 1; if (index < this.size) { Object base = getArray(); System.arraycopy(base, index + 1, base, index, this.size - index); clearRangeInternal(this.size, this.size); } } else { if (this.size == 0) { throw new IllegalStateException("Cannot remove data from an empty array"); } throw new IndexOutOfBoundsException("Index must be between 0 and " + (this.size - 1) + ", but was " + index); } }
// in src/org/python/core/AbstractArray.java
public void remove(int start, int stop) { if (start >= 0 && stop <= this.size && start <= stop) { Object base = getArray(); int nRemove = stop - start; if (nRemove == 0) { return; } System.arraycopy(base, stop, base, start, this.size - stop); this.size = this.size - nRemove; clearRangeInternal(this.size, this.size + nRemove); setArray(base); return; } throw new IndexOutOfBoundsException("start and stop must follow: 0 <= start <= stop <= " + this.size + ", but found start= " + start + " and stop=" + stop); }
// in src/org/python/core/io/TextIOInputStream.java
Override public int read(byte[] b, int off, int len) throws IOException { if (b == null) { throw new NullPointerException(); } else if ((off < 0) || (off > b.length) || (len < 0) || ((off + len) > b.length) || ((off + len) < 0)) { throw new IndexOutOfBoundsException(); } else if (len == 0) { return 0; } String result = textIO.read(len); len = result.length(); for (int i = 0; i < len; i++) { b[off + i] = (byte)result.charAt(i); } return len == 0 ? -1 : len; }
0 0 1
            
// in src/org/python/core/PyString.java
catch (IndexOutOfBoundsException e) { throw Py.TypeError( "translate() only works for 8-bit character strings"); }
1
            
// in src/org/python/core/PyString.java
catch (IndexOutOfBoundsException e) { throw Py.TypeError( "translate() only works for 8-bit character strings"); }
0
runtime (Domain) IndexingException
public class IndexingException extends RuntimeException {

    public IndexingException() {
    }

    public IndexingException(String msg) {
        super(msg);
    }

    public IndexingException(String msg, Throwable cause) {
        super(msg, cause);
    }

    public IndexingException(Throwable cause) {
        super(cause);
    }
}
3
            
// in src/org/python/indexer/Indexer.java
public void handleException(String msg, Throwable cause) { // Stack overflows are still fairly common due to cyclic // types, and they take up an awful lot of log space, so we // don't log the whole trace by default. if (cause instanceof StackOverflowError) { logger.log(Level.WARNING, msg, cause); return; } if (aggressiveAssertionsEnabled()) { if (msg != null) { throw new IndexingException(msg, cause); } throw new IndexingException(cause); } if (msg == null) msg = "<null msg>"; if (cause == null) cause = new Exception(); logger.log(Level.WARNING, msg, cause); }
// in src/org/python/indexer/Indexer.java
public void reportFailedAssertion(String msg) { if (aggressiveAssertionsEnabled()) { throw new IndexingException(msg, new Exception()); // capture stack } // Need more configuration control here. // Currently getting a hillion jillion of these in large clients. if (false) { logger.log(Level.WARNING, msg); } }
0 0 1
            
// in src/org/python/indexer/ast/NNode.java
catch (IndexingException ix) { throw ix; }
1
            
// in src/org/python/indexer/ast/NNode.java
catch (IndexingException ix) { throw ix; }
0
unknown (Lib) InstantiationException 1
            
// in src/org/python/compiler/ProxyMaker.java
public void build() throws Exception { names = Generic.set(); int access = superclass.getModifiers(); if ((access & Modifier.FINAL) != 0) { throw new InstantiationException("can't subclass final class"); } access = Modifier.PUBLIC | Modifier.SYNCHRONIZED; classfile = new ClassFile(myClass, mapClass(superclass), access); addProxy(); addConstructors(superclass); classfile.addInterface("org/python/core/PyProxy"); Set<String> seenmethods = Generic.set(); addMethods(superclass, seenmethods); for (Class<?> iface : interfaces) { if (iface.isAssignableFrom(superclass)) { Py.writeWarning("compiler", "discarding redundant interface: " + iface.getName()); continue; } classfile.addInterface(mapClass(iface)); addMethods(iface, seenmethods); } doConstants(); addClassDictInit(); }
0 0 2
            
// in src/org/python/core/PyObject.java
catch (java.lang.InstantiationException e) { Class<?> sup = c.getSuperclass(); String msg = "Default constructor failed for Java superclass"; if (sup != null) { msg += " " + sup.getName(); } throw Py.TypeError(msg); }
// in src/org/python/core/imp.java
catch (InstantiationException e) { throw Py.JavaError(e); }
2
            
// in src/org/python/core/PyObject.java
catch (java.lang.InstantiationException e) { Class<?> sup = c.getSuperclass(); String msg = "Default constructor failed for Java superclass"; if (sup != null) { msg += " " + sup.getName(); } throw Py.TypeError(msg); }
// in src/org/python/core/imp.java
catch (InstantiationException e) { throw Py.JavaError(e); }
0
unknown (Lib) InternalError 2
            
// in src/org/python/core/AbstractArray.java
public void replaceSubArray(int thisStart, int thisStop, Object srcArray, int srcStart, int srcStop) { this.modCountIncr = 0; if (!srcArray.getClass().isArray()) { throw new IllegalArgumentException("'array' must be an array type"); } int replacedLen = thisStop - thisStart; if (thisStart < 0 || replacedLen < 0 || thisStop > this.size) { String message = null; if (thisStart < 0) { message = "thisStart < 0 (thisStart = " + thisStart + ")"; } else if (replacedLen < 0) { message = "thisStart > thistStop (thisStart = " + thisStart + ", thisStop = " + thisStop + ")"; } else if (thisStop > this.size) { message = "thisStop > size (thisStop = " + thisStop + ", size = " + this.size + ")"; } else { throw new InternalError("Incorrect validation logic"); } throw new ArrayIndexOutOfBoundsException(message); } int srcLen = Array.getLength(srcArray); int replacementLen = srcStop - srcStart; if (srcStart < 0 || replacementLen < 0 || srcStop > srcLen) { String message = null; if (srcStart < 0) { message = "srcStart < 0 (srcStart = " + srcStart +")"; } else if (replacementLen < 0) { message = "srcStart > srcStop (srcStart = " + srcStart + ", srcStop = " + srcStop + ")"; } else if (srcStop > srcLen) { message = "srcStop > srcArray length (srcStop = " + srcStop + ", srcArray length = " +srcLen + ")"; } else { throw new InternalError("Incorrect validation logic"); } throw new IllegalArgumentException("start, stop and array must follow:\n\t" + "0 <= start <= stop <= array length\nBut found\n\t" + message); } int lengthChange = replacementLen - replacedLen; // Adjust array size if needed. if (lengthChange < 0) { remove(thisStop + lengthChange, thisStop); } else if (lengthChange > 0) { makeInsertSpace(thisStop, lengthChange); } try { this.modCountIncr = 1; System.arraycopy(srcArray, srcStart, getArray(), thisStart, replacementLen); } catch (ArrayStoreException e) { throw new IllegalArgumentException("'ofArrayType' must be compatible with existing array type of " + getArray().getClass().getName() + "\tsee java.lang.Class.getName()."); } }
0 0 0 0 0
unknown (Lib) InterruptedException 0 0 5
            
// in src/com/ziclix/python/sql/pipe/Pipe.java
protected void pipe() throws InterruptedException { PyObject row = Py.None; this.source.start(); try { while ((row = this.source.next()) != Py.None) { this.queue.enqueue(row); this.counter++; } } finally { try { this.queue.enqueue(Py.None); } finally { this.source.end(); } } }
// in src/com/ziclix/python/sql/pipe/Pipe.java
protected void pipe() throws InterruptedException { PyObject row = Py.None; this.sink.start(); try { while ((row = (PyObject) this.queue.dequeue()) != Py.None) { this.sink.row(row); this.counter++; } } finally { this.sink.end(); } }
// in src/com/ziclix/python/sql/util/Queue.java
public synchronized void enqueue(Object element) throws InterruptedException { if (closed) { throw new QueueClosedException(); } this.queue.addLast(element); this.notify(); /* * Block while the capacity of the queue has been breached. */ while ((this.capacity > 0) && (this.queue.size() >= this.capacity)) { this.wait(); if (closed) { throw new QueueClosedException(); } } }
// in src/com/ziclix/python/sql/util/Queue.java
public synchronized Object dequeue() throws InterruptedException { while (this.queue.size() <= 0) { this.wait(); if (closed) { throw new QueueClosedException(); } } Object object = this.queue.removeFirst(); // if space exists, notify the other threads if (this.queue.size() < this.threshold) { this.notify(); } return object; }
// in src/org/python/modules/_weakref/GlobalRef.java
public void collect() throws InterruptedException { GlobalRef gr = (GlobalRef)referenceQueue.remove(); gr.call(); objects.remove(gr); gr = null; }
5
            
// in src/com/ziclix/python/sql/pipe/Pipe.java
catch (InterruptedException e) { queue.close(); throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/pipe/Pipe.java
catch (InterruptedException e) { queue.close(); throw zxJDBC.makeException(e); }
// in src/org/python/modules/_weakref/GlobalRef.java
catch (InterruptedException exc) { // ok }
// in src/org/python/modules/thread/PyLock.java
catch (InterruptedException e) { System.err.println("Interrupted thread"); }
// in src/org/python/modules/time/Time.java
catch (java.lang.InterruptedException e) { throw new PyException(Py.KeyboardInterrupt, "interrupted sleep"); }
3
            
// in src/com/ziclix/python/sql/pipe/Pipe.java
catch (InterruptedException e) { queue.close(); throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/pipe/Pipe.java
catch (InterruptedException e) { queue.close(); throw zxJDBC.makeException(e); }
// in src/org/python/modules/time/Time.java
catch (java.lang.InterruptedException e) { throw new PyException(Py.KeyboardInterrupt, "interrupted sleep"); }
1
unknown (Lib) InvalidClassException 1
            
// in src/org/python/core/PyJavaType.java
Override protected Class<?> resolveClass(ObjectStreamClass osc) throws IOException, ClassNotFoundException { Class<?> c = output.classQueue.poll(); String expected = osc.getName(); String found = (c == null) ? null : c.getName(); if (!expected.equals(found)) { throw new InvalidClassException("Classes desynchronized: " + "found " + found + " when expecting " + expected); } return c; }
0 0 0 0 0
runtime (Domain) InvalidExposingException
public class InvalidExposingException extends RuntimeException {

    public InvalidExposingException(String msg) {
        super(msg);
    }

    public InvalidExposingException(String message, String method) {
        this(message + "[method=" + method + "]");
    }
}
6
            
// in src/org/python/expose/generate/MethodExposer.java
protected void throwInvalid(String msg) { throw new InvalidExposingException(msg + "[method=" + onType.getClassName() + "." + methodName + "]"); }
// in src/org/python/expose/generate/ExposedTypeProcessor.java
private void throwInvalid(String msg) { throw new InvalidExposingException(msg + "[class=" + onType.getClassName() + "]"); }
// in src/org/python/expose/generate/TypeExposer.java
private void throwDupe(String exposedName) { throw new InvalidExposingException("Only one item may be exposed on a type with a given name[name=" + exposedName + ", class=" + onType.getClassName() + "]"); }
// in src/org/python/expose/generate/DescriptorExposer.java
private void error(String reason) { throw new InvalidExposingException(reason + "[class=" + onType.getClassName() + ", name=" + name + "]"); }
// in src/org/python/expose/generate/NewExposer.java
private void throwInvalid(String msg) { throw new InvalidExposingException(msg + "[method=" + onType.getClassName() + "." + name + "]"); }
// in src/org/python/expose/generate/ClassMethodExposer.java
private static Type[] getArgs(Type onType, String methodName, String desc) { Type[] args = Type.getArgumentTypes(desc); boolean needsThreadState = needsThreadState(args); int offset = needsThreadState ? 1 : 0; if (args.length == offset || !args[offset].equals(PYTYPE)) { String msg = String.format("ExposedClassMethod's first argument %smust be " + "PyType[method=%s.%s]", needsThreadState ? "(following ThreadState) " : "", onType.getClassName(), methodName); throw new InvalidExposingException(msg); } // Remove PyType from the exposed __call__'s args, it'll be already bound as self Type[] filledInArgs = new Type[args.length - 1]; if (needsThreadState) { // ThreadState precedes PyType filledInArgs[0] = args[0]; System.arraycopy(args, 2, filledInArgs, 1, filledInArgs.length - 1); } else { System.arraycopy(args, 1, filledInArgs, 0, filledInArgs.length); } return filledInArgs; }
0 0 1
            
// in src/org/python/expose/generate/ExposeTask.java
catch (InvalidExposingException iee) { throw new BuildException(iee.getMessage()); }
1
            
// in src/org/python/expose/generate/ExposeTask.java
catch (InvalidExposingException iee) { throw new BuildException(iee.getMessage()); }
0
unknown (Lib) InvocationTargetException 0 0 2
            
// in src/org/python/core/CodeLoader.java
public static PyCode loadCode(Class<?> cls, String name, String filename) throws SecurityException, NoSuchMethodException, IllegalArgumentException, IllegalAccessException, InvocationTargetException { Method getBootstrap = cls.getMethod(GET_BOOTSTRAP_METHOD_NAME); CodeBootstrap bootstrap = (CodeBootstrap) getBootstrap.invoke(null); return loadCode(bootstrap, name, filename); }
// in src/org/python/core/CodeLoader.java
public static PyCode loadCode(Class<?> cls) throws SecurityException, IllegalArgumentException, NoSuchMethodException, IllegalAccessException, InvocationTargetException { return loadCode(cls, null, null); }
2
            
// in src/com/ziclix/python/sql/connect/Connectx.java
catch (InvocationTargetException e) { throw zxJDBC.makeException("invocation target exception for " + exceptionMsg); }
// in src/org/python/core/PyReflectedConstructor.java
catch (InvocationTargetException e) { if (e.getTargetException() instanceof InstantiationException) { Class<?> sup = proxy.getSuperclass(); String msg = "Constructor failed for Java superclass"; if (sup != null) { msg += " " + sup.getName(); } throw Py.TypeError(msg); } else throw Py.JavaError(e); }
3
            
// in src/com/ziclix/python/sql/connect/Connectx.java
catch (InvocationTargetException e) { throw zxJDBC.makeException("invocation target exception for " + exceptionMsg); }
// in src/org/python/core/PyReflectedConstructor.java
catch (InvocationTargetException e) { if (e.getTargetException() instanceof InstantiationException) { Class<?> sup = proxy.getSuperclass(); String msg = "Constructor failed for Java superclass"; if (sup != null) { msg += " " + sup.getName(); } throw Py.TypeError(msg); } else throw Py.JavaError(e); }
0
unknown (Lib) LinkageError 0 0 0 1
            
// in src/org/python/core/Py.java
catch (LinkageError e) { throw JavaError(e); }
1
            
// in src/org/python/core/Py.java
catch (LinkageError e) { throw JavaError(e); }
0
unknown (Lib) MalformedURLException 0 0 0 2
            
// in src/org/python/core/SyspathJavaLoader.java
catch (MalformedURLException e) { throw new RuntimeException(e); }
// in src/org/python/core/SyspathJavaLoader.java
catch (MalformedURLException e) { throw new RuntimeException(e); }
2
            
// in src/org/python/core/SyspathJavaLoader.java
catch (MalformedURLException e) { throw new RuntimeException(e); }
// in src/org/python/core/SyspathJavaLoader.java
catch (MalformedURLException e) { throw new RuntimeException(e); }
2
unknown (Lib) MismatchedTokenException 2
            
// in src/org/python/antlr/FailFastHandler.java
public boolean mismatch(BaseRecognizer br, IntStream input, int ttype, BitSet follow) throws RecognitionException { throw new MismatchedTokenException(ttype, input); }
// in src/org/python/antlr/FailFastHandler.java
public Object recoverFromMismatchedToken(BaseRecognizer br, IntStream input, int ttype, BitSet follow) throws RecognitionException { throw new MismatchedTokenException(ttype, input); }
0 0 0 0 0
unknown (Lib) MissingResourceException 0 0 0 3
            
// in src/com/ziclix/python/sql/zxJDBC.java
catch (MissingResourceException e) { throw new RuntimeException("missing zxjdbc resource bundle"); }
// in src/com/ziclix/python/sql/zxJDBC.java
catch (MissingResourceException e) { break; }
// in src/com/ziclix/python/sql/zxJDBC.java
catch (MissingResourceException e) { return key; }
1
            
// in src/com/ziclix/python/sql/zxJDBC.java
catch (MissingResourceException e) { throw new RuntimeException("missing zxjdbc resource bundle"); }
1
unknown (Lib) NamingException 0 0 0 2
            
// in src/com/ziclix/python/sql/connect/Lookup.java
catch (NamingException e) { throw zxJDBC.makeException(zxJDBC.DatabaseError, e); }
// in src/com/ziclix/python/sql/connect/Lookup.java
catch (NamingException e) { // ok }
1
            
// in src/com/ziclix/python/sql/connect/Lookup.java
catch (NamingException e) { throw zxJDBC.makeException(zxJDBC.DatabaseError, e); }
0
unknown (Lib) NoClassDefFoundError 0 0 0 2
            
// in src/org/python/core/Py.java
catch (NoClassDefFoundError e) { // e.printStackTrace(); return null; }
// in src/org/python/core/imp.java
catch (NoClassDefFoundError e) { throw Py.ImportError("Cannot import " + name + ", missing class " + c.getName()); }
1
            
// in src/org/python/core/imp.java
catch (NoClassDefFoundError e) { throw Py.ImportError("Cannot import " + name + ", missing class " + c.getName()); }
0
unknown (Lib) NoSuchAlgorithmException 0 0 0 1
            
// in src/org/python/modules/_hashlib.java
catch (NoSuchAlgorithmException nsae) { throw Py.ValueError("unsupported hash type"); }
1
            
// in src/org/python/modules/_hashlib.java
catch (NoSuchAlgorithmException nsae) { throw Py.ValueError("unsupported hash type"); }
0
unknown (Lib) NoSuchElementException 1
            
// in src/org/python/core/WrappedIterIterator.java
public PyObject getNext() { if (!hasNext()) { throw new NoSuchElementException("End of the line, bub"); } PyObject toReturn = next; checkedForNext = false; next = null; return toReturn; }
0 0 1
            
// in src/org/python/core/PySet.java
catch (NoSuchElementException e) { throw new PyException(Py.KeyError, "pop from an empty set"); }
1
            
// in src/org/python/core/PySet.java
catch (NoSuchElementException e) { throw new PyException(Py.KeyError, "pop from an empty set"); }
1
unknown (Lib) NoSuchFieldException 0 0 0 3
            
// in src/com/ziclix/python/sql/connect/Connectx.java
catch (NoSuchMethodException e) { Class<?> primitive = null; try { Field f = valueClass.getField("TYPE"); primitive = (Class<?>) f.get(valueClass); } catch (NoSuchFieldException ex) { } catch (IllegalAccessException ex) { } catch (ClassCastException ex) { } if (primitive != null && primitive.isPrimitive()) { return getMethod(srcClass, methodName, primitive); } }
// in src/com/ziclix/python/sql/connect/Connectx.java
catch (NoSuchFieldException ex) { }
// in src/com/ziclix/python/sql/connect/Lookup.java
catch (NoSuchFieldException e) { fieldname = keyword; }
// in src/org/python/core/PyBeanEventProperty.java
catch (NoSuchFieldException exc) { throw Py.AttributeError("Internal bean event error: " + __name__); }
1
            
// in src/org/python/core/PyBeanEventProperty.java
catch (NoSuchFieldException exc) { throw Py.AttributeError("Internal bean event error: " + __name__); }
0
unknown (Lib) NoSuchMethodError 0 0 0 1
            
// in src/org/python/core/PyObject.java
catch (NoSuchMethodError nsme) { throw Py.TypeError("constructor requires arguments"); }
1
            
// in src/org/python/core/PyObject.java
catch (NoSuchMethodError nsme) { throw Py.TypeError("constructor requires arguments"); }
0
unknown (Lib) NoSuchMethodException 3
            
// in src/org/python/jsr223/PyScriptEngine.java
public Object invokeMethod(Object thiz, String name, Object... args) throws ScriptException, NoSuchMethodException { try { interp.setLocals(new PyScriptEngineScope(this, context)); if (!(thiz instanceof PyObject)) { thiz = Py.java2py(thiz); } PyObject method = ((PyObject) thiz).__findattr__(name); if (method == null) { throw new NoSuchMethodException(name); } //return method.__call__(Py.javas2pys(args)).__tojava__(Object.class); PyObject result; if(args != null) { result = method.__call__(Py.javas2pys(args)); } else { result = method.__call__(); } return result.__tojava__(Object.class); } catch (PyException pye) { throw scriptException(pye); } }
// in src/org/python/jsr223/PyScriptEngine.java
public Object invokeFunction(String name, Object... args) throws ScriptException, NoSuchMethodException { try { interp.setLocals(new PyScriptEngineScope(this, context)); PyObject function = interp.get(name); if (function == null) { throw new NoSuchMethodException(name); } return function.__call__(Py.javas2pys(args)).__tojava__(Object.class); } catch (PyException pye) { throw scriptException(pye); } }
// in src/org/python/jsr223/PyScriptEngine.java
public Object invoke(Object proxy, Method method, Object[] args) throws Throwable { try { interp.setLocals(new PyScriptEngineScope(PyScriptEngine.this, context)); PyObject pyMethod = thiz.__findattr__(method.getName()); if (pyMethod == null) throw new NoSuchMethodException(method.getName()); PyObject result = pyMethod.__call__(Py.javas2pys(args)); return result.__tojava__(Object.class); } catch (PyException pye) { throw scriptException(pye); } }
0 4
            
// in src/org/python/jsr223/PyScriptEngine.java
public Object invokeMethod(Object thiz, String name, Object... args) throws ScriptException, NoSuchMethodException { try { interp.setLocals(new PyScriptEngineScope(this, context)); if (!(thiz instanceof PyObject)) { thiz = Py.java2py(thiz); } PyObject method = ((PyObject) thiz).__findattr__(name); if (method == null) { throw new NoSuchMethodException(name); } //return method.__call__(Py.javas2pys(args)).__tojava__(Object.class); PyObject result; if(args != null) { result = method.__call__(Py.javas2pys(args)); } else { result = method.__call__(); } return result.__tojava__(Object.class); } catch (PyException pye) { throw scriptException(pye); } }
// in src/org/python/jsr223/PyScriptEngine.java
public Object invokeFunction(String name, Object... args) throws ScriptException, NoSuchMethodException { try { interp.setLocals(new PyScriptEngineScope(this, context)); PyObject function = interp.get(name); if (function == null) { throw new NoSuchMethodException(name); } return function.__call__(Py.javas2pys(args)).__tojava__(Object.class); } catch (PyException pye) { throw scriptException(pye); } }
// in src/org/python/core/CodeLoader.java
public static PyCode loadCode(Class<?> cls, String name, String filename) throws SecurityException, NoSuchMethodException, IllegalArgumentException, IllegalAccessException, InvocationTargetException { Method getBootstrap = cls.getMethod(GET_BOOTSTRAP_METHOD_NAME); CodeBootstrap bootstrap = (CodeBootstrap) getBootstrap.invoke(null); return loadCode(bootstrap, name, filename); }
// in src/org/python/core/CodeLoader.java
public static PyCode loadCode(Class<?> cls) throws SecurityException, IllegalArgumentException, NoSuchMethodException, IllegalAccessException, InvocationTargetException { return loadCode(cls, null, null); }
4
            
// in src/com/ziclix/python/sql/connect/Connectx.java
catch (NoSuchMethodException e) { Class<?> primitive = null; try { Field f = valueClass.getField("TYPE"); primitive = (Class<?>) f.get(valueClass); } catch (NoSuchFieldException ex) { } catch (IllegalAccessException ex) { } catch (ClassCastException ex) { } if (primitive != null && primitive.isPrimitive()) { return getMethod(srcClass, methodName, primitive); } }
// in src/org/python/compiler/ProxyMaker.java
catch (NoSuchMethodException e) { // OK, no one else defines it, so we need to }
// in src/org/python/core/PyJavaType.java
catch (NoSuchMethodException e) { return null; }
// in src/org/python/core/Py.java
catch (NoSuchMethodException e) { throw Py.JavaError(e); }
1
            
// in src/org/python/core/Py.java
catch (NoSuchMethodException e) { throw Py.JavaError(e); }
0
runtime (Lib) NullPointerException 2
            
// in src/org/python/core/FilelikeInputStream.java
public int read(byte b[], int off, int len) throws IOException { if(b == null) { throw new NullPointerException(); } else if((off < 0) || (off > b.length) || (len < 0) || ((off + len) > b.length) || ((off + len) < 0)) { throw new IndexOutOfBoundsException(); } else if(len == 0) { return 0; } String result = ((PyString) filelike.__getattr__("read") .__call__(new PyInteger(len))).getString(); if(result.length() == 0) { return -1; } System.arraycopy(StringUtil.toBytes(result), 0, b, off, result.length()); return result.length(); }
// in src/org/python/core/io/TextIOInputStream.java
Override public int read(byte[] b, int off, int len) throws IOException { if (b == null) { throw new NullPointerException(); } else if ((off < 0) || (off > b.length) || (len < 0) || ((off + len) > b.length) || ((off + len) < 0)) { throw new IndexOutOfBoundsException(); } else if (len == 0) { return 0; } String result = textIO.read(len); len = result.length(); for (int i = 0; i < len; i++) { b[off + i] = (byte)result.charAt(i); } return len == 0 ? -1 : len; }
0 0 0 0 0
unknown (Lib) NumberFormatException 1
            
// in src/org/python/core/PyString.java
public double atof() { StringBuilder s = null; int n = getString().length(); for (int i = 0; i < n; i++) { char ch = getString().charAt(i); if (ch == '\u0000') { throw Py.ValueError("null byte in argument for float()"); } if (Character.isDigit(ch)) { if (s == null) s = new StringBuilder(getString()); int val = Character.digit(ch, 10); s.setCharAt(i, Character.forDigit(val, 10)); } } String sval = getString(); if (s != null) sval = s.toString(); try { // Double.valueOf allows format specifier ("d" or "f") at the end String lowSval = sval.toLowerCase(); if (lowSval.equals("nan")) return Double.NaN; else if (lowSval.equals("inf")) return Double.POSITIVE_INFINITY; else if (lowSval.equals("-inf")) return Double.NEGATIVE_INFINITY; if (lowSval.endsWith("d") || lowSval.endsWith("f")) { throw new NumberFormatException("format specifiers not allowed"); } return Double.valueOf(sval).doubleValue(); } catch (NumberFormatException exc) { throw Py.ValueError("invalid literal for __float__: "+getString()); } }
0 0 8
            
// in src/org/python/modules/ucnhash.java
catch (NumberFormatException exc) { return -1; // Maybe fallthrough to the main algorithme. }
// in src/org/python/modules/cPickle.java
catch(NumberFormatException e) { try { value = Py.newLong(line); } catch(NumberFormatException e2) { throw Py.ValueError("could not convert string to int"); } }
// in src/org/python/modules/cPickle.java
catch(NumberFormatException e2) { throw Py.ValueError("could not convert string to int"); }
// in src/org/python/core/stringlib/FieldNameIterator.java
catch (NumberFormatException e) { this.head = headStr;
// in src/org/python/core/stringlib/FieldNameIterator.java
catch (NumberFormatException e) { chunk.value = itemValue; }
// in src/org/python/core/PyString.java
catch (NumberFormatException exc) { throw Py.ValueError("invalid literal for __float__: "+getString()); }
// in src/org/python/core/PyString.java
catch (NumberFormatException exc) { throw Py.ValueError("invalid literal for int() with base " + base + ": " + getString()); }
// in src/org/python/core/PyString.java
catch (NumberFormatException exc) { if (this instanceof PyUnicode) { // TODO: here's a basic issue: do we use the BigInteger constructor // above, or add an equivalent to CPython's PyUnicode_EncodeDecimal; // we should note that the current error string does not quite match // CPython regardless of the codec, that's going to require some more work throw Py.UnicodeEncodeError("decimal", "codec can't encode character", 0,0, "invalid decimal Unicode string"); } else { throw Py.ValueError("invalid literal for long() with base " + base + ": " + getString()); } }
5
            
// in src/org/python/modules/cPickle.java
catch(NumberFormatException e) { try { value = Py.newLong(line); } catch(NumberFormatException e2) { throw Py.ValueError("could not convert string to int"); } }
// in src/org/python/modules/cPickle.java
catch(NumberFormatException e2) { throw Py.ValueError("could not convert string to int"); }
// in src/org/python/core/PyString.java
catch (NumberFormatException exc) { throw Py.ValueError("invalid literal for __float__: "+getString()); }
// in src/org/python/core/PyString.java
catch (NumberFormatException exc) { throw Py.ValueError("invalid literal for int() with base " + base + ": " + getString()); }
// in src/org/python/core/PyString.java
catch (NumberFormatException exc) { if (this instanceof PyUnicode) { // TODO: here's a basic issue: do we use the BigInteger constructor // above, or add an equivalent to CPython's PyUnicode_EncodeDecimal; // we should note that the current error string does not quite match // CPython regardless of the codec, that's going to require some more work throw Py.UnicodeEncodeError("decimal", "codec can't encode character", 0,0, "invalid decimal Unicode string"); } else { throw Py.ValueError("invalid literal for long() with base " + base + ": " + getString()); } }
0
unknown (Lib) OutOfMemoryError 0 0 0 1
            
// in src/org/python/indexer/Indexer.java
catch (OutOfMemoryError e) { if (astCache != null) { astCache.clear(); } System.gc(); return null; }
0 0
runtime (Domain) ParseException
public class ParseException extends RuntimeException {
	public transient IntStream input;
	public int index;
	public Token token;
	public Object node;
	public int c;
	public int line;
	public int charPositionInLine;
	public boolean approximateLineInfo;

    private PyObject type = Py.SyntaxError;

    public ParseException() {
        super();
    }

    public ParseException(String message, int lin, int charPos) {
        super(message);
        this.line = lin;
        this.charPositionInLine = charPos;
    }

    public ParseException(String message) {
        this(message, 0, 0);
    }

    /**
     * n must not be null to use this constructor
     */
    public ParseException(String message, PythonTree n) {
        this(message, n.getLine(), n.getCharPositionInLine());
        this.node = n;
        this.token = n.getToken();
    }

    public ParseException(String message, RecognitionException r) {
        super(message);
        this.input = r.input;
        this.index = r.index;
        this.token = r.token;
        this.node = r.node;
        this.c = r.c;
        this.line = r.line;
        this.charPositionInLine = r.charPositionInLine;
        this.approximateLineInfo = r.approximateLineInfo;
    }

    public void setType(PyObject t) {
        this.type = t;
    }

    public PyObject getType() {
        return this.type;
    }

}
38
            
// in src/org/python/compiler/ScopeInfo.java
public void defineAsGenerator(expr node) { generator = true; if (hasReturnWithValue) { throw new ParseException("'return' with argument " + "inside generator", node); } }
// in src/org/python/compiler/ScopeInfo.java
public void noteReturnValue(Return node) { if (generator) { throw new ParseException("'return' with argument " + "inside generator", node); } hasReturnWithValue = true; }
// in src/org/python/compiler/Future.java
private boolean check(ImportFrom cand) throws Exception { if (!cand.getInternalModule().equals(FutureFeature.MODULE_NAME)) return false; if (cand.getInternalNames().isEmpty()) { throw new ParseException( "future statement does not support import *", cand); } try { for (alias feature : cand.getInternalNames()) { // *known* features FutureFeature.addFeature(feature.getInternalName(), features); } } catch (ParseException pe) { throw new ParseException(pe.getMessage(), cand); } return true; }
// in src/org/python/compiler/Future.java
public static void checkFromFuture(ImportFrom node) throws Exception { if (node.from_future_checked) return; if (node.getInternalModule().equals(FutureFeature.MODULE_NAME)) { throw new ParseException("from __future__ imports must occur " + "at the beginning of the file", node); } node.from_future_checked = true; }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitBreak(Break node) throws Exception { //setline(node); Not needed here... if (breakLabels.empty()) { throw new ParseException("'break' outside loop", node); } doFinallysDownTo(bcfLevel); code.goto_(breakLabels.peek()); return null; }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitContinue(Continue node) throws Exception { //setline(node); Not needed here... if (continueLabels.empty()) { throw new ParseException("'continue' not properly in loop", node); } doFinallysDownTo(bcfLevel); code.goto_(continueLabels.peek()); return Exit; }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitYield(Yield node) throws Exception { setline(node); if (!fast_locals) { throw new ParseException("'yield' outside function", node); } int stackState = saveStack(); if (node.getInternalValue() != null) { visit(node.getInternalValue()); } else { getNone(); } setLastI(++yield_count); saveLocals(); code.areturn(); Label restart = new Label(); yields.addElement(restart); code.label(restart); restoreLocals(); restoreStack(stackState); loadFrame(); code.invokevirtual(p(PyFrame.class), "getGeneratorInput", sig(Object.class)); code.dup(); code.instanceof_(p(PyException.class)); Label done2 = new Label(); code.ifeq(done2); code.checkcast(p(Throwable.class)); code.athrow(); code.label(done2); code.checkcast(p(PyObject.class)); return null; }
// in src/org/python/compiler/CodeCompiler.java
public Object visitReturn(Return node, boolean inEval) throws Exception { setline(node); if (!inEval && !fast_locals) { throw new ParseException("'return' outside function", node); } int tmp = 0; if (node.getInternalValue() != null) { if (my_scope.generator) { throw new ParseException("'return' with argument " + "inside generator", node); } visit(node.getInternalValue()); tmp = code.getReturnLocal(); code.astore(tmp); } doFinallysDownTo(0); setLastI(-1); if (node.getInternalValue() != null) { code.aload(tmp); } else { getNone(); } code.areturn(); return Exit; }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitImportFrom(ImportFrom node) throws Exception { Future.checkFromFuture(node); // future stmt support setline(node); code.ldc(node.getInternalModule()); java.util.List<alias> aliases = node.getInternalNames(); if (aliases == null || aliases.size() == 0) { throw new ParseException("Internel parser error", node); } else if (aliases.size() == 1 && aliases.get(0).getInternalName().equals("*")) { if (node.getInternalLevel() > 0) { throw new ParseException("'import *' not allowed with 'from .'", node); } if (my_scope.func_level > 0) { module.error("import * only allowed at module level", false, node); if (my_scope.contains_ns_free_vars) { module.error("import * is not allowed in function '" + my_scope.scope_name + "' because it contains a nested function with free variables", true, node); } } if (my_scope.func_level > 1) { module.error("import * is not allowed in function '" + my_scope.scope_name + "' because it is a nested function", true, node); } loadFrame(); defaultImportLevel(); code.invokestatic(p(imp.class), "importAll", sig(Void.TYPE, String.class, PyFrame.class, Integer.TYPE)); } else { java.util.List<String> fromNames = new ArrayList<String>();//[names.size()]; java.util.List<String> asnames = new ArrayList<String>();//[names.size()]; for (int i = 0; i < aliases.size(); i++) { fromNames.add(aliases.get(i).getInternalName()); asnames.add(aliases.get(i).getInternalAsname()); if (asnames.get(i) == null) { asnames.set(i, fromNames.get(i)); } } int strArray = makeStrings(code, fromNames); code.aload(strArray); code.freeLocal(strArray); loadFrame(); if (node.getInternalLevel() == 0) { defaultImportLevel(); } else { code.iconst(node.getInternalLevel()); } code.invokestatic(p(imp.class), "importFrom", sig(PyObject[].class, String.class, String[].class, PyFrame.class, Integer.TYPE)); int tmp = storeTop(); for (int i = 0; i < aliases.size(); i++) { code.aload(tmp); code.iconst(i); code.aaload(); set(new Name(aliases.get(i), asnames.get(i), expr_contextType.Store)); } code.freeLocal(tmp); } return null; }
// in src/org/python/compiler/CodeCompiler.java
public void exceptionTest(int exc, Label end_of_exceptions, TryExcept node, int index) throws Exception { for (int i = 0; i < node.getInternalHandlers().size(); i++) { ExceptHandler handler = (ExceptHandler) node.getInternalHandlers().get(i); //setline(name); Label end_of_self = new Label(); if (handler.getInternalType() != null) { code.aload(exc); //get specific exception visit(handler.getInternalType()); code.invokevirtual(p(PyException.class), "match", sig(Boolean.TYPE, PyObject.class)); code.ifeq(end_of_self); } else { if (i != node.getInternalHandlers().size() - 1) { throw new ParseException( "default 'except:' must be last", handler); } } if (handler.getInternalName() != null) { code.aload(exc); code.getfield(p(PyException.class), "value", ci(PyObject.class)); set(handler.getInternalName()); } //do exception body suite(handler.getInternalBody()); code.goto_(end_of_exceptions); code.label(end_of_self); } code.aload(exc); code.athrow(); }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitName(Name node) throws Exception { String name; if (fast_locals) { name = node.getInternalId(); } else { name = getName(node.getInternalId()); } SymInfo syminf = tbl.get(name); expr_contextType ctx = node.getInternalCtx(); if (ctx == expr_contextType.AugStore) { ctx = augmode; } switch (ctx) { case Load: loadFrame(); if (syminf != null) { int flags = syminf.flags; if ((flags & ScopeInfo.GLOBAL) != 0 || optimizeGlobals && (flags & (ScopeInfo.BOUND | ScopeInfo.CELL | ScopeInfo.FREE)) == 0) { emitGetGlobal(name); return null; } if (fast_locals) { if ((flags & ScopeInfo.CELL) != 0) { code.iconst(syminf.env_index); code.invokevirtual(p(PyFrame.class), "getderef", sig(PyObject.class, Integer.TYPE)); return null; } if ((flags & ScopeInfo.BOUND) != 0) { code.iconst(syminf.locals_index); code.invokevirtual(p(PyFrame.class), "getlocal", sig(PyObject.class, Integer.TYPE)); return null; } } if ((flags & ScopeInfo.FREE) != 0 && (flags & ScopeInfo.BOUND) == 0) { code.iconst(syminf.env_index); code.invokevirtual(p(PyFrame.class), "getderef", sig(PyObject.class, Integer.TYPE)); return null; } } code.ldc(name); code.invokevirtual(p(PyFrame.class), "getname", sig(PyObject.class, String.class)); return null; case Param: case Store: loadFrame(); if (syminf != null && (syminf.flags & ScopeInfo.GLOBAL) != 0) { code.ldc(name); code.aload(temporary); code.invokevirtual(p(PyFrame.class), "setglobal", sig(Void.TYPE, String.class, PyObject.class)); } else { if (!fast_locals) { code.ldc(name); code.aload(temporary); code.invokevirtual(p(PyFrame.class), "setlocal", sig(Void.TYPE, String.class, PyObject.class)); } else { if (syminf == null) { throw new ParseException("internal compiler error", node); } if ((syminf.flags & ScopeInfo.CELL) != 0) { code.iconst(syminf.env_index); code.aload(temporary); code.invokevirtual(p(PyFrame.class), "setderef", sig(Void.TYPE, Integer.TYPE, PyObject.class)); } else { code.iconst(syminf.locals_index); code.aload(temporary); code.invokevirtual(p(PyFrame.class), "setlocal", sig(Void.TYPE, Integer.TYPE, PyObject.class)); } } } return null; case Del: { loadFrame(); if (syminf != null && (syminf.flags & ScopeInfo.GLOBAL) != 0) { code.ldc(name); code.invokevirtual(p(PyFrame.class), "delglobal", sig(Void.TYPE, String.class)); } else { if (!fast_locals) { code.ldc(name); code.invokevirtual(p(PyFrame.class), "dellocal", sig(Void.TYPE, String.class)); } else { if (syminf == null) { throw new ParseException("internal compiler error", node); } if ((syminf.flags & ScopeInfo.CELL) != 0) { module.error("can not delete variable '" + name + "' referenced in nested scope", true, node); } code.iconst(syminf.locals_index); code.invokevirtual(p(PyFrame.class), "dellocal", sig(Void.TYPE, Integer.TYPE)); } } return null; } } return null; }
// in src/org/python/compiler/CodeCompiler.java
Override public Object visitWith(With node) throws Exception { if (!module.getFutures().withStatementSupported()) { throw new ParseException("'with' will become a reserved keyword in Python 2.6", node); } final Label label_body_start = new Label(); final Label label_body_end = new Label(); final Label label_catch = new Label(); final Label label_end = new Label(); final Method contextGuard_getManager = Method.getMethod( "org.python.core.ContextManager getManager (org.python.core.PyObject)"); final Method __enter__ = Method.getMethod( "org.python.core.PyObject __enter__ (org.python.core.ThreadState)"); final Method __exit__ = Method.getMethod( "boolean __exit__ (org.python.core.ThreadState,org.python.core.PyException)"); // mgr = (EXPR) visit(node.getInternalContext_expr()); // wrap the manager with the ContextGuard (or get it directly if it // supports the ContextManager interface) code.invokestatic(Type.getType(ContextGuard.class).getInternalName(), contextGuard_getManager.getName(), contextGuard_getManager.getDescriptor()); code.dup(); final int mgr_tmp = code.getLocal(Type.getType(ContextManager.class).getInternalName()); code.astore(mgr_tmp); // value = mgr.__enter__() loadThreadState(); code.invokeinterface(Type.getType(ContextManager.class).getInternalName(), __enter__.getName(), __enter__.getDescriptor()); int value_tmp = code.getLocal(p(PyObject.class)); code.astore(value_tmp); // exc = True # not necessary, since we don't exec finally if exception // FINALLY (preparation) // ordinarily with a finally, we need to duplicate the code. that's not the case // here // # The normal and non-local-goto cases are handled here // if exc: # implicit // exit(None, None, None) ExceptionHandler normalExit = new ExceptionHandler() { @Override public boolean isFinallyHandler() { return true; } @Override public void finalBody(CodeCompiler compiler) throws Exception { compiler.code.aload(mgr_tmp); loadThreadState(); compiler.code.aconst_null(); compiler.code.invokeinterface(Type.getType(ContextManager.class).getInternalName(), __exit__.getName(), __exit__.getDescriptor()); compiler.code.pop(); } }; exceptionHandlers.push(normalExit); // try-catch block here ExceptionHandler handler = new ExceptionHandler(); exceptionHandlers.push(handler); handler.exceptionStarts.addElement(label_body_start); // VAR = value # Only if "as VAR" is present code.label(label_body_start); if (node.getInternalOptional_vars() != null) { set(node.getInternalOptional_vars(), value_tmp); } code.freeLocal(value_tmp); // BLOCK + FINALLY if non-local-goto Object blockResult = suite(node.getInternalBody()); normalExit.bodyDone = true; exceptionHandlers.pop(); exceptionHandlers.pop(); code.label(label_body_end); handler.exceptionEnds.addElement(label_body_end); // FINALLY if *not* non-local-goto if (blockResult == NoExit) { // BLOCK would have generated FINALLY for us if it exited (due to a break, // continue or return) inlineFinally(normalExit); code.goto_(label_end); } // CATCH code.label(label_catch); loadFrame(); code.invokestatic(p(Py.class), "setException", sig(PyException.class, Throwable.class, PyFrame.class)); code.aload(mgr_tmp); code.swap(); loadThreadState(); code.swap(); code.invokeinterface(Type.getType(ContextManager.class).getInternalName(), __exit__.getName(), __exit__.getDescriptor()); // # The exceptional case is handled here // exc = False # implicit // if not exit(*sys.exc_info()): code.ifne(label_end); // raise // # The exception is swallowed if exit() returns true code.invokestatic(p(Py.class), "makeException", sig(PyException.class)); code.checkcast(p(Throwable.class)); code.athrow(); code.label(label_end); code.freeLocal(mgr_tmp); handler.addExceptionHandlers(label_catch); return null; }
// in src/org/python/compiler/Module.java
public void error(String msg, boolean err, PythonTree node) throws Exception { if (!err) { try { Py.warning(Py.SyntaxWarning, msg, (sfilename != null) ? sfilename : "?", node.getLine(), null, Py.None); return; } catch (PyException e) { if (!e.match(Py.SyntaxWarning)) { throw e; } } } throw new ParseException(msg, node); }
// in src/org/python/compiler/ArgListCompiler.java
public void visitArgs(arguments args) throws Exception { for (int i = 0; i < args.getInternalArgs().size(); i++) { String name = (String) visit(args.getInternalArgs().get(i)); names.add(name); if (args.getInternalArgs().get(i) instanceof Tuple) { List<expr> targets = new ArrayList<expr>(); targets.add(args.getInternalArgs().get(i)); Assign ass = new Assign(args.getInternalArgs().get(i), targets, new Name(args.getInternalArgs().get(i), name, expr_contextType.Load)); init_code.add(ass); } } if (args.getInternalVararg() != null) { arglist = true; names.add(args.getInternalVararg()); } if (args.getInternalKwarg() != null) { keywordlist = true; names.add(args.getInternalKwarg()); } defaults = args.getInternalDefaults(); for (int i = 0; i < defaults.size(); i++) { if (defaults.get(i) == null) throw new ParseException( "non-default argument follows default argument", args.getInternalArgs().get(args.getInternalArgs().size() - defaults.size() + i)); } }
// in src/org/python/compiler/ArgListCompiler.java
Override public Object visitName(Name node) throws Exception { //FIXME: do we need Store and Param, or just Param? if (node.getInternalCtx() != expr_contextType.Store && node.getInternalCtx() != expr_contextType.Param) { return null; } if (fpnames.contains(node.getInternalId())) { throw new ParseException("duplicate argument name found: " + node.getInternalId(), node); } fpnames.add(node.getInternalId()); return node.getInternalId(); }
// in src/org/python/antlr/FailFastHandler.java
public void reportError(BaseRecognizer br, RecognitionException re) { throw new ParseException(message(br,re), re); }
// in src/org/python/antlr/FailFastHandler.java
public void recover(Lexer lex, RecognitionException re) { throw new ParseException(message(lex,re), re); }
// in src/org/python/antlr/FailFastHandler.java
public void recover(BaseRecognizer br, IntStream input, RecognitionException re) { throw new ParseException(message(br,re), re); }
// in src/org/python/antlr/FailFastHandler.java
public expr errorExpr(PythonTree t) { throw new ParseException("Bad Expr Node", t); }
// in src/org/python/antlr/FailFastHandler.java
public mod errorMod(PythonTree t) { throw new ParseException("Bad Mod Node", t); }
// in src/org/python/antlr/FailFastHandler.java
public slice errorSlice(PythonTree t) { throw new ParseException("Bad Slice Node", t); }
// in src/org/python/antlr/FailFastHandler.java
public stmt errorStmt(PythonTree t) { throw new ParseException("Bad Stmt Node", t); }
// in src/org/python/antlr/FailFastHandler.java
public void error(String message, PythonTree t) { throw new ParseException(message, t); }
// in src/org/python/core/FutureFeature.java
Override public Pragma getStarPragma() { throw new ParseException("future feature * is not defined"); }
// in src/org/python/core/FutureFeature.java
private static FutureFeature getFeature(String featureName) { try { return valueOf(featureName); } catch (IllegalArgumentException ex) { throw new ParseException("future feature " + featureName + " is not defined"); } }
// in src/org/python/core/ParserFacade.java
private static ExpectedEncodingBufferedReader prepBufReader(Reader reader, CompilerFlags cflags, String filename) throws IOException { cflags.source_is_utf8 = true; cflags.encoding = "utf-8"; BufferedReader bufferedReader = new BufferedReader(reader); bufferedReader.mark(MARK_LIMIT); if (findEncoding(bufferedReader) != null) throw new ParseException("encoding declaration in Unicode string"); bufferedReader.reset(); return new ExpectedEncodingBufferedReader(bufferedReader, null); }
// in src/org/python/core/ParserFacade.java
private static ExpectedEncodingBufferedReader prepBufReader(InputStream input, CompilerFlags cflags, String filename, boolean fromString, boolean universalNewlines) throws IOException { input = new BufferedInputStream(input); boolean bom = adjustForBOM(input); String encoding = readEncoding(input); if (encoding == null) { if (bom) { encoding = "utf-8"; } else if (cflags != null && cflags.encoding != null) { encoding = cflags.encoding; } } if (cflags.source_is_utf8) { if (encoding != null) { throw new ParseException("encoding declaration in Unicode string"); } encoding = "utf-8"; } cflags.encoding = encoding; if (universalNewlines) { // Enable universal newlines mode on the input StreamIO rawIO = new StreamIO(input, true); org.python.core.io.BufferedReader bufferedIO = new org.python.core.io.BufferedReader(rawIO, 0); UniversalIOWrapper textIO = new UniversalIOWrapper(bufferedIO); input = new TextIOInputStream(textIO); } Charset cs; try { // Use ascii for the raw bytes when no encoding was specified if (encoding == null) { if (fromString) { cs = Charset.forName("ISO-8859-1"); } else { cs = Charset.forName("ascii"); } } else { cs = Charset.forName(encoding); } } catch (UnsupportedCharsetException exc) { throw new PySyntaxError("Unknown encoding: " + encoding, 1, 0, "", filename); } CharsetDecoder dec = cs.newDecoder(); dec.onMalformedInput(CodingErrorAction.REPORT); dec.onUnmappableCharacter(CodingErrorAction.REPORT); return new ExpectedEncodingBufferedReader(new InputStreamReader(input, dec), encoding); }
// in src/org/python/core/ParserFacade.java
private static boolean adjustForBOM(InputStream stream) throws IOException { stream.mark(3); int ch = stream.read(); if (ch == 0xEF) { if (stream.read() != 0xBB) { throw new ParseException("Incomplete BOM at beginning of file"); } if (stream.read() != 0xBF) { throw new ParseException("Incomplete BOM at beginning of file"); } return true; } stream.reset(); return false; }
// in src/org/python/core/Pragma.java
Override public Pragma getPragma(String name) { throw new ParseException(message); }
// in src/org/python/core/Pragma.java
Override public Pragma getStarPragma() { throw new ParseException(message); }
// in src/org/python/core/Pragma.java
public void addTo(PragmaReceiver receiver) { throw new ParseException(message); }
2
            
// in src/org/python/compiler/Future.java
catch (ParseException pe) { throw new ParseException(pe.getMessage(), cand); }
// in src/org/python/core/FutureFeature.java
catch (IllegalArgumentException ex) { throw new ParseException("future feature " + featureName + " is not defined"); }
0 2
            
// in src/org/python/compiler/Future.java
catch (ParseException pe) { throw new ParseException(pe.getMessage(), cand); }
// in src/org/python/modules/time/Time.java
catch (ParseException e) { throwValueError("time data did not match format: data=" + data_string + " fmt=" + format); }
1
            
// in src/org/python/compiler/Future.java
catch (ParseException pe) { throw new ParseException(pe.getMessage(), cand); }
1
runtime (Domain) PyException
public class PyException extends RuntimeException
{

    /**
     * The python exception class (for class exception) or identifier (for string exception).
     */
    public PyObject type;

    /**
     * The exception instance (for class exception) or exception value (for string exception).
     */
    public PyObject value = Py.None;

    /** The exception traceback object. */
    public PyTraceback traceback;

    /**
     * Whether the exception was re-raised, such as when a traceback is specified to
     * 'raise', or via a 'finally' block.
     */
    private boolean isReRaise = false;

    private boolean normalized = false;

    public PyException() {
        this(Py.None, Py.None);
    }

    public PyException(PyObject type) {
        this(type, Py.None);
    }

    public PyException(PyObject type, PyObject value) {
        this(type, value, null);
    }

    public PyException(PyObject type, PyObject value, PyTraceback traceback) {
        this.type = type;
        this.value = value;
        if (traceback != null) {
            this.traceback = traceback;
            isReRaise = true;
        } else {
            PyFrame frame = Py.getFrame();
            if (frame != null && frame.tracefunc != null) {
                frame.tracefunc = frame.tracefunc.traceException(frame, this);
            }
        }
    }

    public PyException(PyObject type, String value) {
        this(type, new PyString(value));
    }

    private boolean printingStackTrace = false;
    public void printStackTrace() {
        Py.printException(this);
    }

    public Throwable fillInStackTrace() {
        return Options.includeJavaStackInExceptions ? super.fillInStackTrace() : this;
    }

    public synchronized void printStackTrace(PrintStream s) {
        if (printingStackTrace) {
            super.printStackTrace(s);
        } else {
            try {
                printingStackTrace = true;
                Py.displayException(type, value, traceback, new PyFile(s));
            } finally {
                printingStackTrace = false;
            }
        }
    }

    public synchronized void super__printStackTrace(PrintWriter w) {
        try {
            printingStackTrace = true;
            super.printStackTrace(w);
        } finally {
            printingStackTrace = false;
        }
    }

    public synchronized String toString() {
        ByteArrayOutputStream buf = new ByteArrayOutputStream();
        if (!printingStackTrace) {
            printStackTrace(new PrintStream(buf));
        }
        return buf.toString();
    }

    /**
     * Instantiates the exception value if it is not already an
     * instance.
     *
     */
    public void normalize() {
        if (normalized) {
            return;
        }
        PyObject inClass = null;
        if (isExceptionInstance(value)) {
            inClass = value.fastGetClass();
        }

        if (isExceptionClass(type)) {
            if (inClass == null || !Py.isSubClass(inClass, type)) {
                PyObject[] args;

                // Don't decouple a tuple into args when it's a
                // KeyError, pass it on through below
                if (value == Py.None) {
                    args = Py.EmptyObjects;
                } else if (value instanceof PyTuple && type != Py.KeyError) {
                    args = ((PyTuple)value).getArray();
                } else {
                    args = new PyObject[] {value};
                }

                value = type.__call__(args);
            } else if (inClass != type) {
                type = inClass;
            }
        }
        normalized = true;
    }

    /**
     * Register frame as having been visited in the traceback.
     *
     * @param here the current PyFrame
     */
    public void tracebackHere(PyFrame here) {
        tracebackHere(here, false);
    }

    /**
     * Register frame as having been visited in the traceback.
     *
     * @param here the current PyFrame
     * @param isFinally whether caller is a Python finally block
     */
    public void tracebackHere(PyFrame here, boolean isFinally) {
        if (!isReRaise && here != null) {
            // the frame is either inapplicable or already registered (from a finally)
            // during a re-raise
            traceback = new PyTraceback(traceback, here);
        }
        // finally blocks immediately tracebackHere: so they toggle isReRaise to skip the
        // next tracebackHere hook
        isReRaise = isFinally;
    }

    /**
     * Logic for the raise statement
     *
     * @param type the first arg to raise, a type or an instance
     * @param value the second arg, the instance of the class or arguments to its
     * constructor
     * @param traceback a traceback object
     * @return a PyException wrapper
     */
    public static PyException doRaise(PyObject type, PyObject value, PyObject traceback) {
        if (type == null) {
            ThreadState state = Py.getThreadState();
            type = state.exception.type;
            value = state.exception.value;
            traceback = state.exception.traceback;
        }

        if (traceback == Py.None) {
            traceback = null;
        } else if (traceback != null && !(traceback instanceof PyTraceback)) {
            throw Py.TypeError("raise: arg 3 must be a traceback or None");
        }

        if (value == null) {
            value = Py.None;
        }

        // Repeatedly, replace a tuple exception with its first item
        while (type instanceof PyTuple && ((PyTuple)type).size() > 0) {
            type = type.__getitem__(0);
        }

        if (isExceptionClass(type)) {
            PyException pye = new PyException(type, value, (PyTraceback)traceback);
            pye.normalize();
            return pye;
        } else if (isExceptionInstance(type)) {
            // Raising an instance.  The value should be a dummy.
            if (value != Py.None) {
                throw Py.TypeError("instance exception may not have a separate value");
            } else {
                // Normalize to raise <class>, <instance>
                value = type;
                type = type.fastGetClass();
            }
        } else {
            // Not something you can raise.  You get an exception
            // anyway, just not what you specified :-)
            throw Py.TypeError("exceptions must be old-style classes or derived from "
                               + "BaseException, not " + type.getType().fastGetName());
        }

        if (Options.py3kwarning && type instanceof PyClass) {
            Py.DeprecationWarning("exceptions must derive from BaseException in 3.x");
        }

        return new PyException(type, value, (PyTraceback)traceback);
    }

    /**
     * Determine if this PyException is a match for exc.
     *
     * @param exc a PyObject exception type
     * @return true if a match
     */
    public boolean match(PyObject exc) {
        if (exc instanceof PyTuple) {
            for (PyObject item : ((PyTuple)exc).getArray()) {
                if (match(item)) {
                    return true;
                }
            }
            return false;
        }

        if (exc instanceof PyString) {
            Py.DeprecationWarning("catching of string exceptions is deprecated");
        } else if (Options.py3kwarning && !isPy3kExceptionClass(exc)) {
            Py.DeprecationWarning("catching classes that don't inherit from BaseException is not "
                                  + "allowed in 3.x");
        }

        normalize();
        // FIXME, see bug 737978
        //
        // A special case for IOError's to allow them to also match
        // java.io.IOExceptions.  This is a hack for 1.0.x until I can do
        // it right in 1.1
        if (exc == Py.IOError) {
            if (__builtin__.isinstance(value, PyType.fromClass(IOException.class))) {
                return true;
            }
        }
        // FIXME too, same approach for OutOfMemoryError
        if (exc == Py.MemoryError) {
            if (__builtin__.isinstance(value,
                                       PyType.fromClass(OutOfMemoryError.class))) {
                return true;
            }
        }

        if (isExceptionClass(type) && isExceptionClass(exc)) {
            try {
                return Py.isSubClass(type, exc);
            } catch (PyException pye) {
                // This function must not fail, so print the error here
                Py.writeUnraisable(pye, type);
                return false;
            }
        }

        return type == exc;
    }

    /**
     * Determine whether obj is a Python exception class
     *
     * @param obj a PyObject
     * @return true if an exception
     */
    public static boolean isExceptionClass(PyObject obj) {
        if (obj instanceof PyClass) {
            return true;
        }
        return isPy3kExceptionClass(obj);
    }

    /**
     * Determine whether obj is a Python 3 exception class
     *
     * @param obj a PyObject
     * @return true if an exception
     */
    private static boolean isPy3kExceptionClass(PyObject obj) {
        if (!(obj instanceof PyType)) {
            return false;
        }
        PyType type = ((PyType)obj);
        if (type.isSubType(PyBaseException.TYPE)) {
            return true;
        }
        return type.getProxyType() != null
                && Throwable.class.isAssignableFrom(type.getProxyType());
    }

    /**
     * Determine whether obj is an Python exception instance
     *
     * @param obj a PyObject
     * @return true if an exception instance
     */
    public static boolean isExceptionInstance(PyObject obj) {
        return obj instanceof PyInstance || obj instanceof PyBaseException
           || obj.getJavaProxy() instanceof Throwable;
    }

    /**
     * Get the name of the exception's class
     *
     * @param obj a PyObject exception
     * @return String exception name
     */
    public static String exceptionClassName(PyObject obj) {
        return obj instanceof PyClass ? ((PyClass)obj).__name__ : ((PyType)obj).fastGetName();
    }
}
56
            
// in src/org/python/modules/binascii.java
public static PyString a2b_uu(String ascii_data) { int leftbits = 0; int leftchar = 0; if (ascii_data.length() == 0) return new PyString(""); StringBuilder bin_data = new StringBuilder(); char this_ch; int i; int ascii_len = ascii_data.length()-1; int bin_len = (ascii_data.charAt(0) - ' ') & 077; for (i = 0; bin_len > 0 && ascii_len > 0; i++, ascii_len--) { this_ch = ascii_data.charAt(i+1); if (this_ch == '\n' || this_ch == '\r' || ascii_len <= 0) { // Whitespace. Assume some spaces got eaten at // end-of-line. (We check this later) this_ch = 0; } else { // Check the character for legality // The 64 in stead of the expected 63 is because // there are a few uuencodes out there that use // '@' as zero instead of space. if ( this_ch < ' ' || this_ch > (' ' + 64)) { throw new PyException(Error, "Illegal char"); } this_ch = (char)((this_ch - ' ') & 077); } // Shift it in on the low end, and see if there's // a byte ready for output. leftchar = (leftchar << 6) | (this_ch); leftbits += 6; if (leftbits >= 8) { leftbits -= 8; bin_data.append((char)((leftchar >> leftbits) & 0xff)); leftchar &= ((1 << leftbits) - 1); bin_len--; } } // Finally, check that if there's anything left on the line // that it's whitespace only. while (ascii_len-- > 0) { this_ch = ascii_data.charAt(++i); // Extra '@' may be written as padding in some cases if (this_ch != ' ' && this_ch != '@' && this_ch != '\n' && this_ch != '\r') { throw new PyException(Error, "Trailing garbage"); } } // finally, if we haven't decoded enough stuff, fill it up with zeros for (; i<bin_len; i++) bin_data.append((char)0); return new PyString(bin_data.toString()); }
// in src/org/python/modules/binascii.java
public static PyString b2a_uu(String bin_data) { int leftbits = 0; char this_ch; int leftchar = 0; int bin_len = bin_data.length(); if (bin_len > 45) { // The 45 is a limit that appears in all uuencode's throw new PyException(Error, "At most 45 bytes at once"); } StringBuilder ascii_data = new StringBuilder(); // Store the length */ ascii_data.append((char)(' ' + (bin_len & 077))); for (int i = 0; bin_len > 0 || leftbits != 0; i++, bin_len--) { // Shift the data (or padding) into our buffer if (bin_len > 0) // Data leftchar = (leftchar << 8) | bin_data.charAt(i); else // Padding leftchar <<= 8; leftbits += 8; // See if there are 6-bit groups ready while (leftbits >= 6) { this_ch = (char)((leftchar >> (leftbits-6)) & 0x3f); leftbits -= 6; ascii_data.append((char)(this_ch + ' ')); } } ascii_data.append('\n'); // Append a courtesy newline return new PyString(ascii_data.toString()); }
// in src/org/python/modules/binascii.java
public static PyString a2b_base64(String ascii_data) { int leftbits = 0; char this_ch; int leftchar = 0; int quad_pos = 0; int ascii_len = ascii_data.length(); int bin_len = 0; StringBuilder bin_data = new StringBuilder(); for(int i = 0; ascii_len > 0 ; ascii_len--, i++) { // Skip some punctuation this_ch = ascii_data.charAt(i); if (this_ch > 0x7F || this_ch == '\r' || this_ch == '\n' || this_ch == ' ') continue; if (this_ch == BASE64_PAD) { if (quad_pos < 2 || (quad_pos == 2 && binascii_find_valid(ascii_data, i, 1) != BASE64_PAD)) continue; else { // A pad sequence means no more input. // We've already interpreted the data // from the quad at this point. leftbits = 0; break; } } short this_v = table_a2b_base64[this_ch]; if (this_v == -1) continue; // Shift it in on the low end, and see if there's // a byte ready for output. quad_pos = (quad_pos + 1) & 0x03; leftchar = (leftchar << 6) | (this_v); leftbits += 6; if (leftbits >= 8) { leftbits -= 8; bin_data.append((char)((leftchar >> leftbits) & 0xff)); bin_len++; leftchar &= ((1 << leftbits) - 1); } } // Check that no bits are left if (leftbits != 0) { throw new PyException(Error, "Incorrect padding"); } return new PyString(bin_data.toString()); }
// in src/org/python/modules/binascii.java
public static PyString b2a_base64(String bin_data) { int leftbits = 0; char this_ch; int leftchar = 0; StringBuilder ascii_data = new StringBuilder(); int bin_len = bin_data.length(); if (bin_len > BASE64_MAXBIN) { throw new PyException(Error,"Too much data for base64 line"); } for (int i = 0; bin_len > 0 ; bin_len--, i++) { // Shift the data into our buffer leftchar = (leftchar << 8) | bin_data.charAt(i); leftbits += 8; // See if there are 6-bit groups ready while (leftbits >= 6) { this_ch = (char)((leftchar >> (leftbits-6)) & 0x3f); leftbits -= 6; ascii_data.append((char)table_b2a_base64[this_ch]); } } if (leftbits == 2) { ascii_data.append((char)table_b2a_base64[(leftchar&3) << 4]); ascii_data.append(BASE64_PAD); ascii_data.append(BASE64_PAD); } else if (leftbits == 4) { ascii_data.append((char)table_b2a_base64[(leftchar&0xf) << 2]); ascii_data.append(BASE64_PAD); } ascii_data.append('\n'); // Append a courtesy newline return new PyString(ascii_data.toString()); }
// in src/org/python/modules/binascii.java
public static PyTuple a2b_hqx(String ascii_data) { int leftbits = 0; char this_ch; int leftchar = 0; boolean done = false; int len = ascii_data.length(); StringBuilder bin_data = new StringBuilder(); for(int i = 0; len > 0 ; len--, i++) { // Get the byte and look it up this_ch = (char) table_a2b_hqx[ascii_data.charAt(i)]; if (this_ch == SKIP) continue; if (this_ch == FAIL) { throw new PyException(Error, "Illegal char"); } if (this_ch == DONE) { // The terminating colon done = true; break; } // Shift it into the buffer and see if any bytes are ready leftchar = (leftchar << 6) | (this_ch); leftbits += 6; if (leftbits >= 8) { leftbits -= 8; bin_data.append((char)((leftchar >> leftbits) & 0xff)); leftchar &= ((1 << leftbits) - 1); } } if (leftbits != 0 && !done) { throw new PyException(Incomplete, "String has incomplete number of bytes"); } return new PyTuple(Py.java2py(bin_data.toString()), Py.newInteger(done ? 1 : 0)); }
// in src/org/python/modules/binascii.java
static public String rledecode_hqx(String in_data) { char in_byte, in_repeat; int in_len = in_data.length(); int i = 0; // Empty string is a special case if (in_len == 0) return ""; StringBuilder out_data = new StringBuilder(); // Handle first byte separately (since we have to get angry // in case of an orphaned RLE code). if (--in_len < 0) throw new PyException(Incomplete); in_byte = in_data.charAt(i++); if (in_byte == RUNCHAR) { if (--in_len < 0) throw new PyException(Incomplete); in_repeat = in_data.charAt(i++); if (in_repeat != 0) { // Note Error, not Incomplete (which is at the end // of the string only). This is a programmer error. throw new PyException(Error, "Orphaned RLE code at start"); } out_data.append(RUNCHAR); } else { out_data.append(in_byte); } while (in_len > 0) { if (--in_len < 0) throw new PyException(Incomplete); in_byte = in_data.charAt(i++); if (in_byte == RUNCHAR) { if (--in_len < 0) throw new PyException(Incomplete); in_repeat = in_data.charAt(i++); if (in_repeat == 0) { // Just an escaped RUNCHAR value out_data.append(RUNCHAR); } else { // Pick up value and output a sequence of it in_byte = out_data.charAt(out_data.length()-1); while (--in_repeat > 0) out_data.append(in_byte); } } else { // Normal byte out_data.append(in_byte); } } return out_data.toString(); }
// in src/org/python/modules/posix/PosixModule.java
public static void rename(String oldpath, String newpath) { if (!new RelativeFile(oldpath).renameTo(new RelativeFile(newpath))) { PyObject args = new PyTuple(Py.Zero, new PyString("Couldn't rename file")); throw new PyException(Py.OSError, args); } }
// in src/org/python/modules/posix/PosixModule.java
public static void rmdir(String path) { File file = new RelativeFile(path); if (!file.exists()) { throw Py.OSError(Errno.ENOENT, path); } else if (!file.isDirectory()) { throw Py.OSError(Errno.ENOTDIR, path); } else if (!file.delete()) { PyObject args = new PyTuple(Py.Zero, new PyString("Couldn't delete directory"), new PyString(path)); throw new PyException(Py.OSError, args); } }
// in src/org/python/modules/thread/thread.java
public static void exit_thread() { throw new PyException(Py.SystemExit, new PyInteger(0)); }
// in src/org/python/modules/cPickle.java
private void save(PyObject object, boolean pers_save) { if (!pers_save && persistent_id != null && save_pers(object, persistent_id)) { return; } int d = get_id(object); PyType t = object.getType(); if (t == TupleType && object.__len__() == 0) { if (protocol > 0) save_empty_tuple(object); else save_tuple(object); return; } int m = getMemoPosition(d, object); if (m >= 0) { get(m); return; } if (save_type(object, t)) return; if (!pers_save && inst_persistent_id != null && save_pers(object, inst_persistent_id)) { return; } if (Py.isSubClass(t, PyType.TYPE)) { save_global(object); return; } PyObject tup = null; PyObject reduce = dispatch_table.__finditem__(t); if (reduce == null) { reduce = object.__findattr__("__reduce_ex__"); if (reduce != null) { tup = reduce.__call__(Py.newInteger(protocol)); } else { reduce = object.__findattr__("__reduce__"); if (reduce == null) throw new PyException(UnpickleableError, object); tup = reduce.__call__(); } } else { tup = reduce.__call__(object); } if (tup instanceof PyString) { save_global(object, tup); return; } if (!(tup instanceof PyTuple)) { throw new PyException(PicklingError, "Value returned by " + reduce.__repr__() + " must be a tuple"); } int l = tup.__len__(); if (l < 2 || l > 5) { throw new PyException(PicklingError, "tuple returned by " + reduce.__repr__() + " must contain two to five elements"); } PyObject callable = tup.__finditem__(0); PyObject arg_tup = tup.__finditem__(1); PyObject state = (l > 2) ? tup.__finditem__(2) : Py.None; PyObject listitems = (l > 3) ? tup.__finditem__(3) : Py.None; PyObject dictitems = (l > 4) ? tup.__finditem__(4) : Py.None; if (!(arg_tup instanceof PyTuple) && arg_tup != Py.None) { throw new PyException(PicklingError, "Second element of tupe returned by " + reduce.__repr__() + " must be a tuple"); } save_reduce(callable, arg_tup, state, listitems, dictitems, object); }
// in src/org/python/modules/cPickle.java
final private boolean save_pers(PyObject object, PyObject pers_func) { PyObject pid = pers_func.__call__(object); if (pid == Py.None) { return false; } if (protocol == 0) { if (!Py.isInstance(pid, PyString.TYPE)) { throw new PyException(PicklingError, "persistent id must be string"); } file.write(PERSID); file.write(pid.toString()); file.write("\n"); } else { save(pid, true); file.write(BINPERSID); } return true; }
// in src/org/python/modules/cPickle.java
final private void save_reduce(PyObject callable, PyObject arg_tup, PyObject state, PyObject listitems, PyObject dictitems, PyObject object) { PyObject callableName = callable.__findattr__("__name__"); if(protocol >= 2 && callableName != null && "__newobj__".equals(callableName.toString())) { PyObject cls = arg_tup.__finditem__(0); if(cls.__findattr__("__new__") == null) throw new PyException(PicklingError, "args[0] from __newobj__ args has no __new__"); // TODO: check class save(cls); save(arg_tup.__getslice__(Py.One, Py.None)); file.write(NEWOBJ); } else { save(callable); save(arg_tup); file.write(REDUCE); } // Memoize put(putMemo(get_id(object), object)); if (listitems != Py.None) { batch_appends(listitems); } if (dictitems != Py.None) { batch_setitems(dictitems); } if (state != Py.None) { save(state); file.write(BUILD); } }
// in src/org/python/modules/cPickle.java
public PyObject load() { stackTop = 0; stack = new PyObject[10]; while (true) { String s = file.read(1); // System.out.println("load:" + s); // for (int i = 0; i < stackTop; i++) // System.out.println(" " + stack[i]); if (s.length() < 1) load_eof(); char key = s.charAt(0); switch (key) { case PERSID: load_persid(); break; case BINPERSID: load_binpersid(); break; case NONE: load_none(); break; case INT: load_int(); break; case BININT: load_binint(); break; case BININT1: load_binint1(); break; case BININT2: load_binint2(); break; case LONG: load_long(); break; case FLOAT: load_float(); break; case BINFLOAT: load_binfloat(); break; case STRING: load_string(); break; case BINSTRING: load_binstring(); break; case SHORT_BINSTRING: load_short_binstring(); break; case UNICODE: load_unicode(); break; case BINUNICODE: load_binunicode(); break; case TUPLE: load_tuple(); break; case EMPTY_TUPLE: load_empty_tuple(); break; case EMPTY_LIST: load_empty_list(); break; case EMPTY_DICT: load_empty_dictionary(); break; case LIST: load_list(); break; case DICT: load_dict(); break; case INST: load_inst(); break; case OBJ: load_obj(); break; case GLOBAL: load_global(); break; case REDUCE: load_reduce(); break; case POP: load_pop(); break; case POP_MARK: load_pop_mark(); break; case DUP: load_dup(); break; case GET: load_get(); break; case BINGET: load_binget(); break; case LONG_BINGET: load_long_binget(); break; case PUT: load_put(); break; case BINPUT: load_binput(); break; case LONG_BINPUT: load_long_binput(); break; case APPEND: load_append(); break; case APPENDS: load_appends(); break; case SETITEM: load_setitem(); break; case SETITEMS: load_setitems(); break; case BUILD: load_build(); break; case MARK: load_mark(); break; case PROTO: load_proto(); break; case NEWOBJ: load_newobj(); break; case EXT1: load_ext(1); break; case EXT2: load_ext(2); break; case EXT4: load_ext(4); break; case TUPLE1: load_small_tuple(1); break; case TUPLE2: load_small_tuple(2); break; case TUPLE3: load_small_tuple(3); break; case NEWTRUE: load_boolean(true); break; case NEWFALSE: load_boolean(false); break; case LONG1: load_bin_long(1); break; case LONG4: load_bin_long(4); break; case STOP: return load_stop(); default: throw new PyException(UnpicklingError, String.format("invalid load key, '%s'.", key)); } } }
// in src/org/python/modules/cPickle.java
final private int marker() { for (int k = stackTop-1; k >= 0; k--) if (stack[k] == mark) return stackTop-k-1; throw new PyException(UnpicklingError, "Inputstream corrupt, marker not found"); }
// in src/org/python/modules/cPickle.java
final private void load_eof() { throw new PyException(Py.EOFError); }
// in src/org/python/modules/cPickle.java
final private void load_persid(PyObject pid) { if (persistent_load == null) { throw new PyException(UnpicklingError, "A load persistent id instruction was encountered,\n" + "but no persistent_load function was specified."); } if (persistent_load instanceof PyList) { ((PyList)persistent_load).append(pid); } else { pid = persistent_load.__call__(pid); } push(pid); }
// in src/org/python/modules/cPickle.java
final private PyObject find_class(String module, String name) { if (find_global != null) { if (find_global == Py.None) throw new PyException(UnpicklingError, "Global and instance pickles are not supported."); return find_global.__call__(new PyString(module), new PyString(name)); } PyObject modules = Py.getSystemState().modules; PyObject mod = modules.__finditem__(module.intern()); if (mod == null) { mod = importModule(module); } PyObject global = mod.__findattr__(name.intern()); if (global == null) { throw new PyException(Py.SystemError, "Failed to import class " + name + " from module " + module); } return global; }
// in src/org/python/modules/cPickle.java
private void load_ext(int length) { int code = read_binint(length); // TODO: support _extension_cache PyObject key = inverted_registry.get(Py.newInteger(code)); if (key == null) { throw new PyException(Py.ValueError, "unregistered extension code " + code); } String module = key.__finditem__(0).toString(); String name = key.__finditem__(1).toString(); push(find_class(module, name)); }
// in src/org/python/modules/cPickle.java
final private void load_get() { String py_str = file.readlineNoNl(); PyObject value = memo.get(py_str); if (value == null) { throw new PyException(BadPickleGet, py_str); } push(value); }
// in src/org/python/modules/cPickle.java
final private void load_binget() { String py_key = String.valueOf((int)file.read(1).charAt(0)); PyObject value = memo.get(py_key); if (value == null) { throw new PyException(BadPickleGet, py_key); } push(value); }
// in src/org/python/modules/cPickle.java
final private void load_long_binget() { int i = read_binint(); String py_key = String.valueOf(i); PyObject value = memo.get(py_key); if (value == null) { throw new PyException(BadPickleGet, py_key); } push(value); }
// in src/org/python/modules/cPickle.java
private void load_build() { PyObject state = pop(); PyObject inst = peek(); PyObject setstate = inst.__findattr__("__setstate__"); if (setstate != null) { // The explicit __setstate__ is responsible for everything. setstate.__call__(state); return; } // A default __setstate__. First see whether state embeds a slot state dict // too (a proto 2 addition). PyObject slotstate = null; if (state instanceof PyTuple && state.__len__() == 2) { PyObject temp = state; state = temp.__getitem__(0); slotstate = temp.__getitem__(1); } if (state != Py.None) { if (!(state instanceof PyDictionary)) { throw new PyException(UnpicklingError, "state is not a dictionary"); } PyObject dict = inst.__getattr__("__dict__"); for (PyObject item : ((PyDictionary)state).iteritems().asIterable()) { dict.__setitem__(item.__getitem__(0), item.__getitem__(1)); } } // Also set instance attributes from the slotstate dict (if any). if (slotstate != null) { if (!(slotstate instanceof PyDictionary)) { throw new PyException(UnpicklingError, "slot state is not a dictionary"); } for (PyObject item : ((PyDictionary)slotstate).iteritems().asIterable()) { inst.__setattr__(PyObject.asName(item.__getitem__(0)), item.__getitem__(1)); } } }
// in src/org/python/modules/time/Time.java
private static void throwValueError(String msg) { throw new PyException(Py.ValueError, new PyString(msg)); }
// in src/org/python/modules/time/Time.java
private synchronized static String _shortday(int dow) { // we need to hand craft shortdays[] because Java and Python have // different specifications. Java (undocumented) appears to be // first element "", followed by 0=Sun. Python says 0=Mon if (shortdays == null) { shortdays = new String[7]; String[] names = datesyms.getShortWeekdays(); for (int i = 0; i < 6; i++) { shortdays[i] = names[i + 2]; } shortdays[6] = names[1]; } try { return shortdays[dow]; } catch (ArrayIndexOutOfBoundsException e) { throw new PyException(Py.ValueError, new PyString("day of week out of range (0-6)")); } }
// in src/org/python/modules/time/Time.java
private synchronized static String _shortmonth(int month0to11) { // getShortWeekdays() returns a 13 element array with the last item // being the empty string. This is also undocumented ;-/ if (shortmonths == null) { shortmonths = new String[12]; String[] names = datesyms.getShortMonths(); for (int i = 0; i < 12; i++) { shortmonths[i] = names[i]; } } try { return shortmonths[month0to11]; } catch (ArrayIndexOutOfBoundsException e) { throw new PyException(Py.ValueError, new PyString("month out of range (1-12)")); } }
// in src/org/python/modules/time/Time.java
public static void sleep(double secs) { try { java.lang.Thread.sleep((long)(secs * 1000)); } catch (java.lang.InterruptedException e) { throw new PyException(Py.KeyboardInterrupt, "interrupted sleep"); } }
// in src/org/python/core/PySystemState.java
public static void exit(PyObject status) { throw new PyException(Py.SystemExit, status); }
// in src/org/python/core/PyTableCode.java
Override public PyObject call(ThreadState ts, PyFrame frame, PyObject closure) { // System.err.println("tablecode call: "+co_name); if (ts.systemState == null) { ts.systemState = Py.defaultSystemState; } //System.err.println("got ts: "+ts+", "+ts.systemState); // Cache previously defined exception PyException previous_exception = ts.exception; // Push frame frame.f_back = ts.frame; if (frame.f_builtins == null) { if (frame.f_back != null) { frame.f_builtins = frame.f_back.f_builtins; } else { //System.err.println("ts: "+ts); //System.err.println("ss: "+ts.systemState); frame.f_builtins = PySystemState.builtins; } } // nested scopes: setup env with closure // this should only be done once, so let the frame take care of it frame.setupEnv((PyTuple)closure); ts.frame = frame; // Handle trace function for debugging if (ts.tracefunc != null) { frame.f_lineno = co_firstlineno; frame.tracefunc = ts.tracefunc.traceCall(frame); } // Handle trace function for profiling if (ts.profilefunc != null) { ts.profilefunc.traceCall(frame); } PyObject ret; try { ret = funcs.call_function(func_id, frame, ts); } catch (Throwable t) { // Convert exceptions that occured in Java code to PyExceptions PyException pye = Py.JavaError(t); pye.tracebackHere(frame); frame.f_lasti = -1; if (frame.tracefunc != null) { frame.tracefunc.traceException(frame, pye); } if (ts.profilefunc != null) { ts.profilefunc.traceException(frame, pye); } // Rethrow the exception to the next stack frame ts.exception = previous_exception; ts.frame = ts.frame.f_back; throw pye; } if (frame.tracefunc != null) { frame.tracefunc.traceReturn(frame, ret); } // Handle trace function for profiling if (ts.profilefunc != null) { ts.profilefunc.traceReturn(frame, ret); } // Restore previously defined exception ts.exception = previous_exception; ts.frame = ts.frame.f_back; // Check for interruption, which is used for restarting the interpreter // on Jython if (ts.systemState._systemRestart && Thread.currentThread().isInterrupted()) { throw new PyException(_systemrestart.SystemRestart); } return ret; }
// in src/org/python/core/PyBaseCode.java
public PyObject call(ThreadState ts, PyFrame frame, PyObject closure) { // System.err.println("tablecode call: "+co_name); if (ts.systemState == null) { ts.systemState = Py.defaultSystemState; } //System.err.println("got ts: "+ts+", "+ts.systemState); // Cache previously defined exception PyException previous_exception = ts.exception; // Push frame frame.f_back = ts.frame; if (frame.f_builtins == null) { if (frame.f_back != null) { frame.f_builtins = frame.f_back.f_builtins; } else { //System.err.println("ts: "+ts); //System.err.println("ss: "+ts.systemState); frame.f_builtins = PySystemState.builtins; } } // nested scopes: setup env with closure // this should only be done once, so let the frame take care of it frame.setupEnv((PyTuple)closure); ts.frame = frame; // Handle trace function for debugging if (ts.tracefunc != null) { frame.f_lineno = co_firstlineno; frame.tracefunc = ts.tracefunc.traceCall(frame); } // Handle trace function for profiling if (ts.profilefunc != null) { ts.profilefunc.traceCall(frame); } PyObject ret; try { ret = interpret(frame, ts); } catch (Throwable t) { // Convert exceptions that occured in Java code to PyExceptions PyException pye = Py.JavaError(t); pye.tracebackHere(frame); frame.f_lasti = -1; if (frame.tracefunc != null) { frame.tracefunc.traceException(frame, pye); } if (ts.profilefunc != null) { ts.profilefunc.traceException(frame, pye); } // Rethrow the exception to the next stack frame ts.exception = previous_exception; ts.frame = ts.frame.f_back; throw pye; } if (frame.tracefunc != null) { frame.tracefunc.traceReturn(frame, ret); } // Handle trace function for profiling if (ts.profilefunc != null) { ts.profilefunc.traceReturn(frame, ret); } // Restore previously defined exception ts.exception = previous_exception; ts.frame = ts.frame.f_back; // Check for interruption, which is used for restarting the interpreter // on Jython if (ts.systemState._systemRestart && Thread.currentThread().isInterrupted()) { throw new PyException(_systemrestart.SystemRestart); } return ret; }
// in src/org/python/core/PyArray.java
public void append(PyObject value) { // Currently, this is asymmetric with extend, which // *will* do conversions like append(5.0) to an int array. // Also, cpython 2.2 will do the append coersion. However, // it is deprecated in cpython 2.3, so maybe we are just // ahead of our time ;-) int afterLast = delegate.getSize(); if ("u".equals(typecode)) { int codepoint = getCodePoint(value); delegate.makeInsertSpace(afterLast); Array.setInt(data, afterLast, codepoint); } else { delegate.makeInsertSpace(afterLast); try { set(afterLast, value); } catch (PyException e) { delegate.setSize(afterLast); throw new PyException(e.type, e.value); } } }
// in src/org/python/core/PyArray.java
public void fromlist(PyObject obj) { if(!(obj instanceof PyList)) { throw Py.TypeError("arg must be list"); } // store the current size of the internal array int size = delegate.getSize(); try { extendInternalIter(obj); } catch(PyException e) { // trap any exception - any error invalidates the whole list delegate.setSize(size); // re-throw throw new PyException(e.type, e.value); } }
// in src/org/python/core/Py.java
public static void assert_(PyObject test, PyObject message) { if (!test.__nonzero__()) { throw new PyException(Py.AssertionError, message); } }
// in src/org/python/core/codecs.java
public static PyObject lookup_error(String handlerName) { registry_init(); if (handlerName == null) { handlerName = "strict"; } PyObject handler = errorHandlers.__finditem__(handlerName.intern()); if (handler == null) { throw new PyException(Py.LookupError, "unknown error handler name '" + handlerName + "'"); } return handler; }
// in src/org/python/core/codecs.java
public static PyTuple lookup(String encoding) { registry_init(); PyString v = new PyString(normalizestring(encoding)); PyObject cached = searchCache.__finditem__(v); if (cached != null) { return (PyTuple)cached; } if (searchPath.__len__() == 0) { throw new PyException(Py.LookupError, "no codec search functions registered: can't find encoding '" + encoding + "'"); } for (PyObject func : searchPath.asIterable()) { PyObject created = func.__call__(v); if (created == Py.None) { continue; } if (!(created instanceof PyTuple) || created.__len__() != 4) { throw Py.TypeError("codec search functions must return 4-tuples"); } searchCache.__setitem__(v, created); return (PyTuple)created; } throw new PyException(Py.LookupError, "unknown encoding '" + encoding + "'"); }
// in src/org/python/core/codecs.java
public static PyObject strict_errors(PyObject[] args, String[] kws) { ArgParser ap = new ArgParser("strict_errors", args, kws, "exc"); PyObject exc = ap.getPyObject(0); if (Py.isInstance(exc, Py.UnicodeDecodeError)) { throw new PyException(Py.UnicodeDecodeError, exc); } else if (Py.isInstance(exc, Py.UnicodeEncodeError)) { throw new PyException(Py.UnicodeEncodeError, exc); } else if (Py.isInstance(exc, Py.UnicodeTranslateError)) { throw new PyException(Py.UnicodeTranslateError, exc); } throw wrong_exception_type(exc); }
// in src/org/python/core/codecs.java
private static void checkErrorHandlerReturn(String errors, PyObject replacement) { if (!(replacement instanceof PyTuple) || replacement.__len__() != 2 || !(replacement.__getitem__(0) instanceof PyBaseString) || !(replacement.__getitem__(1) instanceof PyInteger)) { throw new PyException(Py.TypeError, "error_handler " + errors + " must return a tuple of (replacement, new position)"); } }
// in src/org/python/core/PyLong.java
Override public int asIndex(PyObject err) { boolean tooLow = getValue().compareTo(PyInteger.MIN_INT) < 0; boolean tooHigh = getValue().compareTo(PyInteger.MAX_INT) > 0; if (tooLow || tooHigh) { if (err != null) { throw new PyException(err, "cannot fit 'long' into an index-sized integer"); } return tooLow ? Integer.MIN_VALUE : Integer.MAX_VALUE; } return (int) getValue().longValue(); }
// in src/org/python/core/PyString.java
public String translate(PyObject table) { StringBuilder v = new StringBuilder(getString().length()); for (int i=0; i < getString().length(); i++) { char ch = getString().charAt(i); PyObject w = Py.newInteger(ch); PyObject x = table.__finditem__(w); if (x == null) { /* No mapping found: default to 1-1 mapping */ v.append(ch); continue; } /* Apply mapping */ if (x instanceof PyInteger) { int value = ((PyInteger) x).getValue(); v.append((char) value); } else if (x == Py.None) { ; } else if (x instanceof PyString) { if (x.__len__() != 1) { /* 1-n mapping */ throw new PyException(Py.NotImplementedError, "1-n mappings are currently not implemented"); } v.append(x.toString()); } else { /* wrong return value */ throw Py.TypeError( "character mapping must return integer, " + "None or unicode"); } } return v.toString(); }
// in src/org/python/util/ReadlineConsole.java
public String raw_input(PyObject prompt) { try { String line = Readline.readline(prompt == null ? "" : prompt.toString()); return (line == null ? "" : line); } catch(EOFException eofe) { throw new PyException(Py.EOFError); } catch(IOException ioe) { throw new PyException(Py.IOError); } }
8
            
// in src/org/python/modules/time/Time.java
catch (ArrayIndexOutOfBoundsException e) { throw new PyException(Py.ValueError, new PyString("day of week out of range (0-6)")); }
// in src/org/python/modules/time/Time.java
catch (ArrayIndexOutOfBoundsException e) { throw new PyException(Py.ValueError, new PyString("month out of range (1-12)")); }
// in src/org/python/modules/time/Time.java
catch (java.lang.InterruptedException e) { throw new PyException(Py.KeyboardInterrupt, "interrupted sleep"); }
// in src/org/python/core/PySet.java
catch (NoSuchElementException e) { throw new PyException(Py.KeyError, "pop from an empty set"); }
// in src/org/python/core/PyArray.java
catch (PyException e) { delegate.setSize(afterLast); throw new PyException(e.type, e.value); }
// in src/org/python/core/PyArray.java
catch(PyException e) { // trap any exception - any error invalidates the whole list delegate.setSize(size); // re-throw throw new PyException(e.type, e.value); }
// in src/org/python/util/ReadlineConsole.java
catch(EOFException eofe) { throw new PyException(Py.EOFError); }
// in src/org/python/util/ReadlineConsole.java
catch(IOException ioe) { throw new PyException(Py.IOError); }
4
            
// in src/com/ziclix/python/sql/zxJDBC.java
protected static void _addSqlTypes(PyObject dict) throws PyException { PyDictionary sqltype = new PyDictionary(); dict.__setitem__("sqltype", sqltype); try { Class<?> c = Class.forName("java.sql.Types"); Field[] fields = c.getFields(); for (Field f : fields) { PyString name = Py.newString(f.getName()); PyObject value = new DBApiType(f.getInt(c)); dict.__setitem__(name, value); sqltype.__setitem__(value, name); } c = Class.forName("java.sql.ResultSet"); fields = c.getFields(); for (Field f : fields) { PyString name = Py.newString(f.getName()); PyObject value = Py.newInteger(f.getInt(c)); dict.__setitem__(name, value); } } catch (Throwable t) { throw makeException(t); } dict.__setitem__("ROWID", dict.__getitem__(Py.newString("OTHER"))); dict.__setitem__("NUMBER", dict.__getitem__(Py.newString("NUMERIC"))); dict.__setitem__("STRING", dict.__getitem__(Py.newString("VARCHAR"))); dict.__setitem__("DATETIME", dict.__getitem__(Py.newString("TIMESTAMP"))); }
// in src/com/ziclix/python/sql/zxJDBC.java
protected static void _addConnectors(PyObject dict) throws PyException { PyObject connector = Py.None; Properties props = new Properties(); props.put("connect", "com.ziclix.python.sql.connect.Connect"); props.put("lookup", "com.ziclix.python.sql.connect.Lookup"); props.put("connectx", "com.ziclix.python.sql.connect.Connectx"); Enumeration<?> names = props.propertyNames(); while (names.hasMoreElements()) { String name = ((String) names.nextElement()).trim(); String className = props.getProperty(name).trim(); try { connector = (PyObject) Class.forName(className).newInstance(); dict.__setitem__(name, connector); Py.writeComment("zxJDBC", "loaded connector [" + className + "] as [" + name + "]"); } catch (Throwable t) { Py.writeComment("zxJDBC", "failed to load connector [" + name + "] using class [" + className + "]"); } } }
// in src/com/xhaus/modjy/ModjyJServlet.java
protected void setupEnvironment(PythonInterpreter interp, Properties props, PySystemState systemState) throws PyException { processPythonLib(interp, systemState); checkSitePackages(props); }
// in src/com/xhaus/modjy/ModjyJServlet.java
protected void checkSitePackages(Properties props) throws PyException { String loadSitePackagesParam = props.getProperty(LOAD_SITE_PACKAGES_PARAM); boolean loadSitePackages = true; if (loadSitePackagesParam != null && loadSitePackagesParam.trim().compareTo("0") == 0) loadSitePackages = false; if (loadSitePackages) imp.load("site"); }
483
            
// in src/com/ziclix/python/sql/Fetch.java
catch (PyException e) { throw e; }
// in src/com/ziclix/python/sql/Fetch.java
catch (PyException e) { throw e; }
// in src/com/ziclix/python/sql/Fetch.java
catch (PyException e) { throw e; }
// in src/com/ziclix/python/sql/Fetch.java
catch (PyException e) { throw e; }
// in src/com/ziclix/python/sql/PyStatement.java
catch (PyException e) { throw zxJDBC.makeException(zxJDBC.ProgrammingError, zxJDBC.getString("bindingValue")); }
// in src/com/ziclix/python/sql/PyCursor.java
catch (PyException e) { throw e; }
// in src/com/ziclix/python/sql/PyCursor.java
catch (PyException e) { throw e; }
// in src/com/xhaus/modjy/ModjyJServlet.java
catch (PyException ix) { throw new ServletException("Unable to import '" + MODJY_PYTHON_CLASSNAME + "': maybe you need to set the '" + PYTHON_HOME_PARAM + "' parameter?", ix); }
// in src/com/xhaus/modjy/ModjyJServlet.java
catch (PyException pyx) { throw new ServletException("Exception creating modjy servlet: " + pyx.toString(), pyx); }
// in src/org/python/compiler/Module.java
catch (PyException e) { if (!e.match(Py.SyntaxWarning)) { throw e; } }
// in src/org/python/antlr/ast/aliasDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/aliasDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/aliasDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/AttributeDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/AttributeDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/AttributeDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/UnaryOpDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/UnaryOpDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/UnaryOpDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/BreakDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/BreakDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/BreakDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/BoolOpDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/BoolOpDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/BoolOpDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ListCompDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/ListCompDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ListCompDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ContinueDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/ContinueDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ContinueDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/TupleDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/TupleDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/TupleDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/InteractiveDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/InteractiveDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/InteractiveDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/DeleteDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/DeleteDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/DeleteDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/IndexDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/IndexDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/IndexDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ModuleDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/ModuleDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ModuleDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/CallDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/CallDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/CallDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ReturnDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/ReturnDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ReturnDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ForDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/ForDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ForDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ExceptHandlerDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/ExceptHandlerDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ExceptHandlerDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/SubscriptDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/SubscriptDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/SubscriptDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/DictDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/DictDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/DictDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/LambdaDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/LambdaDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/LambdaDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/GlobalDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/GlobalDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/GlobalDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ListDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/ListDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ListDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/BinOpDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/BinOpDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/BinOpDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ClassDefDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/ClassDefDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ClassDefDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ExpressionDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/ExpressionDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ExpressionDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/SliceDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/SliceDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/SliceDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/NumDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/NumDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/NumDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ExprDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/ExprDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ExprDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/NameDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/NameDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/NameDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/TryFinallyDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/TryFinallyDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/TryFinallyDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/IfExpDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/IfExpDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/IfExpDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/AugAssignDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/AugAssignDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/AugAssignDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ImportDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/ImportDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ImportDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/IfDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/IfDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/IfDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/PassDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/PassDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/PassDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/FunctionDefDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/FunctionDefDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/FunctionDefDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/argumentsDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/argumentsDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/argumentsDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/WithDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/WithDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/WithDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ImportFromDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/ImportFromDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ImportFromDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/CompareDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/CompareDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/CompareDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ReprDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/ReprDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ReprDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/StrDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/StrDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/StrDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/YieldDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/YieldDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/YieldDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/EllipsisDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/EllipsisDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/EllipsisDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/RaiseDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/RaiseDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/RaiseDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/AssignDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/AssignDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/AssignDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/GeneratorExpDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/GeneratorExpDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/GeneratorExpDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/SuiteDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/SuiteDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/SuiteDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/AssertDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/AssertDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/AssertDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/TryExceptDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/TryExceptDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/TryExceptDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ExecDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/ExecDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ExecDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/WhileDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/WhileDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/WhileDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/keywordDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/keywordDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/keywordDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/comprehensionDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/comprehensionDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/comprehensionDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ExtSliceDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/ExtSliceDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ExtSliceDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/PrintDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/PrintDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/PrintDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/PowDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/PowDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/PowDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/LtEDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/LtEDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/LtEDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/ParamDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/ParamDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/ParamDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/EqDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/EqDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/EqDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/GtDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/GtDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/GtDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/IsDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/IsDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/IsDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/GtEDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/GtEDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/GtEDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/StoreDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/StoreDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/StoreDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/BitOrDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/BitOrDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/BitOrDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/RShiftDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/RShiftDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/RShiftDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/BitAndDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/BitAndDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/BitAndDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/NotInDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/NotInDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/NotInDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/LtDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/LtDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/LtDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/FloorDivDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/FloorDivDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/FloorDivDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/USubDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/USubDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/USubDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/InvertDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/InvertDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/InvertDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/AugLoadDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/AugLoadDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/AugLoadDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/AugStoreDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/AugStoreDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/AugStoreDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/LoadDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/LoadDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/LoadDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/IsNotDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/IsNotDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/IsNotDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/BitXorDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/BitXorDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/BitXorDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/NotEqDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/NotEqDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/NotEqDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/NotDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/NotDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/NotDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/AndDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/AndDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/AndDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/ModDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/ModDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/ModDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/AddDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/AddDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/AddDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/DelDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/DelDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/DelDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/DivDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/DivDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/DivDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/LShiftDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/LShiftDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/LShiftDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/InDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/InDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/InDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/MultDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/MultDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/MultDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/UAddDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/UAddDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/UAddDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/OrDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/OrDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/OrDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/SubDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/SubDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/SubDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/jsr223/PyScriptEngine.java
catch (PyException pye) { throw scriptException(pye); }
// in src/org/python/jsr223/PyScriptEngine.java
catch (PyException pye) { throw scriptException(pye); }
// in src/org/python/jsr223/PyScriptEngine.java
catch (PyException pye) { throw scriptException(pye); }
// in src/org/python/jsr223/PyScriptEngine.java
catch (PyException pye) { throw scriptException(pye); }
// in src/org/python/jsr223/PyScriptEngine.java
catch (PyException pye) { throw scriptException(pye); }
// in src/org/python/jsr223/PyScriptEngine.java
catch (PyException pye) { throw scriptException(pye); }
// in src/org/python/modules/zipimport/zipimporterDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/modules/zipimport/zipimporterDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/modules/zipimport/zipimporterDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/modules/zipimport/zipimporter.java
catch (PyException pye) { if (!pye.match(Py.TypeError)) { throw pye; } time = -1; date = -1; }
// in src/org/python/modules/struct.java
catch (PyException ex) { throw StructError("required argument is not an integer"); }
// in src/org/python/modules/binascii.java
catch (PyException e) { if (e.match(Py.AttributeError) || e.match(Py.ValueError)) throw Py.TypeError(errMsg); throw e; }
// in src/org/python/modules/_weakref/ReferenceTypeDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/modules/_weakref/ReferenceTypeDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/modules/_weakref/ReferenceTypeDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/modules/posix/PosixModule.java
catch (PyException pye) { if (!pye.match(Py.OSError)) { throw pye; } // ENOENT result = false; }
// in src/org/python/modules/posix/PosixModule.java
catch (PyException pye) { throw badFD(); }
// in src/org/python/modules/posix/PosixModule.java
catch (PyException pye) { if (!pye.match(Py.IOError)) { throw pye; } throw Py.OSError(Errno.EINVAL); }
// in src/org/python/modules/posix/PosixModule.java
catch (PyException pye) { throw Py.IOError(Errno.EBADF); }
// in src/org/python/modules/posix/PosixModule.java
catch (PyException pye) { throw badFD(); }
// in src/org/python/modules/posix/PosixModule.java
catch (PyException pye) { throw badFD(); }
// in src/org/python/modules/posix/PosixModule.java
catch (PyException pye) { throw badFD(); }
// in src/org/python/modules/posix/PosixModule.java
catch (PyException pye) { if (!pye.match(Py.KeyError)) { throw pye; } }
// in src/org/python/modules/thread/PyLocalDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/modules/thread/PyLocalDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/modules/thread/PyLocalDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/modules/_csv/PyWriter.java
catch (PyException ex) { quoted = true; }
// in src/org/python/modules/_csv/PyDialectDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/modules/_csv/PyDialectDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/modules/_csv/PyDialectDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/modules/random/PyRandomDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/modules/random/PyRandomDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/modules/random/PyRandomDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/modules/_collections/PyDequeDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/modules/_collections/PyDequeDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/modules/_collections/PyDequeDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/modules/_collections/PyDefaultDictDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/modules/_collections/PyDefaultDictDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/modules/_collections/PyDefaultDictDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/modules/_collections/PyDeque.java
catch (PyException pe) { if (pe.match(Py.KeyError)) { return null; } throw pe; }
// in src/org/python/modules/itertools.java
catch (PyException pyEx) { if (pyEx.match(Py.StopIteration)) { // store exception - will be used by PyIterator.next() stopException = pyEx; } else { throw pyEx; } }
// in src/org/python/modules/itertools.java
catch (PyException pyEx) { if (pyEx.match(Py.TypeError)) { throw Py.ValueError(msg); } else { throw pyEx; } }
// in src/org/python/modules/_functools/PyPartialDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/modules/_functools/PyPartialDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/modules/_functools/PyPartialDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/modules/time/Time.java
catch (PyException e) { // CPython's mktime raises OverflowErrors... yuck! e.type = Py.OverflowError; throw e; }
// in src/org/python/modules/PyTeeIterator.java
catch (PyException pyEx) { if (pyEx.match(Py.StopIteration)) { // store exception - will be used by PyIterator.next() stopException = pyEx; } else { throw pyEx; } }
// in src/org/python/core/PyFinalizableInstance.java
catch (PyException exc) { // Try to get the right method description. PyObject method = instclass.__del__; try { method = __findattr__("__del__"); } catch (PyException e) { // nothing we can do } Py.writeUnraisable(exc, method); }
// in src/org/python/core/PyFinalizableInstance.java
catch (PyException e) { // nothing we can do }
// in src/org/python/core/PyObject.java
catch (PyException pye) { if (!pye.match(Py.AttributeError)) { throw pye; } }
// in src/org/python/core/PyObject.java
catch (PyException exc) { if (exc.match(Py.AttributeError)) { return null; } throw exc; }
// in src/org/python/core/PyObject.java
catch (PyException e) { if (e.value.getJavaProxy() != null) { Object t = e.value.__tojava__(Throwable.class); if (t != null && t != Py.NoConversion) { throw (Throwable) t; } } else { ThreadState ts = Py.getThreadState(); if (ts.frame == null) { Py.maybeSystemExit(e); } if (Options.showPythonProxyExceptions) { Py.stderr.println( "Exception in Python proxy returning to Java:"); Py.printException(e); } } throw e; }
// in src/org/python/core/PyObject.java
catch (PyException exc) { if (exc.match(Py.KeyError)) { noAttributeError(name); } else { throw exc; } }
// in src/org/python/core/PyObject.java
catch (PyException pye) { if (pye.match(Py.AttributeError)) { throw Py.TypeError("an integer is required"); } throw pye; }
// in src/org/python/core/PyObject.java
catch (PyException pye) { if (pye.match(Py.AttributeError)) { throw Py.TypeError("an integer is required"); } throw pye; }
// in src/org/python/core/PyObject.java
catch (PyException pye) { if (pye.match(Py.AttributeError)) { throw Py.TypeError("a float is required"); } throw pye; }
// in src/org/python/core/PyStringMap.java
catch(PyException pye) { if (pye.match(Py.TypeError)) { throw Py.TypeError(String.format("cannot convert dictionary update sequence " + "element #%d to a sequence", i)); } throw pye; }
// in src/org/python/core/PyList.java
catch (PyException pye) { if (!pye.match(Py.TypeError)) { throw pye; } return null; }
// in src/org/python/core/PyFloatDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyFloatDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyFloatDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyClass.java
catch (PyException pye) { noAttributeError(name); }
// in src/org/python/core/PyArrayDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyArrayDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyArrayDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/FunctionThread.java
catch (PyException exc) { if (exc.match(Py.SystemExit) || exc.match(_systemrestart.SystemRestart)) { return; } Py.stderr.println("Unhandled exception in thread started by " + func); Py.printException(exc); }
// in src/org/python/core/PyEnumerateDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyEnumerateDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyEnumerateDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PySystemState.java
catch (PyException pye) { // KeyError if (ret == null) { throw Py.AttributeError(name); } }
// in src/org/python/core/PySystemState.java
catch (PyException exc) { if (!exc.match(Py.SystemExit)) { Py.println(stderr, Py.newString("Error in sys.exitfunc:")); } Py.printException(exc); }
// in src/org/python/core/PySet.java
catch (PyException e) { PyObject frozen = asFrozen(e, o); b = _set.remove(frozen); }
// in src/org/python/core/PySet.java
catch (PyException e) { PyObject frozen = asFrozen(e, o); _set.remove(frozen); }
// in src/org/python/core/PyDictionary.java
catch(PyException pye) { if (pye.match(Py.TypeError)) { throw Py.TypeError(String.format("cannot convert dictionary update sequence " + "element #%d to a sequence", i)); } throw pye; }
// in src/org/python/core/PyUnicodeDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyUnicodeDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyUnicodeDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyFastSequenceIter.java
catch (PyException pye) { if (pye.match(Py.StopIteration)) { seq = null; return null; } throw pye; }
// in src/org/python/core/PyComplex.java
catch (PyException pye) { if (!pye.match(Py.AttributeError)) { // __complex__ not supported throw pye; } // otherwise try other means }
// in src/org/python/core/PyComplex.java
catch (PyException pye) { if (pye.match(Py.AttributeError)) { // __float__ not supported throw Py.TypeError("complex() argument must be a string or a number"); } throw pye; }
// in src/org/python/core/PyComplex.java
catch (PyException pye) { if (pye.match(Py.AttributeError)) { // __float__ not supported throw Py.TypeError("complex() argument must be a string or a number"); } throw pye; }
// in src/org/python/core/PyInstance.java
catch (PyException exc) { if (exc.match(Py.KeyError)) throw Py.AttributeError("class " + instclass.__name__ + " has no attribute '" + name + "'"); }
// in src/org/python/core/PyInstance.java
catch (PyException exc) { }
// in src/org/python/core/PyInstance.java
catch (PyException exc) { }
// in src/org/python/core/PyInstance.java
catch (PyException e) { if (e.match(Py.IndexError)) return null; if (e.match(Py.KeyError)) return null; throw e; }
// in src/org/python/core/PyInstance.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyInstance.java
catch (PyException pye) { if (!pye.match(Py.AttributeError)) { throw pye; } throw Py.TypeError("object cannot be interpreted as an index"); }
// in src/org/python/core/ContextGuard.java
catch(PyException e) { if (e.equals(exception)) { return false; } else { throw e; } }
// in src/org/python/core/PyFrame.java
catch (PyException pye) { if (pye.match(Py.KeyError)) { throw Py.NameError(String.format(NAME_ERROR_MSG, index)); } throw pye; }
// in src/org/python/core/PyFrame.java
catch (PyException pye) { if (pye.match(Py.KeyError)) { throw Py.NameError(String.format(GLOBAL_NAME_ERROR_MSG, index)); } throw pye; }
// in src/org/python/core/PyLongDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyLongDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyLongDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/AstList.java
catch (PyException pye) { if (!pye.match(Py.TypeError)) { throw pye; } return null; }
// in src/org/python/core/AstList.java
catch (PyException pye) { if (pye.match(Py.TypeError)) { throw Py.TypeError("can only assign an iterable"); } throw pye; }
// in src/org/python/core/PyFloat.java
catch (PyException e) { if (e.match(Py.AttributeError)) { // Translate AttributeError to TypeError // XXX: We are using the same message as CPython, even if // it is not strictly correct (instances of types // that implement the __float__ method are also // valid arguments) throw Py.TypeError("float() argument must be a string or a number"); } throw e; }
// in src/org/python/core/PySlice.java
catch (PyException pye) { if (!pye.match(Py.TypeError)) { throw pye; } }
// in src/org/python/core/PyIntegerDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyIntegerDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyIntegerDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyBaseExceptionDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyBaseExceptionDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyBaseExceptionDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/io/IOBase.java
catch (PyException pye) { if (!pye.match(Py.IOError)) { throw pye; } // If flush() fails, just give up }
// in src/org/python/core/io/BufferedIOMixin.java
catch (PyException pye) { if (!pye.match(Py.IOError)) { throw pye; } // If flush() fails, just give up }
// in src/org/python/core/PySuperDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PySuperDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PySuperDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/StdoutWrapper.java
catch (PyException pye) { // ok }
// in src/org/python/core/StdoutWrapper.java
catch (PyException pye) { // ok }
// in src/org/python/core/PyTraceback.java
catch (PyException pye) { return null; }
// in src/org/python/core/PyTraceback.java
catch (PyException pye) { // Proceed to closing the file }
// in src/org/python/core/PyTraceback.java
catch (PyException pye) { // Continue, we may have the line }
// in src/org/python/core/PyArray.java
catch (PyException e) { delegate.setSize(afterLast); throw new PyException(e.type, e.value); }
// in src/org/python/core/PyArray.java
catch(PyException e) { // trap any exception - any error invalidates the whole list delegate.setSize(size); // re-throw throw new PyException(e.type, e.value); }
// in src/org/python/core/PyModuleDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyModuleDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyModuleDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/__builtin__.java
catch (PyException pye) { if (!pye.match(Py.AttributeError)) { throw pye; } attributeError = pye; }
// in src/org/python/core/__builtin__.java
catch (PyException pye) { // swallow }
// in src/org/python/core/__builtin__.java
catch (PyException pye) { return handleRangeLongs(start, stop, step); }
// in src/org/python/core/__builtin__.java
catch (PyException pye) { return -1; }
// in src/org/python/core/__builtin__.java
catch (PyException e) { if (e.match(Py.AttributeError)) { throw Py.TypeError("vars() argument must have __dict__ attribute"); } throw e; }
// in src/org/python/core/__builtin__.java
catch (PyException e) { if (e.match(Py.StopIteration)) { return ret; } throw e; }
// in src/org/python/core/PyTypeDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyTypeDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyTypeDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PySetDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PySetDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PySetDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyType.java
catch (PyException t) { for (Iterator<Object> it = savedSubMros.iterator(); it.hasNext();) { PyType subtype = (PyType)it.next(); PyObject[] subtypeSavedMro = (PyObject[])it.next(); subtype.mro = subtypeSavedMro; } bases = savedBases; base = savedBase; mro = savedMro; throw t; }
// in src/org/python/core/PythonTraceFunction.java
catch(PyException exc) { frame.tracefunc = null; ts.tracefunc = null; ts.profilefunc = null; throw exc; }
// in src/org/python/core/PyPropertyDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyPropertyDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyPropertyDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/Py.java
catch (PyException e) { if (e.match(ImportError)) { return null; } throw e; }
// in src/org/python/core/Py.java
catch (PyException e) { Py.getSystemState().callExitFunc(); if (e.match(Py.SystemExit)) { return; } throw e; }
// in src/org/python/core/Py.java
catch (PyException exc2) { exc2.normalize(); flushLine(); stderr.println("Error in sys.excepthook:"); displayException(exc2.type, exc2.value, exc2.traceback, file); stderr.println(); stderr.println("Original exception was:"); displayException(exc.type, exc.value, exc.traceback, file); }
// in src/org/python/core/Py.java
catch (PyException pye) { if (!pye.match(TypeError)) { throw pye; } pye.value = Py.newString(String.format("Error when calling the metaclass bases\n " + "%s", pye.value.__str__().toString())); throw pye; }
// in src/org/python/core/Py.java
catch (PyException exc) { if (exc.match(Py.TypeError)) { throw Py.TypeError(message); } throw exc; }
// in src/org/python/core/Py.java
catch (PyException pye) { // ok }
// in src/org/python/core/PySequenceIter.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) { seq = null; return null; } throw exc; }
// in src/org/python/core/PyFileDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyFileDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyFileDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyCallIter.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) { callable = null; stopException = exc; return null; } throw exc; }
// in src/org/python/core/PyListDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyListDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyListDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyFrozenSetDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyFrozenSetDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyFrozenSetDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyDictionaryDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyDictionaryDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyDictionaryDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyBytecode.java
catch (PyException pye) { if (pye.match(Py.AttributeError)) { throw Py.ImportError(String.format("cannot import name %.230s", name)); } else { throw pye; } }
// in src/org/python/core/PyBytecode.java
catch (PyException pye) { if (!pye.match(Py.StopIteration)) { throw pye; } }
// in src/org/python/core/PyStringDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyStringDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyStringDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/codecs.java
catch (PyException exc) { if (exc.type != Py.ImportError) { throw exc; } }
// in src/org/python/core/codecs.java
catch (PyException ex) { if (ex.match(Py.LookupError)) { // If we couldn't find an encoding, see if we have a builtin if (encoding.equals("utf-8")) { return wrapDecodeResult(PyUnicode_DecodeUTF8(v.toString(), errors)); } else if(encoding.equals("utf-7")) { return wrapDecodeResult(PyUnicode_DecodeUTF7(v.toString(), errors)); } else if(encoding.equals("latin-1")) { return wrapDecodeResult(PyUnicode_DecodeLatin1(v.toString(), v.__len__(), errors)); } } throw ex; }
// in src/org/python/core/codecs.java
catch (PyException ex) { if (ex.match(Py.LookupError)) { // If we couldn't find an encoding, see if we have a builtin if (encoding.equals("utf-8")) { return PyUnicode_EncodeUTF8(v.toString(), errors); } else if(encoding.equals("utf-7")) { return codecs.PyUnicode_EncodeUTF7(v.toString(), false, false, errors); } } throw ex; }
// in src/org/python/core/PyException.java
catch (PyException pye) { // This function must not fail, so print the error here Py.writeUnraisable(pye, type); return false; }
// in src/org/python/core/BaseSet.java
catch (PyException pye) { PyFrozenSet frozen = asFrozen(pye, other); return _set.contains(frozen); }
// in src/org/python/core/PyInteger.java
catch (PyException pye) { if (pye.match(Py.OverflowError)) { return ((PyString) x).atol(base); } throw pye; }
// in src/org/python/core/PyInteger.java
catch (PyException pye) { if (!pye.match(Py.AttributeError)) { throw pye; } throw Py.TypeError("int() argument must be a string or a number"); }
// in src/org/python/core/PyObjectDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyObjectDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyObjectDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyComplexDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyComplexDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyComplexDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyLong.java
catch (PyException pye) { if (!pye.match(Py.AttributeError)) { throw pye; } throw Py.TypeError(String.format("long() argument must be a string or a number, " + "not '%.200s'", x.getType().fastGetName())); }
// in src/org/python/core/PyLong.java
catch (PyException e) { return Py.NoConversion; }
// in src/org/python/core/PyClassMethodDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyClassMethodDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyClassMethodDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyMethod.java
catch (PyException pye) { // continue }
// in src/org/python/core/PyTupleDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyTupleDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyTupleDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyString.java
catch (PyException e) { if (e.match(Py.OverflowError)) { return atol(10); } throw e; }
// in src/org/python/core/PyString.java
catch (PyException e) { // XXX: Swallow customs AttributeError throws from __float__ methods // No better alternative for the moment if (e.match(Py.AttributeError)) { throw Py.TypeError("int argument required"); } throw e; }
// in src/org/python/core/PyString.java
catch (PyException pye) { throw !pye.match(Py.TypeError) ? pye : Py.TypeError("float argument required"); }
// in src/org/python/core/PyString.java
catch (PyException e){ if (e.match(Py.AttributeError)) { throw Py.TypeError("%c requires int or char"); } throw e; }
// in src/org/python/core/imp.java
catch (PyException pye) { // another thread may have deleted it if (!pye.match(Py.KeyError)) { throw pye; } }
// in src/org/python/core/imp.java
catch (PyException e) { if (!e.match(Py.ImportError)) { throw e; } }
// in src/org/python/core/ClasspathPyImporterDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/ClasspathPyImporterDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/ClasspathPyImporterDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyGenerator.java
catch (PyException e) { if (!(e.type == Py.StopIteration || e.type == Py.GeneratorExit)) { throw e; } }
// in src/org/python/core/PyGenerator.java
catch (PyException pye) { // PEP 342 specifies that if an exception is raised by close, // we output to stderr and then forget about it; String className = PyException.exceptionClassName(pye.type); int lastDot = className.lastIndexOf('.'); if (lastDot != -1) { className = className.substring(lastDot + 1); } String msg = String.format("Exception %s: %s in %s", className, pye.value.__repr__(), __repr__()); Py.println(Py.getSystemState().stderr, Py.newString(msg)); }
// in src/org/python/core/PyGenerator.java
catch (PyException pye) { if (!(pye.type == Py.StopIteration || pye.type == Py.GeneratorExit)) { gi_frame = null; throw pye; } else { stopException = pye; gi_frame = null; return null; } }
// in src/org/python/core/Deriveds.java
catch (PyException pye) { if (!pye.match(Py.AttributeError)) { throw pye; } else { // saved to avoid swallowing custom AttributeErrors, and pass through to // __getattr__ firstAttributeError = pye; } }
// in src/org/python/util/PyFilter.java
catch (PyException e) { throw new ServletException(e); }
// in src/org/python/util/JycompileAntTask.java
catch (PyException pye) { pye.printStackTrace(); throw new BuildException("Compile failed; see the compiler error output for details."); }
// in src/org/python/util/InteractiveInterpreter.java
catch (PyException exc) { if (exc.match(Py.SyntaxError)) { // Case 1 showexception(exc); return false; } else if (exc.match(Py.ValueError) || exc.match(Py.OverflowError)) { // Should not print the stack trace, just the error. showexception(exc); return false; } else { throw exc; } }
// in src/org/python/util/InteractiveInterpreter.java
catch (PyException exc) { if (exc.match(Py.SystemExit)) throw exc; showexception(exc); }
// in src/org/python/util/InteractiveConsole.java
catch(PyException exc) { if(!exc.match(Py.EOFError)) throw exc; write("\n"); break; }
// in src/org/python/util/PyServlet.java
catch (PyException e) { throw new ServletException(e); }
// in src/org/python/util/PyServlet.java
catch (PyException e) { throw new ServletException(e); }
// in src/org/python/util/jython.java
catch (PyException pye) { if (!pye.match(Py.ImportError)) { System.err.println("error importing site"); Py.printException(pye); System.exit(-1); } }
// in src/org/python/util/jython.java
catch (PyException pye) { // continue }
// in src/org/python/util/PythonInterpreter.java
catch (PyException pye) { // fall through }
// in src/org/python/util/PythonInterpreter.java
catch (PyException pye) { // fall through }
478
            
// in src/com/ziclix/python/sql/Fetch.java
catch (PyException e) { throw e; }
// in src/com/ziclix/python/sql/Fetch.java
catch (PyException e) { throw e; }
// in src/com/ziclix/python/sql/Fetch.java
catch (PyException e) { throw e; }
// in src/com/ziclix/python/sql/Fetch.java
catch (PyException e) { throw e; }
// in src/com/ziclix/python/sql/PyStatement.java
catch (PyException e) { throw zxJDBC.makeException(zxJDBC.ProgrammingError, zxJDBC.getString("bindingValue")); }
// in src/com/ziclix/python/sql/PyCursor.java
catch (PyException e) { throw e; }
// in src/com/ziclix/python/sql/PyCursor.java
catch (PyException e) { throw e; }
// in src/com/xhaus/modjy/ModjyJServlet.java
catch (PyException ix) { throw new ServletException("Unable to import '" + MODJY_PYTHON_CLASSNAME + "': maybe you need to set the '" + PYTHON_HOME_PARAM + "' parameter?", ix); }
// in src/com/xhaus/modjy/ModjyJServlet.java
catch (PyException pyx) { throw new ServletException("Exception creating modjy servlet: " + pyx.toString(), pyx); }
// in src/org/python/compiler/Module.java
catch (PyException e) { if (!e.match(Py.SyntaxWarning)) { throw e; } }
// in src/org/python/antlr/ast/aliasDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/aliasDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/aliasDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/AttributeDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/AttributeDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/AttributeDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/UnaryOpDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/UnaryOpDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/UnaryOpDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/BreakDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/BreakDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/BreakDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/BoolOpDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/BoolOpDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/BoolOpDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ListCompDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/ListCompDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ListCompDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ContinueDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/ContinueDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ContinueDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/TupleDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/TupleDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/TupleDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/InteractiveDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/InteractiveDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/InteractiveDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/DeleteDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/DeleteDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/DeleteDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/IndexDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/IndexDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/IndexDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ModuleDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/ModuleDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ModuleDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/CallDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/CallDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/CallDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ReturnDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/ReturnDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ReturnDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ForDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/ForDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ForDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ExceptHandlerDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/ExceptHandlerDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ExceptHandlerDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/SubscriptDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/SubscriptDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/SubscriptDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/DictDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/DictDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/DictDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/LambdaDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/LambdaDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/LambdaDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/GlobalDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/GlobalDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/GlobalDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ListDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/ListDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ListDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/BinOpDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/BinOpDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/BinOpDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ClassDefDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/ClassDefDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ClassDefDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ExpressionDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/ExpressionDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ExpressionDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/SliceDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/SliceDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/SliceDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/NumDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/NumDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/NumDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ExprDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/ExprDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ExprDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/NameDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/NameDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/NameDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/TryFinallyDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/TryFinallyDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/TryFinallyDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/IfExpDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/IfExpDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/IfExpDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/AugAssignDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/AugAssignDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/AugAssignDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ImportDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/ImportDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ImportDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/IfDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/IfDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/IfDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/PassDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/PassDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/PassDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/FunctionDefDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/FunctionDefDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/FunctionDefDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/argumentsDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/argumentsDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/argumentsDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/WithDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/WithDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/WithDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ImportFromDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/ImportFromDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ImportFromDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/CompareDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/CompareDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/CompareDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ReprDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/ReprDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ReprDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/StrDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/StrDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/StrDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/YieldDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/YieldDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/YieldDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/EllipsisDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/EllipsisDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/EllipsisDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/RaiseDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/RaiseDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/RaiseDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/AssignDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/AssignDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/AssignDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/GeneratorExpDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/GeneratorExpDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/GeneratorExpDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/SuiteDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/SuiteDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/SuiteDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/AssertDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/AssertDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/AssertDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/TryExceptDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/TryExceptDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/TryExceptDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ExecDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/ExecDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ExecDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/WhileDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/WhileDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/WhileDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/keywordDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/keywordDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/keywordDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/comprehensionDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/comprehensionDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/comprehensionDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ExtSliceDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/ExtSliceDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/ExtSliceDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/PrintDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/ast/PrintDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/ast/PrintDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/PowDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/PowDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/PowDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/LtEDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/LtEDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/LtEDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/ParamDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/ParamDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/ParamDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/EqDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/EqDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/EqDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/GtDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/GtDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/GtDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/IsDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/IsDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/IsDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/GtEDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/GtEDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/GtEDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/StoreDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/StoreDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/StoreDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/BitOrDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/BitOrDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/BitOrDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/RShiftDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/RShiftDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/RShiftDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/BitAndDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/BitAndDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/BitAndDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/NotInDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/NotInDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/NotInDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/LtDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/LtDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/LtDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/FloorDivDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/FloorDivDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/FloorDivDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/USubDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/USubDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/USubDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/InvertDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/InvertDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/InvertDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/AugLoadDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/AugLoadDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/AugLoadDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/AugStoreDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/AugStoreDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/AugStoreDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/LoadDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/LoadDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/LoadDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/IsNotDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/IsNotDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/IsNotDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/BitXorDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/BitXorDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/BitXorDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/NotEqDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/NotEqDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/NotEqDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/NotDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/NotDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/NotDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/AndDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/AndDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/AndDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/ModDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/ModDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/ModDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/AddDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/AddDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/AddDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/DelDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/DelDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/DelDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/DivDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/DivDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/DivDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/LShiftDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/LShiftDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/LShiftDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/InDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/InDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/InDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/MultDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/MultDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/MultDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/UAddDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/UAddDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/UAddDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/OrDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/OrDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/OrDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/SubDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/antlr/op/SubDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/antlr/op/SubDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/jsr223/PyScriptEngine.java
catch (PyException pye) { throw scriptException(pye); }
// in src/org/python/jsr223/PyScriptEngine.java
catch (PyException pye) { throw scriptException(pye); }
// in src/org/python/jsr223/PyScriptEngine.java
catch (PyException pye) { throw scriptException(pye); }
// in src/org/python/jsr223/PyScriptEngine.java
catch (PyException pye) { throw scriptException(pye); }
// in src/org/python/jsr223/PyScriptEngine.java
catch (PyException pye) { throw scriptException(pye); }
// in src/org/python/jsr223/PyScriptEngine.java
catch (PyException pye) { throw scriptException(pye); }
// in src/org/python/modules/zipimport/zipimporterDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/modules/zipimport/zipimporterDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/modules/zipimport/zipimporterDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/modules/zipimport/zipimporter.java
catch (PyException pye) { if (!pye.match(Py.TypeError)) { throw pye; } time = -1; date = -1; }
// in src/org/python/modules/struct.java
catch (PyException ex) { throw StructError("required argument is not an integer"); }
// in src/org/python/modules/binascii.java
catch (PyException e) { if (e.match(Py.AttributeError) || e.match(Py.ValueError)) throw Py.TypeError(errMsg); throw e; }
// in src/org/python/modules/_weakref/ReferenceTypeDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/modules/_weakref/ReferenceTypeDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/modules/_weakref/ReferenceTypeDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/modules/posix/PosixModule.java
catch (PyException pye) { if (!pye.match(Py.OSError)) { throw pye; } // ENOENT result = false; }
// in src/org/python/modules/posix/PosixModule.java
catch (PyException pye) { throw badFD(); }
// in src/org/python/modules/posix/PosixModule.java
catch (PyException pye) { if (!pye.match(Py.IOError)) { throw pye; } throw Py.OSError(Errno.EINVAL); }
// in src/org/python/modules/posix/PosixModule.java
catch (PyException pye) { throw Py.IOError(Errno.EBADF); }
// in src/org/python/modules/posix/PosixModule.java
catch (PyException pye) { throw badFD(); }
// in src/org/python/modules/posix/PosixModule.java
catch (PyException pye) { throw badFD(); }
// in src/org/python/modules/posix/PosixModule.java
catch (PyException pye) { throw badFD(); }
// in src/org/python/modules/posix/PosixModule.java
catch (PyException pye) { if (!pye.match(Py.KeyError)) { throw pye; } }
// in src/org/python/modules/thread/PyLocalDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/modules/thread/PyLocalDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/modules/thread/PyLocalDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/modules/_csv/PyDialectDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/modules/_csv/PyDialectDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/modules/_csv/PyDialectDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/modules/random/PyRandomDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/modules/random/PyRandomDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/modules/random/PyRandomDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/modules/_collections/PyDequeDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/modules/_collections/PyDequeDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/modules/_collections/PyDequeDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/modules/_collections/PyDefaultDictDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/modules/_collections/PyDefaultDictDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/modules/_collections/PyDefaultDictDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/modules/_collections/PyDeque.java
catch (PyException pe) { if (pe.match(Py.KeyError)) { return null; } throw pe; }
// in src/org/python/modules/itertools.java
catch (PyException pyEx) { if (pyEx.match(Py.StopIteration)) { // store exception - will be used by PyIterator.next() stopException = pyEx; } else { throw pyEx; } }
// in src/org/python/modules/itertools.java
catch (PyException pyEx) { if (pyEx.match(Py.TypeError)) { throw Py.ValueError(msg); } else { throw pyEx; } }
// in src/org/python/modules/_functools/PyPartialDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/modules/_functools/PyPartialDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/modules/_functools/PyPartialDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/modules/time/Time.java
catch (PyException e) { // CPython's mktime raises OverflowErrors... yuck! e.type = Py.OverflowError; throw e; }
// in src/org/python/modules/PyTeeIterator.java
catch (PyException pyEx) { if (pyEx.match(Py.StopIteration)) { // store exception - will be used by PyIterator.next() stopException = pyEx; } else { throw pyEx; } }
// in src/org/python/core/PyObject.java
catch (PyException pye) { if (!pye.match(Py.AttributeError)) { throw pye; } }
// in src/org/python/core/PyObject.java
catch (PyException exc) { if (exc.match(Py.AttributeError)) { return null; } throw exc; }
// in src/org/python/core/PyObject.java
catch (PyException e) { if (e.value.getJavaProxy() != null) { Object t = e.value.__tojava__(Throwable.class); if (t != null && t != Py.NoConversion) { throw (Throwable) t; } } else { ThreadState ts = Py.getThreadState(); if (ts.frame == null) { Py.maybeSystemExit(e); } if (Options.showPythonProxyExceptions) { Py.stderr.println( "Exception in Python proxy returning to Java:"); Py.printException(e); } } throw e; }
// in src/org/python/core/PyObject.java
catch (PyException exc) { if (exc.match(Py.KeyError)) { noAttributeError(name); } else { throw exc; } }
// in src/org/python/core/PyObject.java
catch (PyException pye) { if (pye.match(Py.AttributeError)) { throw Py.TypeError("an integer is required"); } throw pye; }
// in src/org/python/core/PyObject.java
catch (PyException pye) { if (pye.match(Py.AttributeError)) { throw Py.TypeError("an integer is required"); } throw pye; }
// in src/org/python/core/PyObject.java
catch (PyException pye) { if (pye.match(Py.AttributeError)) { throw Py.TypeError("a float is required"); } throw pye; }
// in src/org/python/core/PyStringMap.java
catch(PyException pye) { if (pye.match(Py.TypeError)) { throw Py.TypeError(String.format("cannot convert dictionary update sequence " + "element #%d to a sequence", i)); } throw pye; }
// in src/org/python/core/PyList.java
catch (PyException pye) { if (!pye.match(Py.TypeError)) { throw pye; } return null; }
// in src/org/python/core/PyFloatDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyFloatDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyFloatDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyArrayDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyArrayDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyArrayDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyEnumerateDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyEnumerateDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyEnumerateDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PySystemState.java
catch (PyException pye) { // KeyError if (ret == null) { throw Py.AttributeError(name); } }
// in src/org/python/core/PyDictionary.java
catch(PyException pye) { if (pye.match(Py.TypeError)) { throw Py.TypeError(String.format("cannot convert dictionary update sequence " + "element #%d to a sequence", i)); } throw pye; }
// in src/org/python/core/PyUnicodeDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyUnicodeDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyUnicodeDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyFastSequenceIter.java
catch (PyException pye) { if (pye.match(Py.StopIteration)) { seq = null; return null; } throw pye; }
// in src/org/python/core/PyComplex.java
catch (PyException pye) { if (!pye.match(Py.AttributeError)) { // __complex__ not supported throw pye; } // otherwise try other means }
// in src/org/python/core/PyComplex.java
catch (PyException pye) { if (pye.match(Py.AttributeError)) { // __float__ not supported throw Py.TypeError("complex() argument must be a string or a number"); } throw pye; }
// in src/org/python/core/PyComplex.java
catch (PyException pye) { if (pye.match(Py.AttributeError)) { // __float__ not supported throw Py.TypeError("complex() argument must be a string or a number"); } throw pye; }
// in src/org/python/core/PyInstance.java
catch (PyException exc) { if (exc.match(Py.KeyError)) throw Py.AttributeError("class " + instclass.__name__ + " has no attribute '" + name + "'"); }
// in src/org/python/core/PyInstance.java
catch (PyException e) { if (e.match(Py.IndexError)) return null; if (e.match(Py.KeyError)) return null; throw e; }
// in src/org/python/core/PyInstance.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyInstance.java
catch (PyException pye) { if (!pye.match(Py.AttributeError)) { throw pye; } throw Py.TypeError("object cannot be interpreted as an index"); }
// in src/org/python/core/ContextGuard.java
catch(PyException e) { if (e.equals(exception)) { return false; } else { throw e; } }
// in src/org/python/core/PyFrame.java
catch (PyException pye) { if (pye.match(Py.KeyError)) { throw Py.NameError(String.format(NAME_ERROR_MSG, index)); } throw pye; }
// in src/org/python/core/PyFrame.java
catch (PyException pye) { if (pye.match(Py.KeyError)) { throw Py.NameError(String.format(GLOBAL_NAME_ERROR_MSG, index)); } throw pye; }
// in src/org/python/core/PyLongDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyLongDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyLongDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/AstList.java
catch (PyException pye) { if (!pye.match(Py.TypeError)) { throw pye; } return null; }
// in src/org/python/core/AstList.java
catch (PyException pye) { if (pye.match(Py.TypeError)) { throw Py.TypeError("can only assign an iterable"); } throw pye; }
// in src/org/python/core/PyFloat.java
catch (PyException e) { if (e.match(Py.AttributeError)) { // Translate AttributeError to TypeError // XXX: We are using the same message as CPython, even if // it is not strictly correct (instances of types // that implement the __float__ method are also // valid arguments) throw Py.TypeError("float() argument must be a string or a number"); } throw e; }
// in src/org/python/core/PySlice.java
catch (PyException pye) { if (!pye.match(Py.TypeError)) { throw pye; } }
// in src/org/python/core/PyIntegerDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyIntegerDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyIntegerDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyBaseExceptionDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyBaseExceptionDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyBaseExceptionDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/io/IOBase.java
catch (PyException pye) { if (!pye.match(Py.IOError)) { throw pye; } // If flush() fails, just give up }
// in src/org/python/core/io/BufferedIOMixin.java
catch (PyException pye) { if (!pye.match(Py.IOError)) { throw pye; } // If flush() fails, just give up }
// in src/org/python/core/PySuperDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PySuperDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PySuperDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyArray.java
catch (PyException e) { delegate.setSize(afterLast); throw new PyException(e.type, e.value); }
// in src/org/python/core/PyArray.java
catch(PyException e) { // trap any exception - any error invalidates the whole list delegate.setSize(size); // re-throw throw new PyException(e.type, e.value); }
// in src/org/python/core/PyModuleDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyModuleDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyModuleDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/__builtin__.java
catch (PyException pye) { if (!pye.match(Py.AttributeError)) { throw pye; } attributeError = pye; }
// in src/org/python/core/__builtin__.java
catch (PyException e) { if (e.match(Py.AttributeError)) { throw Py.TypeError("vars() argument must have __dict__ attribute"); } throw e; }
// in src/org/python/core/__builtin__.java
catch (PyException e) { if (e.match(Py.StopIteration)) { return ret; } throw e; }
// in src/org/python/core/PyTypeDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyTypeDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyTypeDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PySetDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PySetDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PySetDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyType.java
catch (PyException t) { for (Iterator<Object> it = savedSubMros.iterator(); it.hasNext();) { PyType subtype = (PyType)it.next(); PyObject[] subtypeSavedMro = (PyObject[])it.next(); subtype.mro = subtypeSavedMro; } bases = savedBases; base = savedBase; mro = savedMro; throw t; }
// in src/org/python/core/PythonTraceFunction.java
catch(PyException exc) { frame.tracefunc = null; ts.tracefunc = null; ts.profilefunc = null; throw exc; }
// in src/org/python/core/PyPropertyDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyPropertyDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyPropertyDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/Py.java
catch (PyException e) { if (e.match(ImportError)) { return null; } throw e; }
// in src/org/python/core/Py.java
catch (PyException e) { Py.getSystemState().callExitFunc(); if (e.match(Py.SystemExit)) { return; } throw e; }
// in src/org/python/core/Py.java
catch (PyException pye) { if (!pye.match(TypeError)) { throw pye; } pye.value = Py.newString(String.format("Error when calling the metaclass bases\n " + "%s", pye.value.__str__().toString())); throw pye; }
// in src/org/python/core/Py.java
catch (PyException exc) { if (exc.match(Py.TypeError)) { throw Py.TypeError(message); } throw exc; }
// in src/org/python/core/PySequenceIter.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) { seq = null; return null; } throw exc; }
// in src/org/python/core/PyFileDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyFileDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyFileDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyCallIter.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) { callable = null; stopException = exc; return null; } throw exc; }
// in src/org/python/core/PyListDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyListDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyListDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyFrozenSetDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyFrozenSetDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyFrozenSetDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyDictionaryDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyDictionaryDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyDictionaryDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyBytecode.java
catch (PyException pye) { if (pye.match(Py.AttributeError)) { throw Py.ImportError(String.format("cannot import name %.230s", name)); } else { throw pye; } }
// in src/org/python/core/PyBytecode.java
catch (PyException pye) { if (!pye.match(Py.StopIteration)) { throw pye; } }
// in src/org/python/core/PyStringDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyStringDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyStringDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/codecs.java
catch (PyException exc) { if (exc.type != Py.ImportError) { throw exc; } }
// in src/org/python/core/codecs.java
catch (PyException ex) { if (ex.match(Py.LookupError)) { // If we couldn't find an encoding, see if we have a builtin if (encoding.equals("utf-8")) { return wrapDecodeResult(PyUnicode_DecodeUTF8(v.toString(), errors)); } else if(encoding.equals("utf-7")) { return wrapDecodeResult(PyUnicode_DecodeUTF7(v.toString(), errors)); } else if(encoding.equals("latin-1")) { return wrapDecodeResult(PyUnicode_DecodeLatin1(v.toString(), v.__len__(), errors)); } } throw ex; }
// in src/org/python/core/codecs.java
catch (PyException ex) { if (ex.match(Py.LookupError)) { // If we couldn't find an encoding, see if we have a builtin if (encoding.equals("utf-8")) { return PyUnicode_EncodeUTF8(v.toString(), errors); } else if(encoding.equals("utf-7")) { return codecs.PyUnicode_EncodeUTF7(v.toString(), false, false, errors); } } throw ex; }
// in src/org/python/core/PyInteger.java
catch (PyException pye) { if (pye.match(Py.OverflowError)) { return ((PyString) x).atol(base); } throw pye; }
// in src/org/python/core/PyInteger.java
catch (PyException pye) { if (!pye.match(Py.AttributeError)) { throw pye; } throw Py.TypeError("int() argument must be a string or a number"); }
// in src/org/python/core/PyObjectDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyObjectDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyObjectDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyComplexDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyComplexDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyComplexDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyLong.java
catch (PyException pye) { if (!pye.match(Py.AttributeError)) { throw pye; } throw Py.TypeError(String.format("long() argument must be a string or a number, " + "not '%.200s'", x.getType().fastGetName())); }
// in src/org/python/core/PyClassMethodDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyClassMethodDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyClassMethodDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyTupleDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/PyTupleDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyTupleDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyString.java
catch (PyException e) { if (e.match(Py.OverflowError)) { return atol(10); } throw e; }
// in src/org/python/core/PyString.java
catch (PyException e) { // XXX: Swallow customs AttributeError throws from __float__ methods // No better alternative for the moment if (e.match(Py.AttributeError)) { throw Py.TypeError("int argument required"); } throw e; }
// in src/org/python/core/PyString.java
catch (PyException pye) { throw !pye.match(Py.TypeError) ? pye : Py.TypeError("float argument required"); }
// in src/org/python/core/PyString.java
catch (PyException e){ if (e.match(Py.AttributeError)) { throw Py.TypeError("%c requires int or char"); } throw e; }
// in src/org/python/core/imp.java
catch (PyException pye) { // another thread may have deleted it if (!pye.match(Py.KeyError)) { throw pye; } }
// in src/org/python/core/imp.java
catch (PyException e) { if (!e.match(Py.ImportError)) { throw e; } }
// in src/org/python/core/ClasspathPyImporterDerived.java
catch (PyException exc) { if (exc.match(Py.StopIteration)) return null; throw exc; }
// in src/org/python/core/ClasspathPyImporterDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/ClasspathPyImporterDerived.java
catch (PyException exc) { if (exc.match(Py.LookupError)) return null; throw exc; }
// in src/org/python/core/PyGenerator.java
catch (PyException e) { if (!(e.type == Py.StopIteration || e.type == Py.GeneratorExit)) { throw e; } }
// in src/org/python/core/PyGenerator.java
catch (PyException pye) { if (!(pye.type == Py.StopIteration || pye.type == Py.GeneratorExit)) { gi_frame = null; throw pye; } else { stopException = pye; gi_frame = null; return null; } }
// in src/org/python/core/Deriveds.java
catch (PyException pye) { if (!pye.match(Py.AttributeError)) { throw pye; } else { // saved to avoid swallowing custom AttributeErrors, and pass through to // __getattr__ firstAttributeError = pye; } }
// in src/org/python/util/PyFilter.java
catch (PyException e) { throw new ServletException(e); }
// in src/org/python/util/JycompileAntTask.java
catch (PyException pye) { pye.printStackTrace(); throw new BuildException("Compile failed; see the compiler error output for details."); }
// in src/org/python/util/InteractiveInterpreter.java
catch (PyException exc) { if (exc.match(Py.SyntaxError)) { // Case 1 showexception(exc); return false; } else if (exc.match(Py.ValueError) || exc.match(Py.OverflowError)) { // Should not print the stack trace, just the error. showexception(exc); return false; } else { throw exc; } }
// in src/org/python/util/InteractiveInterpreter.java
catch (PyException exc) { if (exc.match(Py.SystemExit)) throw exc; showexception(exc); }
// in src/org/python/util/InteractiveConsole.java
catch(PyException exc) { if(!exc.match(Py.EOFError)) throw exc; write("\n"); break; }
// in src/org/python/util/PyServlet.java
catch (PyException e) { throw new ServletException(e); }
// in src/org/python/util/PyServlet.java
catch (PyException e) { throw new ServletException(e); }
2
runtime (Domain) PyIgnoreMethodTag
public class PyIgnoreMethodTag extends RuntimeException {
}
0 0 8
            
// in src/org/python/modules/operator.java
public static void classDictInit(PyObject dict) throws PyIgnoreMethodTag { dict.__setitem__("__add__", new OperatorFunctions("__add__", 0, 2)); dict.__setitem__("add", new OperatorFunctions("add", 0, 2)); dict.__setitem__("__concat__", new OperatorFunctions("__concat__", 0, 2)); dict.__setitem__("concat", new OperatorFunctions("concat", 0, 2)); dict.__setitem__("__and__", new OperatorFunctions("__and__", 1, 2)); dict.__setitem__("and_", new OperatorFunctions("and_", 1, 2)); dict.__setitem__("__div__", new OperatorFunctions("__div__", 2, 2)); dict.__setitem__("div", new OperatorFunctions("div", 2, 2)); dict.__setitem__("__lshift__", new OperatorFunctions("__lshift__", 3, 2)); dict.__setitem__("lshift", new OperatorFunctions("lshift", 3, 2)); dict.__setitem__("__mod__", new OperatorFunctions("__mod__", 4, 2)); dict.__setitem__("mod", new OperatorFunctions("mod", 4, 2)); dict.__setitem__("__mul__", new OperatorFunctions("__mul__", 5, 2)); dict.__setitem__("mul", new OperatorFunctions("mul", 5, 2)); dict.__setitem__("__repeat__", new OperatorFunctions("__repeat__", 5, 2)); dict.__setitem__("repeat", new OperatorFunctions("repeat", 5, 2)); dict.__setitem__("__or__", new OperatorFunctions("__or__", 6, 2)); dict.__setitem__("or_", new OperatorFunctions("or_", 6, 2)); dict.__setitem__("__rshift__", new OperatorFunctions("__rshift__", 7, 2)); dict.__setitem__("rshift", new OperatorFunctions("rshift", 7, 2)); dict.__setitem__("__sub__", new OperatorFunctions("__sub__", 8, 2)); dict.__setitem__("sub", new OperatorFunctions("sub", 8, 2)); dict.__setitem__("__xor__", new OperatorFunctions("__xor__", 9, 2)); dict.__setitem__("xor", new OperatorFunctions("xor", 9, 2)); dict.__setitem__("__abs__", new OperatorFunctions("__abs__", 10, 1)); dict.__setitem__("abs", new OperatorFunctions("abs", 10, 1)); dict.__setitem__("__inv__", new OperatorFunctions("__inv__", 11, 1)); dict.__setitem__("inv", new OperatorFunctions("inv", 11, 1)); dict.__setitem__("__neg__", new OperatorFunctions("__neg__", 12, 1)); dict.__setitem__("neg", new OperatorFunctions("neg", 12, 1)); dict.__setitem__("__not__", new OperatorFunctions("__not__", 13, 1)); dict.__setitem__("not_", new OperatorFunctions("not_", 13, 1)); dict.__setitem__("__pos__", new OperatorFunctions("__pos__", 14, 1)); dict.__setitem__("pos", new OperatorFunctions("pos", 14, 1)); dict.__setitem__("truth", new OperatorFunctions("truth", 15, 1)); dict.__setitem__("isCallable", new OperatorFunctions("isCallable", 16, 1)); dict.__setitem__("isMappingType", new OperatorFunctions("isMappingType", 17, 1)); dict.__setitem__("isNumberType", new OperatorFunctions("isNumberType", 18, 1)); dict.__setitem__("isSequenceType", new OperatorFunctions("isSequenceType", 19, 1)); dict.__setitem__("contains", new OperatorFunctions("contains", 20, 2)); dict.__setitem__("__contains__", new OperatorFunctions("__contains__", 20, 2)); dict.__setitem__("sequenceIncludes", new OperatorFunctions("sequenceIncludes", 20, 2)); dict.__setitem__("__delitem__", new OperatorFunctions("__delitem__", 21, 2)); dict.__setitem__("delitem", new OperatorFunctions("delitem", 21, 2)); dict.__setitem__("__delslice__", new OperatorFunctions("__delslice__", 22, 3)); dict.__setitem__("delslice", new OperatorFunctions("delslice", 22, 3)); dict.__setitem__("__getitem__", new OperatorFunctions("__getitem__", 23, 2)); dict.__setitem__("getitem", new OperatorFunctions("getitem", 23, 2)); dict.__setitem__("__getslice__", new OperatorFunctions("__getslice__", 24, 3)); dict.__setitem__("getslice", new OperatorFunctions("getslice", 24, 3)); dict.__setitem__("__setitem__", new OperatorFunctions("__setitem__", 25, 3)); dict.__setitem__("setitem", new OperatorFunctions("setitem", 25, 3)); dict.__setitem__("__setslice__", new OperatorFunctions("__setslice__", 26, 4)); dict.__setitem__("setslice", new OperatorFunctions("setslice", 26, 4)); dict.__setitem__("ge", new OperatorFunctions("ge", 27, 2)); dict.__setitem__("__ge__", new OperatorFunctions("__ge__", 27, 2)); dict.__setitem__("le", new OperatorFunctions("le", 28, 2)); dict.__setitem__("__le__", new OperatorFunctions("__le__", 28, 2)); dict.__setitem__("eq", new OperatorFunctions("eq", 29, 2)); dict.__setitem__("__eq__", new OperatorFunctions("__eq__", 29, 2)); dict.__setitem__("floordiv", new OperatorFunctions("floordiv", 30, 2)); dict.__setitem__("__floordiv__", new OperatorFunctions("__floordiv__", 30, 2)); dict.__setitem__("gt", new OperatorFunctions("gt", 31, 2)); dict.__setitem__("__gt__", new OperatorFunctions("__gt__", 31, 2)); dict.__setitem__("invert", new OperatorFunctions("invert", 32, 1)); dict.__setitem__("__invert__", new OperatorFunctions("__invert__", 32, 1)); dict.__setitem__("lt", new OperatorFunctions("lt", 33, 2)); dict.__setitem__("__lt__", new OperatorFunctions("__lt__", 33, 2)); dict.__setitem__("ne", new OperatorFunctions("ne", 34, 2)); dict.__setitem__("__ne__", new OperatorFunctions("__ne__", 34, 2)); dict.__setitem__("truediv", new OperatorFunctions("truediv", 35, 2)); dict.__setitem__("__truediv__", new OperatorFunctions("__truediv__", 35, 2)); dict.__setitem__("pow", new OperatorFunctions("pow", 36, 2)); dict.__setitem__("__pow__", new OperatorFunctions("pow", 36, 2)); dict.__setitem__("is_", new OperatorFunctions("is_", 37, 2)); dict.__setitem__("is_not", new OperatorFunctions("is_not", 38, 2)); dict.__setitem__("__iadd__", new OperatorFunctions("__iadd__", 39, 2)); dict.__setitem__("iadd", new OperatorFunctions("iadd", 39, 2)); dict.__setitem__("__iconcat__", new OperatorFunctions("__iconcat__", 39, 2)); dict.__setitem__("iconcat", new OperatorFunctions("iconcat", 39, 2)); dict.__setitem__("__iand__", new OperatorFunctions("__iand__", 40, 2)); dict.__setitem__("iand", new OperatorFunctions("iand", 40, 2)); dict.__setitem__("__idiv__", new OperatorFunctions("__idiv__", 41, 2)); dict.__setitem__("idiv", new OperatorFunctions("idiv", 41, 2)); dict.__setitem__("__ifloordiv__", new OperatorFunctions("__ifloordiv__", 42, 2)); dict.__setitem__("ifloordiv", new OperatorFunctions("ifloordiv", 42, 2)); dict.__setitem__("__ilshift__", new OperatorFunctions("__ilshift__", 43, 2)); dict.__setitem__("ilshift", new OperatorFunctions("ilshift", 43, 2)); dict.__setitem__("__imod__", new OperatorFunctions("__imod__", 44, 2)); dict.__setitem__("imod", new OperatorFunctions("imod", 44, 2)); dict.__setitem__("__imul__", new OperatorFunctions("__imul__", 45, 2)); dict.__setitem__("imul", new OperatorFunctions("imul", 45, 2)); dict.__setitem__("__irepeat__", new OperatorFunctions("__irepeat__", 45, 2)); dict.__setitem__("irepeat", new OperatorFunctions("irepeat", 45, 2)); dict.__setitem__("__ior__", new OperatorFunctions("__ior__", 46, 2)); dict.__setitem__("ior", new OperatorFunctions("ior", 46, 2)); dict.__setitem__("__ipow__", new OperatorFunctions("__ipow__", 47, 2)); dict.__setitem__("ipow", new OperatorFunctions("ipow", 47, 2)); dict.__setitem__("__irshift__", new OperatorFunctions("__irshift__", 48, 2)); dict.__setitem__("irshift", new OperatorFunctions("irshift", 48, 2)); dict.__setitem__("__isub__", new OperatorFunctions("__isub__", 49, 2)); dict.__setitem__("isub", new OperatorFunctions("isub", 49, 2)); dict.__setitem__("__itruediv__", new OperatorFunctions("__itruediv__", 50, 2)); dict.__setitem__("itruediv", new OperatorFunctions("itruediv", 50, 2)); dict.__setitem__("__ixor__", new OperatorFunctions("__ixor__", 51, 2)); dict.__setitem__("ixor", new OperatorFunctions("ixor", 51, 2)); dict.__setitem__("__index__", new OperatorFunctions("__index__", 52, 1)); dict.__setitem__("index", new OperatorFunctions("index", 52, 1)); dict.__setitem__("attrgetter", PyAttrGetter.TYPE); dict.__setitem__("itemgetter", PyItemGetter.TYPE); }
// in src/org/python/core/PySystemState.java
void reload() throws PyIgnoreMethodTag { __dict__.invoke("update", getType().fastGetDict()); }
// in src/org/python/core/PySystemState.java
public void callExitFunc() throws PyIgnoreMethodTag { PyObject exitfunc = __findattr__("exitfunc"); if (exitfunc != null) { try { exitfunc.__call__(); } catch (PyException exc) { if (!exc.match(Py.SystemExit)) { Py.println(stderr, Py.newString("Error in sys.exitfunc:")); } Py.printException(exc); } } Py.flushLine(); }
// in src/org/python/core/PyArray.java
public static Class<?> char2class(char type) throws PyIgnoreMethodTag { switch(type){ case 'z': return Boolean.TYPE; case 'b': return Byte.TYPE; case 'B': return Short.TYPE; case 'u': return Integer.TYPE; case 'c': return Character.TYPE; case 'h': return Short.TYPE; case 'H': return Integer.TYPE; case 'i': return Integer.TYPE; case 'I': return Long.TYPE; case 'l': return Long.TYPE; case 'L': return Long.TYPE; case 'f': return Float.TYPE; case 'd': return Double.TYPE; default: throw Py.ValueError("bad typecode (must be c, b, B, u, h, H, i, I, l, L, f or d)"); } }
// in src/org/python/core/PyArray.java
public Object getArray() throws PyIgnoreMethodTag { return delegate.copyArray(); }
// in src/org/python/core/PySequence.java
Override public boolean isMappingType() throws PyIgnoreMethodTag { return false; }
// in src/org/python/core/PySequence.java
Override public boolean isNumberType() throws PyIgnoreMethodTag { return false; }
// in src/org/python/core/PySequence.java
Override public synchronized Object __tojava__(Class<?> c) throws PyIgnoreMethodTag { if (c.isArray()) { Class<?> component = c.getComponentType(); try { int n = __len__(); PyArray array = new PyArray(component, n); for (int i = 0; i < n; i++) { PyObject o = pyget(i); array.set(i, o); } return array.getArray(); } catch (Throwable t) { // ok } } return super.__tojava__(c); }
0 0 0
runtime (Domain) PyIndentationError
public class PyIndentationError extends PyException {
    int lineno, column;
    String text;
    String filename;

    public PyIndentationError(String s, int line, int column, String text,
                         String filename)
    {
        super(Py.IndentationError);
        PyObject[] tmp = new PyObject[] {
            new PyString(filename), new PyInteger(line),
            new PyInteger(column), new PyString(text)
        };

        this.value = new PyTuple(new PyString(s), new PyTuple(tmp));

        this.lineno = line;
        this.column = column;
        this.text = text;
        this.filename = filename;
    }
}
0 0 0 0 0 0
runtime (Domain) PySyntaxError
public class PySyntaxError extends PyException {
    int lineno;
    int column;
    String text;
    String filename;


    public PySyntaxError(String s, int line, int column, String text,
                         String filename)
    {
        super(Py.SyntaxError);
        //XXX: null text causes Java error, though I bet I'm not supposed to
        //     get null text.
        if (text == null) {
            text = "";
        }
        PyObject[] tmp = new PyObject[] {
            new PyString(filename), new PyInteger(line),
            new PyInteger(column), new PyString(text)
        };

        this.value = new PyTuple(new PyString(s), new PyTuple(tmp));

        this.lineno = line;
        this.column = column;
        this.text = text;
        this.filename = filename;
    }
}
1
            
// in src/org/python/core/ParserFacade.java
private static ExpectedEncodingBufferedReader prepBufReader(InputStream input, CompilerFlags cflags, String filename, boolean fromString, boolean universalNewlines) throws IOException { input = new BufferedInputStream(input); boolean bom = adjustForBOM(input); String encoding = readEncoding(input); if (encoding == null) { if (bom) { encoding = "utf-8"; } else if (cflags != null && cflags.encoding != null) { encoding = cflags.encoding; } } if (cflags.source_is_utf8) { if (encoding != null) { throw new ParseException("encoding declaration in Unicode string"); } encoding = "utf-8"; } cflags.encoding = encoding; if (universalNewlines) { // Enable universal newlines mode on the input StreamIO rawIO = new StreamIO(input, true); org.python.core.io.BufferedReader bufferedIO = new org.python.core.io.BufferedReader(rawIO, 0); UniversalIOWrapper textIO = new UniversalIOWrapper(bufferedIO); input = new TextIOInputStream(textIO); } Charset cs; try { // Use ascii for the raw bytes when no encoding was specified if (encoding == null) { if (fromString) { cs = Charset.forName("ISO-8859-1"); } else { cs = Charset.forName("ascii"); } } else { cs = Charset.forName(encoding); } } catch (UnsupportedCharsetException exc) { throw new PySyntaxError("Unknown encoding: " + encoding, 1, 0, "", filename); } CharsetDecoder dec = cs.newDecoder(); dec.onMalformedInput(CodingErrorAction.REPORT); dec.onUnmappableCharacter(CodingErrorAction.REPORT); return new ExpectedEncodingBufferedReader(new InputStreamReader(input, dec), encoding); }
1
            
// in src/org/python/core/ParserFacade.java
catch (UnsupportedCharsetException exc) { throw new PySyntaxError("Unknown encoding: " + encoding, 1, 0, "", filename); }
0 0 0 0
runtime (Domain) QueueClosedException
public class QueueClosedException extends RuntimeException {

    /**
     * Constructor QueueClosedException
     */
    public QueueClosedException() {
        super();
    }

    /**
     * Constructor QueueClosedException
     *
     * @param msg
     */
    public QueueClosedException(String msg) {
        super(msg);
    }
}
3
            
// in src/com/ziclix/python/sql/util/Queue.java
public synchronized void enqueue(Object element) throws InterruptedException { if (closed) { throw new QueueClosedException(); } this.queue.addLast(element); this.notify(); /* * Block while the capacity of the queue has been breached. */ while ((this.capacity > 0) && (this.queue.size() >= this.capacity)) { this.wait(); if (closed) { throw new QueueClosedException(); } } }
// in src/com/ziclix/python/sql/util/Queue.java
public synchronized Object dequeue() throws InterruptedException { while (this.queue.size() <= 0) { this.wait(); if (closed) { throw new QueueClosedException(); } } Object object = this.queue.removeFirst(); // if space exists, notify the other threads if (this.queue.size() < this.threshold) { this.notify(); } return object; }
0 0 1
            
// in src/com/ziclix/python/sql/pipe/Pipe.java
catch (QueueClosedException e) { /* * thrown by a closed queue when any operation is performed. we know * at this point that nothing else can happen to the queue and that * both producer and consumer will stop since one closed the queue * by throwing an exception (below) and the other is here. */ return; }
0 0
unknown (Lib) RecognitionException 0 0 2
            
// in src/org/python/antlr/FailFastHandler.java
public boolean mismatch(BaseRecognizer br, IntStream input, int ttype, BitSet follow) throws RecognitionException { throw new MismatchedTokenException(ttype, input); }
// in src/org/python/antlr/FailFastHandler.java
public Object recoverFromMismatchedToken(BaseRecognizer br, IntStream input, int ttype, BitSet follow) throws RecognitionException { throw new MismatchedTokenException(ttype, input); }
3
            
// in src/org/python/antlr/BaseParser.java
catch (RecognitionException e) { //XXX: this can't happen. Need to strip the throws from antlr // generated code. }
// in src/org/python/antlr/BaseParser.java
catch (RecognitionException e) { //I am only throwing ParseExceptions, but "throws RecognitionException" still gets //into the generated code. System.err.println("FIXME: pretty sure this can't happen -- but needs to be checked"); }
// in src/org/python/antlr/BaseParser.java
catch (RecognitionException e) { //XXX: this can't happen. Need to strip the throws from antlr // generated code. }
0 0
runtime (Lib) RuntimeException 18
            
// in src/org/python/expose/generate/TypeExposer.java
public TypeBuilder makeBuilder() { BytecodeLoader.Loader l = new BytecodeLoader.Loader(); if(ne != null) { ne.load(l); } for(DescriptorExposer de : descriptors) { de.load(l); } for(MethodExposer me : methods) { me.load(l); } Class descriptor = load(l); try { return (TypeBuilder)descriptor.newInstance(); } catch(Exception e) { // If we're unable to create the generated class, the process is // definitely ill, but that shouldn't be the case most of the time // so make this a runtime exception throw new RuntimeException("Unable to create generated builder", e); } }
// in src/org/python/Version.java
private static void loadProperties() { boolean loaded = false; final String versionProperties = "/org/python/version.properties"; InputStream in = Version.class.getResourceAsStream(versionProperties); if (in != null) { try { Properties properties = new Properties(); properties.load(in); loaded = true; PY_VERSION = properties.getProperty("jython.version"); PY_MAJOR_VERSION = Integer.valueOf(properties.getProperty("jython.major_version")); PY_MINOR_VERSION = Integer.valueOf(properties.getProperty("jython.minor_version")); PY_MICRO_VERSION = Integer.valueOf(properties.getProperty("jython.micro_version")); PY_RELEASE_LEVEL = Integer.valueOf(properties.getProperty("jython.release_level")); PY_RELEASE_SERIAL = Integer.valueOf(properties.getProperty("jython.release_serial")); DATE = properties.getProperty("jython.build.date"); TIME = properties.getProperty("jython.build.time"); SVN_REVISION = properties.getProperty("jython.build.svn_revision"); HG_BRANCH = properties.getProperty("jython.build.hg_branch"); HG_TAG = properties.getProperty("jython.build.hg_tag"); HG_VERSION = properties.getProperty("jython.build.hg_version"); } catch (IOException ioe) { System.err.println("There was a problem loading ".concat(versionProperties) .concat(":")); ioe.printStackTrace(); } finally { try { in.close(); } catch (IOException ioe) { // ok } } } if (!loaded) { // fail with a meaningful exception (cannot use Py exceptions here) throw new RuntimeException("unable to load ".concat(versionProperties)); } }
// in src/org/python/antlr/PythonTree.java
public <R> R accept(VisitorIF<R> visitor) throws Exception { throw new RuntimeException("Unexpected node: " + this); }
// in src/org/python/antlr/PythonTree.java
public void traverse(VisitorIF<?> visitor) throws Exception { throw new RuntimeException("Cannot traverse node: " + this); }
// in src/org/python/antlr/PythonTree.java
public void addChild(PythonTree t) { if ( t==null ) { return; // do nothing upon addChild(null) } PythonTree childTree = t; if ( childTree.isNil() ) { // t is an empty node possibly with children if ( this.children!=null && this.children == childTree.children ) { throw new RuntimeException("attempt to add child list to itself"); } // just add all of childTree's children to this if ( childTree.children!=null ) { if ( this.children!=null ) { // must copy, this has children already int n = childTree.children.size(); for (int i = 0; i < n; i++) { PythonTree c = childTree.children.get(i); this.children.add(c); // handle double-link stuff for each child of nil root c.setParent(this); c.setChildIndex(children.size()-1); } } else { // no children for this but t has children; just set pointer // call general freshener routine this.children = childTree.children; this.freshenParentAndChildIndexes(); } } } else { // child is not nil (don't care about children) if ( children==null ) { children = createChildrenList(); // create children list on demand } children.add(t); childTree.setParent(this); childTree.setChildIndex(children.size()-1); } }
// in src/org/python/antlr/PythonTreeAdaptor.java
Override public Object becomeRoot(Object newRoot, Object oldRoot) { //System.out.println("becomeroot new "+newRoot.toString()+" old "+oldRoot); PythonTree newRootTree = (PythonTree)newRoot; PythonTree oldRootTree = (PythonTree)oldRoot; if ( oldRoot==null ) { return newRoot; } // handle ^(nil real-node) if ( newRootTree.isNil() ) { int nc = newRootTree.getChildCount(); if ( nc==1 ) newRootTree = newRootTree.getChild(0); else if ( nc >1 ) { // TODO: make tree run time exceptions hierarchy throw new RuntimeException("more than one node as root (TODO: make exception hierarchy)"); } } // add oldRoot to newRoot; addChild takes care of case where oldRoot // is a flat list (i.e., nil-rooted tree). All children of oldRoot // are added to newRoot. newRootTree.addChild(oldRootTree); return newRootTree; }
// in src/org/python/modules/jffi/NativeType.java
static final com.kenai.jffi.Type jffiType(NativeType type) { switch (type) { case VOID: return com.kenai.jffi.Type.VOID; case BYTE: return com.kenai.jffi.Type.SINT8; case UBYTE: return com.kenai.jffi.Type.UINT8; case SHORT: return com.kenai.jffi.Type.SINT16; case USHORT: return com.kenai.jffi.Type.UINT16; case INT: case BOOL: return com.kenai.jffi.Type.SINT32; case UINT: return com.kenai.jffi.Type.UINT32; case LONGLONG: return com.kenai.jffi.Type.SINT64; case ULONGLONG: return com.kenai.jffi.Type.UINT64; case LONG: return com.kenai.jffi.Type.SLONG; case ULONG: return com.kenai.jffi.Type.ULONG; case FLOAT: return com.kenai.jffi.Type.FLOAT; case DOUBLE: return com.kenai.jffi.Type.DOUBLE; case POINTER: case STRING: return com.kenai.jffi.Type.POINTER; default: throw new RuntimeException("Unknown type " + type); } }
// in src/org/python/core/SyspathJavaLoader.java
Override protected URL findResource(String res) { PySystemState sys = Py.getSystemState(); if (res.charAt(0) == SLASH_CHAR) { res = res.substring(1); } String entryRes = res; if (File.separatorChar != SLASH_CHAR) { res = res.replace(SLASH_CHAR, File.separatorChar); entryRes = entryRes.replace(File.separatorChar, SLASH_CHAR); } PyList path = sys.path; for (int i = 0; i < path.__len__(); i++) { PyObject entry = replacePathItem(sys, i, path); if (entry instanceof SyspathArchive) { SyspathArchive archive = (SyspathArchive) entry; ZipEntry ze = archive.getEntry(entryRes); if (ze != null) { try { return new URL("jar:file:" + entry.__str__().toString() + "!/" + entryRes); } catch (MalformedURLException e) { throw new RuntimeException(e); } } continue; } if (!(entry instanceof PyUnicode)) { entry = entry.__str__(); } String dir = sys.getPath(entry.toString()); try { File resource = new File(dir, res); if (!resource.exists()) { continue; } return resource.toURI().toURL(); } catch (MalformedURLException e) { throw new RuntimeException(e); } } return null; }
// in src/org/python/core/PySystemState.java
private static void initStaticFields() { Py.None = new PyNone(); Py.NotImplemented = new PyNotImplemented(); Py.NoKeywords = new String[0]; Py.EmptyObjects = new PyObject[0]; Py.EmptyTuple = new PyTuple(Py.EmptyObjects); Py.EmptyFrozenSet = new PyFrozenSet(); Py.NoConversion = new PySingleton("Error"); Py.Ellipsis = new PyEllipsis(); Py.Zero = new PyInteger(0); Py.One = new PyInteger(1); Py.False = new PyBoolean(false); Py.True = new PyBoolean(true); Py.EmptyString = new PyString(""); Py.Newline = new PyString("\n"); Py.Space = new PyString(" "); // Setup standard wrappers for stdout and stderr... Py.stderr = new StderrWrapper(); Py.stdout = new StdoutWrapper(); String s; if(Version.PY_RELEASE_LEVEL == 0x0A) s = "alpha"; else if(Version.PY_RELEASE_LEVEL == 0x0B) s = "beta"; else if(Version.PY_RELEASE_LEVEL == 0x0C) s = "candidate"; else if(Version.PY_RELEASE_LEVEL == 0x0F) s = "final"; else if(Version.PY_RELEASE_LEVEL == 0xAA) s = "snapshot"; else throw new RuntimeException("Illegal value for PY_RELEASE_LEVEL: " + Version.PY_RELEASE_LEVEL); version_info = new PyTuple(Py.newInteger(Version.PY_MAJOR_VERSION), Py.newInteger(Version.PY_MINOR_VERSION), Py.newInteger(Version.PY_MICRO_VERSION), Py.newString(s), Py.newInteger(Version.PY_RELEASE_SERIAL)); subversion = new PyTuple(Py.newString("Jython"), Py.newString(Version.BRANCH), Py.newString(Version.SVN_REVISION)); _mercurial = new PyTuple(Py.newString("Jython"), Py.newString(Version.getHGIdentifier()), Py.newString(Version.getHGVersion())); }
// in src/org/python/core/PyType.java
private static TypeBuilder getBuilder(Class<?> c) { if (classToBuilder == null) { // PyType itself has yet to be initialized. This should be a bootstrap type, so it'll // go through the builder process in a second return null; } if (c.isPrimitive() || !PyObject.class.isAssignableFrom(c)) { // If this isn't a PyObject, don't bother forcing it to be initialized to load its // builder return null; } // This is a PyObject, call forName to force static initialization on the class so if it has // a builder, it'll be filled in SecurityException exc = null; try { Class.forName(c.getName(), true, c.getClassLoader()); } catch (ClassNotFoundException e) { // Well, this is certainly surprising. throw new RuntimeException("Got ClassNotFound calling Class.forName on an already " + " found class.", e); } catch (ExceptionInInitializerError e) { throw Py.JavaError(e); } catch (SecurityException e) { exc = e; } TypeBuilder builder = classToBuilder.get(c); if (builder == null && exc != null) { Py.writeComment("type", "Unable to initialize " + c.getName() + ", a PyObject subclass, due to a " + "security exception, and no type builder could be found for it. If it's an " + "exposed type, it may not work properly. Security exception: " + exc.getMessage()); } return builder; }
// in src/org/python/core/PyBuiltinMethodSet.java
Override public PyBuiltinCallable bind(PyObject bindTo) { if (__self__ != Py.None) { return this; } PyBuiltinMethodSet bindable; try { bindable = (PyBuiltinMethodSet)clone(); } catch (CloneNotSupportedException e) { throw new RuntimeException("Didn't expect PyBuiltinMethodSet to throw " + "CloneNotSupported since it implements Cloneable", e); } bindable.__self__ = bindTo; return bindable; }
// in src/org/python/core/PyBuiltinMethod.java
Override public PyBuiltinCallable bind(PyObject bindTo) { if(self == null) { PyBuiltinMethod bindable; try { bindable = (PyBuiltinMethod)clone(); } catch(CloneNotSupportedException e) { throw new RuntimeException("Didn't expect PyBuiltinMethodto throw " + "CloneNotSupported since it implements Cloneable", e); } bindable.self = bindTo; return bindable; } return this; }
// in src/org/python/util/CodegenUtils.java
public static String ci(Class n) { if (n.isArray()) { n = n.getComponentType(); if (n.isPrimitive()) { if (n == Byte.TYPE) { return "[B"; } else if (n == Boolean.TYPE) { return "[Z"; } else if (n == Short.TYPE) { return "[S"; } else if (n == Character.TYPE) { return "[C"; } else if (n == Integer.TYPE) { return "[I"; } else if (n == Float.TYPE) { return "[F"; } else if (n == Double.TYPE) { return "[D"; } else if (n == Long.TYPE) { return "[J"; } else { throw new RuntimeException("Unrecognized type in compiler: " + n.getName()); } } else { return "[" + ci(n); } } else { if (n.isPrimitive()) { if (n == Byte.TYPE) { return "B"; } else if (n == Boolean.TYPE) { return "Z"; } else if (n == Short.TYPE) { return "S"; } else if (n == Character.TYPE) { return "C"; } else if (n == Integer.TYPE) { return "I"; } else if (n == Float.TYPE) { return "F"; } else if (n == Double.TYPE) { return "D"; } else if (n == Long.TYPE) { return "J"; } else if (n == Void.TYPE) { return "V"; } else { throw new RuntimeException("Unrecognized type in compiler: " + n.getName()); } } else { return "L" + p(n) + ";"; } } }
9
            
// in src/com/ziclix/python/sql/zxJDBC.java
catch (MissingResourceException e) { throw new RuntimeException("missing zxjdbc resource bundle"); }
// in src/com/ziclix/python/sql/JDBC30DataHandler.java
catch (ClassNotFoundException e) { throw new RuntimeException("JDBC3.0 required to use this DataHandler"); }
// in src/org/python/expose/generate/TypeExposer.java
catch(Exception e) { // If we're unable to create the generated class, the process is // definitely ill, but that shouldn't be the case most of the time // so make this a runtime exception throw new RuntimeException("Unable to create generated builder", e); }
// in src/org/python/core/SyspathJavaLoader.java
catch (MalformedURLException e) { throw new RuntimeException(e); }
// in src/org/python/core/SyspathJavaLoader.java
catch (MalformedURLException e) { throw new RuntimeException(e); }
// in src/org/python/core/PyType.java
catch (ClassNotFoundException e) { // Well, this is certainly surprising. throw new RuntimeException("Got ClassNotFound calling Class.forName on an already " + " found class.", e); }
// in src/org/python/core/PyBuiltinMethodSet.java
catch (CloneNotSupportedException e) { throw new RuntimeException("Didn't expect PyBuiltinMethodSet to throw " + "CloneNotSupported since it implements Cloneable", e); }
// in src/org/python/core/PyBuiltinMethod.java
catch(CloneNotSupportedException e) { throw new RuntimeException("Didn't expect PyBuiltinMethodto throw " + "CloneNotSupported since it implements Cloneable", e); }
// in src/org/python/util/JLineConsole.java
catch (IOException e) { throw new RuntimeException(e); }
0 4
            
// in src/org/python/indexer/demos/StyleApplier.java
catch (RuntimeException x) { System.err.println("Warning: " + x); }
// in src/org/python/core/BytecodeLoader.java
catch (RuntimeException re) { // Probably an invalid .class, fallback to the // specified name }
// in src/org/python/core/imp.java
catch (RuntimeException t) { removeModule(name); throw t; }
// in src/org/python/util/ReadlineConsole.java
catch(RuntimeException e) { // Silently ignore errors during load of the native library. // Will use a pure java fallback. }
1
            
// in src/org/python/core/imp.java
catch (RuntimeException t) { removeModule(name); throw t; }
0
unknown (Lib) SQLException 0 0 62
            
// in src/com/ziclix/python/sql/FilterDataHandler.java
public PyObject getRowId(Statement stmt) throws SQLException { return this.delegate.getRowId(stmt); }
// in src/com/ziclix/python/sql/FilterDataHandler.java
public void preExecute(Statement stmt) throws SQLException { this.delegate.preExecute(stmt); }
// in src/com/ziclix/python/sql/FilterDataHandler.java
public void postExecute(Statement stmt) throws SQLException { this.delegate.postExecute(stmt); }
// in src/com/ziclix/python/sql/FilterDataHandler.java
public void setJDBCObject(PreparedStatement stmt, int index, PyObject object) throws SQLException { this.delegate.setJDBCObject(stmt, index, object); }
// in src/com/ziclix/python/sql/FilterDataHandler.java
public void setJDBCObject(PreparedStatement stmt, int index, PyObject object, int type) throws SQLException { this.delegate.setJDBCObject(stmt, index, object, type); }
// in src/com/ziclix/python/sql/FilterDataHandler.java
public PyObject getPyObject(ResultSet set, int col, int type) throws SQLException { return this.delegate.getPyObject(set, col, type); }
// in src/com/ziclix/python/sql/handler/RowIdHandler.java
public PyObject getRowId(Statement stmt) throws SQLException { Class<?> c = stmt.getClass(); Object o = ROWIDS.get(c); if (o == null) { synchronized (ROWIDS) { try { o = c.getMethod(getRowIdMethodName(), (Class[])null); ROWIDS.put(c, o); } catch (Throwable t) { ROWIDS.put(c, CHECKED); } } } if (!(o == null || o == CHECKED)) { try { return Py.java2py(((Method) o).invoke(stmt, (Object[])null)); } catch (Throwable t) {} } return super.getRowId(stmt); }
// in src/com/ziclix/python/sql/handler/MySQLDataHandler.java
Override public void setJDBCObject(PreparedStatement stmt, int index, PyObject object, int type) throws SQLException { if (DataHandler.checkNull(stmt, index, object, type)) { return; } switch (type) { case Types.LONGVARCHAR: // XXX: Only works with ASCII data! byte[] bytes; if (object instanceof PyFile) { bytes = ((PyFile) object).read().toBytes(); } else { String varchar = (String) object.__tojava__(String.class); bytes = StringUtil.toBytes(varchar); } InputStream stream = new ByteArrayInputStream(bytes); stream = new BufferedInputStream(stream); stmt.setAsciiStream(index, stream, bytes.length); break; default : super.setJDBCObject(stmt, index, object, type); break; } }
// in src/com/ziclix/python/sql/handler/SQLServerDataHandler.java
public Procedure getProcedure(PyCursor cursor, PyObject name) throws SQLException { return new SQLServerProcedure(cursor, name); }
// in src/com/ziclix/python/sql/handler/SQLServerDataHandler.java
public PyObject getPyObject(ResultSet set, int col, int type) throws SQLException { PyObject obj = Py.None; switch (type) { case UNICODE_VARCHAR: obj = super.getPyObject(set, col, Types.VARCHAR); break; default : obj = super.getPyObject(set, col, type); } return (set.wasNull() || (obj == null)) ? Py.None : obj; }
// in src/com/ziclix/python/sql/handler/OracleDataHandler.java
Override public void setJDBCObject(PreparedStatement stmt, int index, PyObject object, int type) throws SQLException { if (DataHandler.checkNull(stmt, index, object, type)) { return; } switch (type) { case Types.DATE: // Oracle DATE is a timestamp with one second precision Timestamp timestamp = (Timestamp) object.__tojava__(Timestamp.class); if (timestamp != Py.NoConversion) { stmt.setTimestamp(index, timestamp); } else { super.setJDBCObject(stmt, index, object, type); } break; case Types.DECIMAL: // Oracle is annoying Object input = object.__tojava__(Double.class); if (input != Py.NoConversion) { stmt.setDouble(index, ((Double) input).doubleValue()); break; } super.setJDBCObject(stmt, index, object, type); break; case Types.NUMERIC: super.setJDBCObject(stmt, index, object, Types.DOUBLE); break; case OracleTypes.ROWID: stmt.setString(index, (String) object.__tojava__(String.class)); break; case OracleTypes.TIMESTAMPLTZ: case OracleTypes.TIMESTAMPTZ: // XXX: We should include time zone information, but cx_Oracle currently // doesn't either super.setJDBCObject(stmt, index, object, Types.TIMESTAMP); break; default : super.setJDBCObject(stmt, index, object, type); } }
// in src/com/ziclix/python/sql/handler/OracleDataHandler.java
Override public PyObject getPyObject(ResultSet set, int col, int type) throws SQLException { PyObject obj = Py.None; switch (type) { case Types.DATE: // Oracle DATE is a timestamp with one second precision obj = Py.newDatetime(set.getTimestamp(col)); break; case Types.NUMERIC: // Oracle NUMBER encompasses all numeric types String number = set.getString(col); if (number == null) { obj = Py.None; break; } int scale; int precision; // Oracle's DML returning ResultSet doesn't support getMetaData try { ResultSetMetaData metaData = set.getMetaData(); scale = metaData.getScale(col); precision = metaData.getPrecision(col); } catch (SQLException sqle) { scale = precision = 0; } if (scale == -127) { if (precision == 0) { // Unspecified precision. Normally an integer from a sequence but // possibly any kind of number obj = number.indexOf('.') == -1 ? PyInteger.TYPE.__call__(Py.newString(number)) : Py.newDecimal(number); } else { // Floating point binary precision obj = Py.newFloat(set.getBigDecimal(col).doubleValue()); } } else { // Decimal precision. A plain integer when without a scale. Maybe a // plain integer when NUMBER(0,0) (scale and precision unknown, // similar to NUMBER(0,-127) above) obj = scale == 0 && (precision != 0 || number.indexOf('.') == -1) ? PyInteger.TYPE.__call__(Py.newString(number)) : Py.newDecimal(number); } break; case Types.BLOB: BLOB blob = ((OracleResultSet) set).getBLOB(col); obj = blob == null ? Py.None : Py.java2py(read(blob.getBinaryStream())); break; case OracleTypes.TIMESTAMPLTZ: case OracleTypes.TIMESTAMPTZ: // XXX: We should include time zone information, but cx_Oracle currently // doesn't either obj = super.getPyObject(set, col, Types.TIMESTAMP); break; case OracleTypes.ROWID: ROWID rowid = ((OracleResultSet) set).getROWID(col); if (rowid != null) { obj = Py.java2py(rowid.stringValue()); } break; default : obj = super.getPyObject(set, col, type); } return set.wasNull() ? Py.None : obj; }
// in src/com/ziclix/python/sql/handler/OracleDataHandler.java
Override public void registerOut(CallableStatement statement, int index, int colType, int dataType, String dataTypeName) throws SQLException { if (dataType == Types.OTHER) { if ("REF CURSOR".equals(dataTypeName)) { statement.registerOutParameter(index, OracleTypes.CURSOR); return; } else if ("PL/SQL RECORD".equals(dataTypeName)) { statement.registerOutParameter(index, OracleTypes.CURSOR); return; } } super.registerOut(statement, index, colType, dataType, dataTypeName); }
// in src/com/ziclix/python/sql/handler/UpdateCountDataHandler.java
public void preExecute(Statement stmt) throws SQLException { super.preExecute(stmt); this.updateCount = -1; }
// in src/com/ziclix/python/sql/handler/UpdateCountDataHandler.java
public void postExecute(Statement stmt) throws SQLException { super.postExecute(stmt); this.updateCount = stmt.getUpdateCount(); }
// in src/com/ziclix/python/sql/handler/InformixDataHandler.java
Override public PyObject getRowId(Statement stmt) throws SQLException { if (stmt instanceof IfmxStatement) { return Py.newInteger(((IfmxStatement) stmt).getSerial()); } return super.getRowId(stmt); }
// in src/com/ziclix/python/sql/handler/InformixDataHandler.java
Override public void setJDBCObject(PreparedStatement stmt, int index, PyObject object, int type) throws SQLException { if (DataHandler.checkNull(stmt, index, object, type)) { return; } switch (type) { case Types.LONGVARCHAR: String varchar; // Ifx driver can't handle the setCharacterStream() method so use setObject() instead if (object instanceof PyFile) { varchar = ((PyFile) object).read().toString(); } else { varchar = (String) object.__tojava__(String.class); } stmt.setObject(index, varchar, type); break; case Types.OTHER: // this is most likely an Informix boolean stmt.setBoolean(index, object.__nonzero__()); break; default : super.setJDBCObject(stmt, index, object, type); } }
// in src/com/ziclix/python/sql/handler/InformixDataHandler.java
Override public void setJDBCObject(PreparedStatement stmt, int index, PyObject object) throws SQLException { // there is a bug in the Ifx driver when using setObject() with a String for a // prepared statement if (object instanceof PyString) { super.setJDBCObject(stmt, index, object, Types.VARCHAR); } else { super.setJDBCObject(stmt, index, object); } }
// in src/com/ziclix/python/sql/handler/PostgresqlDataHandler.java
Override public PyObject getPyObject(ResultSet set, int col, int type) throws SQLException { PyObject obj = Py.None; switch (type) { case Types.NUMERIC: case Types.DECIMAL: BigDecimal bd = set.getBigDecimal(col); obj = (bd == null) ? Py.None : Py.newDecimal(bd.toString()); break; case Types.OTHER: // it seems pg doesn't like to handle OTHER types as anything but strings // but we'll try first anyways just to see what happens try { obj = super.getPyObject(set, col, type); } catch (SQLException e) { obj = super.getPyObject(set, col, Types.VARCHAR); } break; default : obj = super.getPyObject(set, col, type); } return (set.wasNull() || (obj == null)) ? Py.None : obj; }
// in src/com/ziclix/python/sql/handler/PostgresqlDataHandler.java
Override public void setJDBCObject(PreparedStatement stmt, int index, PyObject object, int type) throws SQLException { if (DataHandler.checkNull(stmt, index, object, type)) { return; } switch (type) { case Types.LONGVARCHAR: String varchar; // Postgresql driver can't handle the setCharacterStream() method so use setObject() instead if (object instanceof PyFile) { varchar = ((PyFile) object).read().asString(); } else { varchar = (String) object.__tojava__(String.class); } stmt.setObject(index, varchar, type); break; default : super.setJDBCObject(stmt, index, object, type); } }
// in src/com/ziclix/python/sql/handler/PostgresqlDataHandler.java
Override public void setJDBCObject(PreparedStatement stmt, int index, PyObject object) throws SQLException { // PostgreSQL doesn't support BigIntegers without explicitely setting the // type. Object value = object.__tojava__(Object.class); if (value instanceof BigInteger) { super.setJDBCObject(stmt, index, object, Types.BIGINT); } else { super.setJDBCObject(stmt, index, object); } }
// in src/com/ziclix/python/sql/Fetch.java
public void close() throws SQLException { this.listeners.clear(); }
// in src/com/ziclix/python/sql/Fetch.java
protected PyObject createDescription(ResultSetMetaData meta) throws SQLException { PyObject metadata = new PyList(); for (int i = 1; i <= meta.getColumnCount(); i++) { PyObject[] a = new PyObject[7]; a[0] = Py.newUnicode(meta.getColumnLabel(i)); a[1] = Py.newInteger(meta.getColumnType(i)); a[2] = Py.newInteger(meta.getColumnDisplaySize(i)); a[3] = Py.None; switch (meta.getColumnType(i)) { case Types.BIGINT: case Types.BIT: case Types.DECIMAL: case Types.NUMERIC: case Types.DOUBLE: case Types.FLOAT: case Types.INTEGER: case Types.SMALLINT: case Types.TINYINT: a[4] = Py.newInteger(meta.getPrecision(i)); a[5] = Py.newInteger(meta.getScale(i)); break; default : a[4] = Py.None; a[5] = Py.None; break; } a[6] = Py.newInteger(meta.isNullable(i)); ((PyList) metadata).append(new PyTuple(a)); } return metadata; }
// in src/com/ziclix/python/sql/Fetch.java
protected PyObject createDescription(Procedure procedure) throws SQLException { PyObject metadata = new PyList(); for (int i = 0, len = procedure.columns.__len__(); i < len; i++) { PyObject column = procedure.columns.__getitem__(i); int colType = column.__getitem__(Procedure.COLUMN_TYPE).asInt(); switch (colType) { case DatabaseMetaData.procedureColumnReturn: PyObject[] a = new PyObject[7]; a[0] = column.__getitem__(Procedure.NAME); a[1] = column.__getitem__(Procedure.DATA_TYPE); a[2] = Py.newInteger(-1); a[3] = column.__getitem__(Procedure.LENGTH); switch (a[1].asInt()) { case Types.BIGINT: case Types.BIT: case Types.DECIMAL: case Types.DOUBLE: case Types.FLOAT: case Types.INTEGER: case Types.SMALLINT: a[4] = column.__getitem__(Procedure.PRECISION); a[5] = column.__getitem__(Procedure.SCALE); break; default : a[4] = Py.None; a[5] = Py.None; break; } int nullable = column.__getitem__(Procedure.NULLABLE).asInt(); a[6] = (nullable == DatabaseMetaData.procedureNullable) ? Py.One : Py.Zero; ((PyList) metadata).append(new PyTuple(a)); break; } } return metadata; }
// in src/com/ziclix/python/sql/Fetch.java
protected PyObject createResults(CallableStatement callableStatement, Procedure procedure, PyObject params) throws SQLException { PyList results = new PyList(); for (int i = 0, j = 0, len = procedure.columns.__len__(); i < len; i++) { PyObject obj = Py.None; PyObject column = procedure.columns.__getitem__(i); int colType = column.__getitem__(Procedure.COLUMN_TYPE).asInt(); int dataType = column.__getitem__(Procedure.DATA_TYPE).asInt(); switch (colType) { case DatabaseMetaData.procedureColumnIn: j++; break; case DatabaseMetaData.procedureColumnOut: case DatabaseMetaData.procedureColumnInOut: obj = datahandler.getPyObject(callableStatement, i + 1, dataType); params.__setitem__(j++, obj); break; case DatabaseMetaData.procedureColumnReturn: obj = datahandler.getPyObject(callableStatement, i + 1, dataType); // Oracle sends ResultSets as a return value Object rs = obj.__tojava__(ResultSet.class); if (rs == Py.NoConversion) { results.append(obj); } else { add((ResultSet) rs); } break; } } if (results.__len__() == 0) { return results; } PyList ret = new PyList(); ret.append(PyTuple.fromIterable(results)); return ret; }
// in src/com/ziclix/python/sql/Fetch.java
protected PyList createResults(ResultSet set, Set<Integer> skipCols, PyObject metaData) throws SQLException { PyList res = new PyList(); while (set.next()) { PyObject tuple = createResult(set, skipCols, metaData); res.append(tuple); } return res; }
// in src/com/ziclix/python/sql/Fetch.java
protected PyTuple createResult(ResultSet set, Set<Integer> skipCols, PyObject metaData) throws SQLException { int descriptionLength = metaData.__len__(); PyObject[] row = new PyObject[descriptionLength]; for (int i = 0; i < descriptionLength; i++) { if (skipCols != null && skipCols.contains(i + 1)) { row[i] = Py.None; } else { int type = ((PyInteger) metaData.__getitem__(i).__getitem__(1)).getValue(); row[i] = datahandler.getPyObject(set, i + 1, type); } } SQLWarning warning = set.getWarnings(); if (warning != null) { fireWarning(warning); } return new PyTuple(row); }
// in src/com/ziclix/python/sql/Fetch.java
Override public void close() throws SQLException { super.close(); this.rownumber = -1; this.results.clear(); }
// in src/com/ziclix/python/sql/Fetch.java
Override public void close() throws SQLException { super.close(); if (this.resultSet == null) { return; } this.rownumber = -1; try { this.resultSet.close(); } finally { this.resultSet = null; } }
// in src/com/ziclix/python/sql/DataHandler.java
public Procedure getProcedure(PyCursor cursor, PyObject name) throws SQLException { return new Procedure(cursor, name); }
// in src/com/ziclix/python/sql/DataHandler.java
public PyObject getRowId(Statement stmt) throws SQLException { return Py.None; }
// in src/com/ziclix/python/sql/DataHandler.java
public void preExecute(Statement stmt) throws SQLException { return; }
// in src/com/ziclix/python/sql/DataHandler.java
public void postExecute(Statement stmt) throws SQLException { return; }
// in src/com/ziclix/python/sql/DataHandler.java
public void setJDBCObject(PreparedStatement stmt, int index, PyObject object) throws SQLException { try { Object o = object.__tojava__(Object.class); if (o instanceof BigInteger) { //XXX: This is in here to specifically fix passing a PyLong into Postgresql. stmt.setObject(index, o, Types.BIGINT); } else { stmt.setObject(index, o); } } catch (Exception e) { SQLException cause = null, ex = new SQLException("error setting index [" + index + "]"); if (e instanceof SQLException) { cause = (SQLException) e; } else { cause = new SQLException(e.getMessage()); } ex.setNextException(cause); throw ex; } }
// in src/com/ziclix/python/sql/DataHandler.java
public void setJDBCObject(PreparedStatement stmt, int index, PyObject object, int type) throws SQLException { try { if (checkNull(stmt, index, object, type)) { return; } switch (type) { case Types.DATE: Date date = (Date) object.__tojava__(Date.class); stmt.setDate(index, date); break; case Types.TIME: Time time = (Time) object.__tojava__(Time.class); stmt.setTime(index, time); break; case Types.TIMESTAMP: Timestamp timestamp = (Timestamp) object.__tojava__(Timestamp.class); stmt.setTimestamp(index, timestamp); break; case Types.LONGVARCHAR: if (object instanceof PyFile) { object = ((PyFile) object).read(); } String varchar = (String) object.__tojava__(String.class); Reader reader = new BufferedReader(new StringReader(varchar)); stmt.setCharacterStream(index, reader, varchar.length()); break; case Types.BIT: stmt.setBoolean(index, object.__nonzero__()); break; default : if (object instanceof PyFile) { object = ((PyFile) object).read(); } stmt.setObject(index, object.__tojava__(Object.class), type); break; } } catch (Exception e) { SQLException cause = null, ex = new SQLException("error setting index [" + index + "], type [" + type + "]"); if (e instanceof SQLException) { cause = (SQLException) e; } else { cause = new SQLException(e.getMessage()); } ex.setNextException(cause); throw ex; } }
// in src/com/ziclix/python/sql/DataHandler.java
public PyObject getPyObject(ResultSet set, int col, int type) throws SQLException { PyObject obj = Py.None; switch (type) { case Types.CHAR: case Types.VARCHAR: case Java6Types.NCHAR: case Java6Types.NVARCHAR: String string = set.getString(col); obj = string == null ? Py.None : Py.newUnicode(string); break; case Types.LONGVARCHAR: case Java6Types.LONGNVARCHAR: Reader reader = set.getCharacterStream(col); obj = reader == null ? Py.None : Py.newUnicode(read(reader)); break; case Types.NUMERIC: case Types.DECIMAL: BigDecimal bd = set.getBigDecimal(col); obj = (bd == null) ? Py.None : Py.newFloat(bd.doubleValue()); break; case Types.BIT: case Types.BOOLEAN: obj = set.getBoolean(col) ? Py.True : Py.False; break; case Types.INTEGER: case Types.TINYINT: case Types.SMALLINT: obj = Py.newInteger(set.getInt(col)); break; case Types.BIGINT: obj = Py.newLong(set.getLong(col)); break; case Types.FLOAT: case Types.REAL: obj = Py.newFloat(set.getFloat(col)); break; case Types.DOUBLE: obj = Py.newFloat(set.getDouble(col)); break; case Types.TIME: obj = Py.newTime(set.getTime(col)); break; case Types.TIMESTAMP: obj = Py.newDatetime(set.getTimestamp(col)); break; case Types.DATE: Object date = set.getObject(col); // don't newDate mysql YEAR columns obj = date instanceof Date ? Py.newDate((Date)date) : Py.java2py(date); break; case Types.NULL: obj = Py.None; break; case Types.OTHER: case Types.JAVA_OBJECT: obj = Py.java2py(set.getObject(col)); break; case Types.BINARY: case Types.VARBINARY: case Types.LONGVARBINARY: obj = Py.java2py(set.getBytes(col)); break; case Types.BLOB: Blob blob = set.getBlob(col); obj = blob == null ? Py.None : Py.java2py(read(blob.getBinaryStream())); break; case Types.CLOB: case Java6Types.NCLOB: case Java6Types.SQLXML: Clob clob = set.getClob(col); obj = clob == null ? Py.None : Py.java2py(read(clob.getCharacterStream())); break; // TODO can we support these? case Types.ARRAY: throw createUnsupportedTypeSQLException("ARRAY", col); case Types.DATALINK: throw createUnsupportedTypeSQLException("DATALINK", col); case Types.DISTINCT: throw createUnsupportedTypeSQLException("DISTINCT", col); case Types.REF: throw createUnsupportedTypeSQLException("REF", col); case Java6Types.ROWID: throw createUnsupportedTypeSQLException("STRUCT", col); case Types.STRUCT: throw createUnsupportedTypeSQLException("STRUCT", col); default : throw createUnsupportedTypeSQLException(new Integer(type), col); } return set.wasNull() || obj == null ? Py.None : obj; }
// in src/com/ziclix/python/sql/DataHandler.java
public PyObject getPyObject(CallableStatement stmt, int col, int type) throws SQLException { PyObject obj = Py.None; switch (type) { case Types.CHAR: case Types.VARCHAR: case Types.LONGVARCHAR: String string = stmt.getString(col); obj = (string == null) ? Py.None : Py.newUnicode(string); break; case Types.NUMERIC: case Types.DECIMAL: BigDecimal bd = stmt.getBigDecimal(col); obj = (bd == null) ? Py.None : Py.newFloat(bd.doubleValue()); break; case Types.BIT: obj = stmt.getBoolean(col) ? Py.True : Py.False; break; case Types.INTEGER: case Types.TINYINT: case Types.SMALLINT: obj = Py.newInteger(stmt.getInt(col)); break; case Types.BIGINT: obj = Py.newLong(stmt.getLong(col)); break; case Types.FLOAT: case Types.REAL: obj = Py.newFloat(stmt.getFloat(col)); break; case Types.DOUBLE: obj = Py.newFloat(stmt.getDouble(col)); break; case Types.TIME: obj = Py.newTime(stmt.getTime(col)); break; case Types.TIMESTAMP: obj = Py.newDatetime(stmt.getTimestamp(col)); break; case Types.DATE: obj = Py.newDate(stmt.getDate(col)); break; case Types.NULL: obj = Py.None; break; case Types.OTHER: obj = Py.java2py(stmt.getObject(col)); break; case Types.BINARY: case Types.VARBINARY: case Types.LONGVARBINARY: obj = Py.java2py(stmt.getBytes(col)); break; default : createUnsupportedTypeSQLException(type, col); } return stmt.wasNull() || obj == null ? Py.None : obj; }
// in src/com/ziclix/python/sql/DataHandler.java
public void registerOut(CallableStatement statement, int index, int colType, int dataType, String dataTypeName) throws SQLException { try { statement.registerOutParameter(index, dataType); } catch (Throwable t) { SQLException cause = null; SQLException ex = new SQLException("error setting index [" + index + "], coltype [" + colType + "], datatype [" + dataType + "], datatypename [" + dataTypeName + "]"); if (t instanceof SQLException) { cause = (SQLException)t; } else { cause = new SQLException(t.getMessage()); } ex.setNextException(cause); throw ex; } }
// in src/com/ziclix/python/sql/DataHandler.java
public static final boolean checkNull(PreparedStatement stmt, int index, PyObject object, int type) throws SQLException { if ((object == null) || (Py.None == object)) { stmt.setNull(index, type); return true; } return false; }
// in src/com/ziclix/python/sql/Jython22DataHandler.java
Override public Procedure getProcedure(PyCursor cursor, PyObject name) throws SQLException { return new Procedure(cursor, name); }
// in src/com/ziclix/python/sql/Jython22DataHandler.java
Override public PyObject getRowId(Statement stmt) throws SQLException { return Py.None; }
// in src/com/ziclix/python/sql/Jython22DataHandler.java
Override public void preExecute(Statement stmt) throws SQLException { return; }
// in src/com/ziclix/python/sql/Jython22DataHandler.java
Override public void postExecute(Statement stmt) throws SQLException { return; }
// in src/com/ziclix/python/sql/Jython22DataHandler.java
Override public void setJDBCObject(PreparedStatement stmt, int index, PyObject object) throws SQLException { try { stmt.setObject(index, object.__tojava__(Object.class)); } catch (Exception e) { SQLException cause = null, ex = new SQLException("error setting index [" + index + "]"); if (e instanceof SQLException) { cause = (SQLException) e; } else { cause = new SQLException(e.getMessage()); } ex.setNextException(cause); throw ex; } }
// in src/com/ziclix/python/sql/Jython22DataHandler.java
Override public void setJDBCObject(PreparedStatement stmt, int index, PyObject object, int type) throws SQLException { try { if (checkNull(stmt, index, object, type)) { return; } switch (type) { case Types.DATE: Date date = (Date) object.__tojava__(Date.class); stmt.setDate(index, date); break; case Types.TIME: Time time = (Time) object.__tojava__(Time.class); stmt.setTime(index, time); break; case Types.TIMESTAMP: Timestamp timestamp = (Timestamp) object.__tojava__(Timestamp.class); stmt.setTimestamp(index, timestamp); break; case Types.LONGVARCHAR: if (object instanceof PyFile) { object = ((PyFile) object).read(); } String varchar = (String) object.__tojava__(String.class); Reader reader = new BufferedReader(new StringReader(varchar)); stmt.setCharacterStream(index, reader, varchar.length()); break; case Types.BIT: stmt.setBoolean(index, object.__nonzero__()); break; default : if (object instanceof PyFile) { object = ((PyFile) object).read(); } stmt.setObject(index, object.__tojava__(Object.class), type); break; } } catch (Exception e) { SQLException cause = null, ex = new SQLException("error setting index [" + index + "], type [" + type + "]"); if (e instanceof SQLException) { cause = (SQLException) e; } else { cause = new SQLException(e.getMessage()); } ex.setNextException(cause); throw ex; } }
// in src/com/ziclix/python/sql/Jython22DataHandler.java
Override public void registerOut(CallableStatement statement, int index, int colType, int dataType, String dataTypeName) throws SQLException { try { statement.registerOutParameter(index, dataType); } catch (Throwable t) { SQLException cause = null; SQLException ex = new SQLException("error setting index [" + index + "], coltype [" + colType + "], datatype [" + dataType + "], datatypename [" + dataTypeName + "]"); if (t instanceof SQLException) { cause = (SQLException)t; } else { cause = new SQLException(t.getMessage()); } ex.setNextException(cause); throw ex; } }
// in src/com/ziclix/python/sql/JDBC30DataHandler.java
public void setJDBCObject(PreparedStatement stmt, int index, PyObject object) throws SQLException { ParameterMetaData meta = stmt.getParameterMetaData(); super.setJDBCObject(stmt, index, object, meta.getParameterType(index)); }
// in src/com/ziclix/python/sql/PyStatement.java
public void execute(PyCursor cursor, PyObject params, PyObject bindings) throws SQLException { if (closed) { throw zxJDBC.makeException(zxJDBC.ProgrammingError, "statement is closed"); } prepare(cursor, params, bindings); Fetch fetch = cursor.fetch; switch (style) { case STATEMENT_STATIC: if (statement.execute((String) sql)) { fetch.add(statement.getResultSet()); } break; case STATEMENT_PREPARED: final PreparedStatement preparedStatement = (PreparedStatement) statement; if (preparedStatement.execute()) { fetch.add(preparedStatement.getResultSet()); } break; case STATEMENT_CALLABLE: final CallableStatement callableStatement = (CallableStatement) statement; if (callableStatement.execute()) { fetch.add(callableStatement.getResultSet()); } fetch.add(callableStatement, (Procedure) sql, params); break; default: throw zxJDBC.makeException(zxJDBC.ProgrammingError, zxJDBC.getString("invalidStyle")); } }
// in src/com/ziclix/python/sql/PyStatement.java
private void prepare(PyCursor cursor, PyObject params, PyObject bindings) throws SQLException { if (params == Py.None || style == STATEMENT_STATIC) { return; } // [3, 4] or (3, 4) final DataHandler datahandler = cursor.datahandler; int columns = 0, column = 0, index = params.__len__(); final PreparedStatement preparedStatement = (PreparedStatement) statement; final Procedure procedure = style == STATEMENT_CALLABLE ? (Procedure) sql : null; if (style != STATEMENT_CALLABLE) { columns = params.__len__(); // clear the statement so all new bindings take affect only if not a callproc // this is because Procedure already registered the OUT parameters and we // don't want to lose those preparedStatement.clearParameters(); } else { columns = procedure.columns == Py.None ? 0 : procedure.columns.__len__(); } // count backwards through all the columns while (columns-- > 0) { column = columns + 1; if (procedure != null && !procedure.isInput(column)) { continue; } // working from right to left PyObject param = params.__getitem__(--index); if (bindings != Py.None) { PyObject binding = bindings.__finditem__(Py.newInteger(index)); if (binding != null) { try { int bindingValue = binding.asInt(); datahandler.setJDBCObject(preparedStatement, column, param, bindingValue); } catch (PyException e) { throw zxJDBC.makeException(zxJDBC.ProgrammingError, zxJDBC.getString("bindingValue")); } continue; } } datahandler.setJDBCObject(preparedStatement, column, param); } }
// in src/com/ziclix/python/sql/JDBC20DataHandler.java
Override public PyObject getPyObject(ResultSet set, int col, int type) throws SQLException { PyObject obj = Py.None; switch (type) { case Types.NUMERIC: case Types.DECIMAL: // in JDBC 2.0, use of a scale is deprecated try { BigDecimal bd = set.getBigDecimal(col); obj = (bd == null) ? Py.None : Py.newFloat(bd.doubleValue()); } catch (SQLException e) { obj = super.getPyObject(set, col, type); } break; case Types.CLOB: Reader reader = set.getCharacterStream(col); obj = reader == null ? Py.None : Py.newUnicode(read(reader)); break; case Types.BLOB: Blob blob = set.getBlob(col); obj = blob == null ? Py.None : Py.java2py(read(blob.getBinaryStream())); break; case Types.ARRAY: Array array = set.getArray(col); obj = array == null ? Py.None : Py.java2py(array.getArray()); break; default : return super.getPyObject(set, col, type); } return (set.wasNull() || (obj == null)) ? Py.None : obj; }
// in src/com/ziclix/python/sql/Procedure.java
public CallableStatement prepareCall() throws SQLException { return prepareCall(Py.None, Py.None); }
// in src/com/ziclix/python/sql/Procedure.java
public CallableStatement prepareCall(PyObject rsType, PyObject rsConcur) throws SQLException { // prepare the statement CallableStatement statement = null; boolean normal = ((rsType == Py.None) && (rsConcur == Py.None)); try { // build the full call syntax String sqlString = toSql(); if (normal) { statement = cursor.connection.connection.prepareCall(sqlString); } else { int t = rsType.asInt(); int c = rsConcur.asInt(); statement = cursor.connection.connection.prepareCall(sqlString, t, c); } // prepare the OUT parameters registerOutParameters(statement); } catch (SQLException e) { if (statement != null) { try { statement.close(); } catch (Exception ex) { } } throw e; } return statement; }
// in src/com/ziclix/python/sql/Procedure.java
public void normalizeInput(PyObject params, PyObject bindings) throws SQLException { if (this.columns == Py.None) { return; } // do nothing with params at the moment for (int i = 0, len = this.columns.__len__(), binding = 0; i < len; i++) { PyObject column = this.columns.__getitem__(i); int colType = column.__getitem__(COLUMN_TYPE).asInt(); switch (colType) { case DatabaseMetaData.procedureColumnIn: case DatabaseMetaData.procedureColumnInOut: // bindings are Python-indexed PyInteger key = Py.newInteger(binding++); if (bindings.__finditem__(key) == null) { int dataType = column.__getitem__(DATA_TYPE).asInt(); bindings.__setitem__(key, Py.newInteger(dataType)); } // inputs are JDBC-indexed this.inputSet.set(i + 1); break; } } }
// in src/com/ziclix/python/sql/Procedure.java
public boolean isInput(int index) throws SQLException { return this.inputSet.get(index); }
// in src/com/ziclix/python/sql/Procedure.java
public String toSql() throws SQLException { int colParam = 0; int colReturn = 0; if (this.columns != Py.None) { for (int i = 0, len = this.columns.__len__(); i < len; i++) { PyObject column = this.columns.__getitem__(i); int colType = column.__getitem__(COLUMN_TYPE).asInt(); switch (colType) { case DatabaseMetaData.procedureColumnUnknown: throw zxJDBC.makeException(zxJDBC.NotSupportedError, "procedureColumnUnknown"); case DatabaseMetaData.procedureColumnResult: throw zxJDBC.makeException(zxJDBC.NotSupportedError, "procedureColumnResult"); // these go on the right hand side case DatabaseMetaData.procedureColumnIn: case DatabaseMetaData.procedureColumnInOut: case DatabaseMetaData.procedureColumnOut: colParam++; break; // these go on the left hand side case DatabaseMetaData.procedureColumnReturn: colReturn++; break; default : throw zxJDBC.makeException(zxJDBC.DataError, "unknown column type [" + colType + "]"); } } } StringBuffer sql = new StringBuffer("{"); if (colReturn > 0) { PyList list = new PyList(); for (; colReturn > 0; colReturn--) { list.append(Py.newString("?")); } sql.append(Py.newString(",").join(list)).append(" = "); } String name = this.getProcedureName(); sql.append("call ").append(name).append("("); if (colParam > 0) { PyList list = new PyList(); for (; colParam > 0; colParam--) { list.append(Py.newString("?")); } sql.append(Py.newString(",").join(list)); } return sql.append(")}").toString(); }
// in src/com/ziclix/python/sql/Procedure.java
protected void registerOutParameters(CallableStatement statement) throws SQLException { if (this.columns == Py.None) { return; } for (int i = 0, len = this.columns.__len__(); i < len; i++) { PyObject column = this.columns.__getitem__(i); int colType = column.__getitem__(COLUMN_TYPE).asInt(); int dataType = column.__getitem__(DATA_TYPE).asInt(); String dataTypeName = column.__getitem__(DATA_TYPE_NAME).toString(); switch (colType) { case DatabaseMetaData.procedureColumnInOut: case DatabaseMetaData.procedureColumnOut: case DatabaseMetaData.procedureColumnReturn: cursor.datahandler.registerOut(statement, i + 1, colType, dataType, dataTypeName); break; } } }
// in src/com/ziclix/python/sql/Procedure.java
protected void fetchColumns() throws SQLException { PyExtendedCursor pec = (PyExtendedCursor) cursor.connection.cursor(); try { pec.datahandler = this.cursor.datahandler; pec.procedurecolumns(procedureCatalog, procedureSchema, procedureName, Py.None); this.columns = pec.fetchall(); } finally { pec.close(); } }
// in src/com/ziclix/python/sql/PyCursor.java
protected DatabaseMetaData getMetaData() throws SQLException { return this.connection.connection.getMetaData(); }
// in src/com/ziclix/python/sql/PyCursor.java
private void updateAttributes(int updateCount) throws SQLException { lastrowid = datahandler.getRowId(statement.statement); updatecount = updateCount < 0 ? Py.None : Py.newInteger(updateCount); }
39
            
// in src/com/ziclix/python/sql/handler/OracleDataHandler.java
catch (SQLException sqle) { scale = precision = 0; }
// in src/com/ziclix/python/sql/handler/InformixDataHandler.java
catch (SQLException e) { obj = super.getPyObject(set, col, type); }
// in src/com/ziclix/python/sql/handler/PostgresqlDataHandler.java
catch (SQLException e) { obj = super.getPyObject(set, col, Types.VARCHAR); }
// in src/com/ziclix/python/sql/Fetch.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyConnection.java
catch (SQLException e) { return String.format("<PyConnection object at %s", Py.idstr(this)); }
// in src/com/ziclix/python/sql/PyConnection.java
catch (SQLException e) { throw zxJDBC.makeException(zxJDBC.DatabaseError, e); }
// in src/com/ziclix/python/sql/PyConnection.java
catch (SQLException e) { throw zxJDBC.makeException(zxJDBC.DatabaseError, e); }
// in src/com/ziclix/python/sql/PyConnection.java
catch (SQLException e) { throw zxJDBC.makeException(zxJDBC.DatabaseError, e); }
// in src/com/ziclix/python/sql/PyConnection.java
catch (SQLException e) { throw zxJDBC.makeException(zxJDBC.DatabaseError, e); }
// in src/com/ziclix/python/sql/PyConnection.java
catch (SQLException e) { throw zxJDBC.makeException(zxJDBC.DatabaseError, e); }
// in src/com/ziclix/python/sql/PyConnection.java
catch (SQLException e) { throw zxJDBC.makeException(zxJDBC.DatabaseError, e); }
// in src/com/ziclix/python/sql/PyConnection.java
catch (SQLException e) { throw zxJDBC.makeException(zxJDBC.DatabaseError, e); }
// in src/com/ziclix/python/sql/PyConnection.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyConnection.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyConnection.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyConnection.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyExtendedCursor.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyExtendedCursor.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyExtendedCursor.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyExtendedCursor.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyExtendedCursor.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyExtendedCursor.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyExtendedCursor.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyExtendedCursor.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyExtendedCursor.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyExtendedCursor.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyExtendedCursor.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyExtendedCursor.java
catch (SQLException e) { }
// in src/com/ziclix/python/sql/connect/Connectx.java
catch (SQLException e) { throw zxJDBC.makeException(zxJDBC.DatabaseError, e); }
// in src/com/ziclix/python/sql/connect/Connectx.java
catch (SQLException e) { throw zxJDBC.makeException(zxJDBC.DatabaseError, e); }
// in src/com/ziclix/python/sql/connect/Connect.java
catch (SQLException e) { throw zxJDBC.makeException(zxJDBC.DatabaseError, e); }
// in src/com/ziclix/python/sql/connect/Connect.java
catch (SQLException e) { throw zxJDBC.makeException(zxJDBC.DatabaseError, e); }
// in src/com/ziclix/python/sql/connect/Lookup.java
catch (SQLException e) { throw zxJDBC.makeException(zxJDBC.DatabaseError, e); }
// in src/com/ziclix/python/sql/connect/Lookup.java
catch (SQLException e) { throw zxJDBC.makeException(zxJDBC.DatabaseError, e); }
// in src/com/ziclix/python/sql/PyStatement.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyStatement.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/JDBC20DataHandler.java
catch (SQLException e) { obj = super.getPyObject(set, col, type); }
// in src/com/ziclix/python/sql/Procedure.java
catch (SQLException e) { if (statement != null) { try { statement.close(); } catch (Exception ex) { } } throw e; }
// in src/com/ziclix/python/sql/PyCursor.java
catch (SQLException sqle) { throw zxJDBC.makeException(sqle); }
33
            
// in src/com/ziclix/python/sql/Fetch.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyConnection.java
catch (SQLException e) { throw zxJDBC.makeException(zxJDBC.DatabaseError, e); }
// in src/com/ziclix/python/sql/PyConnection.java
catch (SQLException e) { throw zxJDBC.makeException(zxJDBC.DatabaseError, e); }
// in src/com/ziclix/python/sql/PyConnection.java
catch (SQLException e) { throw zxJDBC.makeException(zxJDBC.DatabaseError, e); }
// in src/com/ziclix/python/sql/PyConnection.java
catch (SQLException e) { throw zxJDBC.makeException(zxJDBC.DatabaseError, e); }
// in src/com/ziclix/python/sql/PyConnection.java
catch (SQLException e) { throw zxJDBC.makeException(zxJDBC.DatabaseError, e); }
// in src/com/ziclix/python/sql/PyConnection.java
catch (SQLException e) { throw zxJDBC.makeException(zxJDBC.DatabaseError, e); }
// in src/com/ziclix/python/sql/PyConnection.java
catch (SQLException e) { throw zxJDBC.makeException(zxJDBC.DatabaseError, e); }
// in src/com/ziclix/python/sql/PyConnection.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyConnection.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyConnection.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyConnection.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyExtendedCursor.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyExtendedCursor.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyExtendedCursor.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyExtendedCursor.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyExtendedCursor.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyExtendedCursor.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyExtendedCursor.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyExtendedCursor.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyExtendedCursor.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyExtendedCursor.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyExtendedCursor.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/connect/Connectx.java
catch (SQLException e) { throw zxJDBC.makeException(zxJDBC.DatabaseError, e); }
// in src/com/ziclix/python/sql/connect/Connectx.java
catch (SQLException e) { throw zxJDBC.makeException(zxJDBC.DatabaseError, e); }
// in src/com/ziclix/python/sql/connect/Connect.java
catch (SQLException e) { throw zxJDBC.makeException(zxJDBC.DatabaseError, e); }
// in src/com/ziclix/python/sql/connect/Connect.java
catch (SQLException e) { throw zxJDBC.makeException(zxJDBC.DatabaseError, e); }
// in src/com/ziclix/python/sql/connect/Lookup.java
catch (SQLException e) { throw zxJDBC.makeException(zxJDBC.DatabaseError, e); }
// in src/com/ziclix/python/sql/connect/Lookup.java
catch (SQLException e) { throw zxJDBC.makeException(zxJDBC.DatabaseError, e); }
// in src/com/ziclix/python/sql/PyStatement.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyStatement.java
catch (SQLException e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/Procedure.java
catch (SQLException e) { if (statement != null) { try { statement.close(); } catch (Exception ex) { } } throw e; }
// in src/com/ziclix/python/sql/PyCursor.java
catch (SQLException sqle) { throw zxJDBC.makeException(sqle); }
0
unknown (Lib) SecurityException 0 0 2
            
// in src/org/python/core/CodeLoader.java
public static PyCode loadCode(Class<?> cls, String name, String filename) throws SecurityException, NoSuchMethodException, IllegalArgumentException, IllegalAccessException, InvocationTargetException { Method getBootstrap = cls.getMethod(GET_BOOTSTRAP_METHOD_NAME); CodeBootstrap bootstrap = (CodeBootstrap) getBootstrap.invoke(null); return loadCode(bootstrap, name, filename); }
// in src/org/python/core/CodeLoader.java
public static PyCode loadCode(Class<?> cls) throws SecurityException, IllegalArgumentException, NoSuchMethodException, IllegalAccessException, InvocationTargetException { return loadCode(cls, null, null); }
20
            
// in src/org/python/compiler/ProxyMaker.java
catch (SecurityException e) { return; }
// in src/org/python/modules/zipimport/zipimporter.java
catch (SecurityException se) { // continue }
// in src/org/python/modules/posix/PosixModule.java
catch (SecurityException se) { return environ; }
// in src/org/python/core/SyspathJavaLoader.java
catch(SecurityException e) { return null; }
// in src/org/python/core/PySystemState.java
catch (SecurityException e) { }
// in src/org/python/core/PySystemState.java
catch (SecurityException se) { // ignore, can't do anything about it }
// in src/org/python/core/PySystemState.java
catch (SecurityException e) { // Must be running in a security environment that doesn't allow access to the class // loader }
// in src/org/python/core/PySystemState.java
catch (SecurityException se) { Py.writeDebug("PySystemState", "Can't register cleanup closer hook"); return null; }
// in src/org/python/core/BytecodeLoader.java
catch (SecurityException e) { }
// in src/org/python/core/PyReflectedFunction.java
catch (SecurityException se) { // This case is pretty far in the corner, so don't scream if we can't set the method // accessible due to a security manager. Any calls to it will fail with an // IllegalAccessException, so it'll become visible there. This way we don't spam // people who aren't calling methods like this from Python with warnings if a // library they're using happens to have a method like this. }
// in src/org/python/core/PyTraceback.java
catch (SecurityException e) { return null; // If we don't have read access to the file, return null }
// in src/org/python/core/PyType.java
catch (SecurityException e) { exc = e; }
// in src/org/python/core/Py.java
catch (SecurityException e) { syspathJavaLoaderRestricted = true; }
// in src/org/python/core/imp.java
catch (SecurityException e) { return false; }
// in src/org/python/core/imp.java
catch(SecurityException exc) { // If we can't write the cache file, just log and continue Py.writeDebug(IMPORT_LOG, "Unable to write to source cache file '" + compiledFilename + "' due to " + exc); return null; }
// in src/org/python/core/imp.java
catch (SecurityException e) { // ok }
// in src/org/python/core/imp.java
catch (SecurityException e) { // ok }
// in src/org/python/core/packagecache/PathPackageManager.java
catch (SecurityException se) { return false; }
// in src/org/python/util/JLineConsole.java
catch (SecurityException se) { // continue }
// in src/org/python/util/jython.java
catch (SecurityException e) { // continue }
0 0
unknown (Lib) ServletException 12
            
// in src/com/xhaus/modjy/ModjyJServlet.java
Override public void init() throws ServletException { try { Properties props = readConfiguration(); PythonInterpreter.initialize(System.getProperties(), props, new String[0]); PySystemState systemState = new PySystemState(); interp = new PythonInterpreter(null, systemState); setupEnvironment(interp, props, systemState); try { interp.exec("from modjy.modjy import " + MODJY_PYTHON_CLASSNAME); } catch (PyException ix) { throw new ServletException("Unable to import '" + MODJY_PYTHON_CLASSNAME + "': maybe you need to set the '" + PYTHON_HOME_PARAM + "' parameter?", ix); } PyObject pyServlet = ((PyType)interp.get(MODJY_PYTHON_CLASSNAME)).__call__(); Object temp = pyServlet.__tojava__(HttpServlet.class); if (temp == Py.NoConversion) throw new ServletException("Corrupted modjy file: cannot find definition of '" + MODJY_PYTHON_CLASSNAME + "' class"); modjyServlet = (HttpServlet)temp; modjyServlet.init(this); } catch (PyException pyx) { throw new ServletException("Exception creating modjy servlet: " + pyx.toString(), pyx); } }
// in src/org/python/util/PyFilter.java
public void init(FilterConfig config) throws ServletException { if (config.getServletContext().getAttribute(PyServlet.INIT_ATTR) == null) { throw new ServletException("Jython has not been initialized. Add " + "org.python.util.PyServletInitializer as a listener to your " + "web.xml."); } this.config = config; String filterPath = config.getInitParameter(FILTER_PATH_PARAM); if (filterPath == null) { throw new ServletException("Missing required param '" + FILTER_PATH_PARAM + "'"); } source = new File(getRealPath(config.getServletContext(), filterPath)); if (!source.exists()) { throw new ServletException(source.getAbsolutePath() + " does not exist."); } interp = PyServlet.createInterpreter(config.getServletContext()); }
// in src/org/python/util/PyFilter.java
private Filter loadFilter() throws ServletException, IOException { loadedMtime = source.lastModified(); cached = PyServlet.createInstance(interp, source, Filter.class); try { cached.init(config); } catch (PyException e) { throw new ServletException(e); } return cached; }
// in src/org/python/util/PyServlet.java
private HttpServlet loadServlet(String path) throws ServletException, IOException { File file = new File(path); HttpServlet servlet = createInstance(interp, file, HttpServlet.class); try { servlet.init(getServletConfig()); } catch (PyException e) { throw new ServletException(e); } cache.put(path, new CacheEntry(servlet, file.lastModified())); return servlet; }
// in src/org/python/util/PyServlet.java
protected static <T> T createInstance(PythonInterpreter interp, File file, Class<T> type) throws ServletException { Matcher m = FIND_NAME.matcher(file.getName()); if (!m.find()) { throw new ServletException("I can't guess the name of the class from " + file.getAbsolutePath()); } String name = m.group(1); try { interp.set("__file__", file.getAbsolutePath()); interp.execfile(file.getAbsolutePath()); PyObject cls = interp.get(name); if (cls == null) { throw new ServletException("No callable (class or function) named " + name + " in " + file.getAbsolutePath()); } PyObject pyServlet = cls.__call__(); Object o = pyServlet.__tojava__(type); if (o == Py.NoConversion) { throw new ServletException("The value from " + name + " must extend " + type.getSimpleName()); } @SuppressWarnings("unchecked") T asT = (T)o; return asT; } catch (PyException e) { throw new ServletException(e); } }
5
            
// in src/com/xhaus/modjy/ModjyJServlet.java
catch (PyException ix) { throw new ServletException("Unable to import '" + MODJY_PYTHON_CLASSNAME + "': maybe you need to set the '" + PYTHON_HOME_PARAM + "' parameter?", ix); }
// in src/com/xhaus/modjy/ModjyJServlet.java
catch (PyException pyx) { throw new ServletException("Exception creating modjy servlet: " + pyx.toString(), pyx); }
// in src/org/python/util/PyFilter.java
catch (PyException e) { throw new ServletException(e); }
// in src/org/python/util/PyServlet.java
catch (PyException e) { throw new ServletException(e); }
// in src/org/python/util/PyServlet.java
catch (PyException e) { throw new ServletException(e); }
10
            
// in src/com/xhaus/modjy/ModjyJServlet.java
Override public void init() throws ServletException { try { Properties props = readConfiguration(); PythonInterpreter.initialize(System.getProperties(), props, new String[0]); PySystemState systemState = new PySystemState(); interp = new PythonInterpreter(null, systemState); setupEnvironment(interp, props, systemState); try { interp.exec("from modjy.modjy import " + MODJY_PYTHON_CLASSNAME); } catch (PyException ix) { throw new ServletException("Unable to import '" + MODJY_PYTHON_CLASSNAME + "': maybe you need to set the '" + PYTHON_HOME_PARAM + "' parameter?", ix); } PyObject pyServlet = ((PyType)interp.get(MODJY_PYTHON_CLASSNAME)).__call__(); Object temp = pyServlet.__tojava__(HttpServlet.class); if (temp == Py.NoConversion) throw new ServletException("Corrupted modjy file: cannot find definition of '" + MODJY_PYTHON_CLASSNAME + "' class"); modjyServlet = (HttpServlet)temp; modjyServlet.init(this); } catch (PyException pyx) { throw new ServletException("Exception creating modjy servlet: " + pyx.toString(), pyx); } }
// in src/com/xhaus/modjy/ModjyJServlet.java
Override public void service(HttpServletRequest req, HttpServletResponse resp) throws ServletException, IOException { modjyServlet.service(req, resp); }
// in src/org/python/util/PyFilter.java
public void doFilter(ServletRequest request, ServletResponse response, FilterChain chain) throws IOException, ServletException { request.setAttribute("pyfilter", this); getFilter().doFilter(request, response, chain); }
// in src/org/python/util/PyFilter.java
public void init(FilterConfig config) throws ServletException { if (config.getServletContext().getAttribute(PyServlet.INIT_ATTR) == null) { throw new ServletException("Jython has not been initialized. Add " + "org.python.util.PyServletInitializer as a listener to your " + "web.xml."); } this.config = config; String filterPath = config.getInitParameter(FILTER_PATH_PARAM); if (filterPath == null) { throw new ServletException("Missing required param '" + FILTER_PATH_PARAM + "'"); } source = new File(getRealPath(config.getServletContext(), filterPath)); if (!source.exists()) { throw new ServletException(source.getAbsolutePath() + " does not exist."); } interp = PyServlet.createInterpreter(config.getServletContext()); }
// in src/org/python/util/PyFilter.java
private Filter getFilter() throws ServletException, IOException { if (cached == null || source.lastModified() > loadedMtime) { return loadFilter(); } return cached; }
// in src/org/python/util/PyFilter.java
private Filter loadFilter() throws ServletException, IOException { loadedMtime = source.lastModified(); cached = PyServlet.createInstance(interp, source, Filter.class); try { cached.init(config); } catch (PyException e) { throw new ServletException(e); } return cached; }
// in src/org/python/util/PyServlet.java
Override public void service(ServletRequest req, ServletResponse res) throws ServletException, IOException { req.setAttribute("pyservlet", this); String spath = (String) req.getAttribute("javax.servlet.include.servlet_path"); if (spath == null) { spath = ((HttpServletRequest)req).getServletPath(); if (spath == null || spath.length() == 0) { // Servlet 2.1 puts the path of an extension-matched servlet in PathInfo. spath = ((HttpServletRequest)req).getPathInfo(); } } String rpath = getServletContext().getRealPath(spath); getServlet(rpath).service(req, res); }
// in src/org/python/util/PyServlet.java
private synchronized HttpServlet getServlet(String path) throws ServletException, IOException { CacheEntry entry = cache.get(path); if (entry == null || new File(path).lastModified() > entry.date) { return loadServlet(path); } return entry.servlet; }
// in src/org/python/util/PyServlet.java
private HttpServlet loadServlet(String path) throws ServletException, IOException { File file = new File(path); HttpServlet servlet = createInstance(interp, file, HttpServlet.class); try { servlet.init(getServletConfig()); } catch (PyException e) { throw new ServletException(e); } cache.put(path, new CacheEntry(servlet, file.lastModified())); return servlet; }
// in src/org/python/util/PyServlet.java
protected static <T> T createInstance(PythonInterpreter interp, File file, Class<T> type) throws ServletException { Matcher m = FIND_NAME.matcher(file.getName()); if (!m.find()) { throw new ServletException("I can't guess the name of the class from " + file.getAbsolutePath()); } String name = m.group(1); try { interp.set("__file__", file.getAbsolutePath()); interp.execfile(file.getAbsolutePath()); PyObject cls = interp.get(name); if (cls == null) { throw new ServletException("No callable (class or function) named " + name + " in " + file.getAbsolutePath()); } PyObject pyServlet = cls.__call__(); Object o = pyServlet.__tojava__(type); if (o == Py.NoConversion) { throw new ServletException("The value from " + name + " must extend " + type.getSimpleName()); } @SuppressWarnings("unchecked") T asT = (T)o; return asT; } catch (PyException e) { throw new ServletException(e); } }
0 0 0
unknown (Lib) StackOverflowError 0 0 0 2
            
// in src/org/python/indexer/Indexer.java
catch (StackOverflowError soe) { handleException("Error loading " + path, soe); return null; }
// in src/org/python/indexer/ast/NNode.java
catch (StackOverflowError soe) { String msg = "Unable to resolve: " + n + " in " + n.getFile() + " (stack overflow)"; Indexer.idx.warn(msg); return handleExceptionInResolve(n, soe); }
0 0
runtime (Domain) StopIterationException
public static final class StopIterationException extends RuntimeException {
        public StopIterationException() {}
    }
1
            
// in src/org/python/indexer/ast/NNode.java
public boolean dispatch(NNode node) { // This node ends before the offset, so don't look inside it. if (offset > node.end) { return false; // don't traverse children, but do keep going } if (offset >= node.start && offset <= node.end) { deepest = node; return true; // visit kids } // this node starts after the offset, so we're done throw new NNodeVisitor.StopIterationException(); }
0 0 1
            
// in src/org/python/indexer/ast/NNode.java
catch (NNodeVisitor.StopIterationException six) { // expected }
0 0
unknown (Lib) StreamCorruptedException 1
            
// in src/org/python/core/Py.java
private Object readResolve() throws ObjectStreamException { if (which.equals("None")) { return Py.None; } else if (which.equals("Ellipsis")) { return Py.Ellipsis; } else if (which.equals("NotImplemented")) { return Py.NotImplemented; } throw new StreamCorruptedException("unknown singleton: " + which); }
0 0 0 0 0
unknown (Lib) StringIndexOutOfBoundsException 0 0 0 5
            
// in src/org/python/indexer/demos/Styler.java
catch (StringIndexOutOfBoundsException sx) { System.out.println("whoops: beg=" + a + ", end=" + b + ", len=" + source.length()); return ""; }
// in src/org/python/modules/_marshal.java
catch (StringIndexOutOfBoundsException e) { // convert from our PyIOFile abstraction to what marshal in CPython returns // (although it's really just looking for no bombing) throw Py.EOFError("EOF read where object expected"); }
// in src/org/python/core/PyString.java
catch (StringIndexOutOfBoundsException exc) { throw Py.ValueError("invalid literal for int() with base " + base + ": " + getString()); }
// in src/org/python/core/PyString.java
catch (StringIndexOutOfBoundsException exc) { throw Py.ValueError("invalid literal for long() with base " + base + ": " + getString()); }
// in src/org/python/core/PyString.java
catch (StringIndexOutOfBoundsException e) { throw Py.ValueError("incomplete format"); }
4
            
// in src/org/python/modules/_marshal.java
catch (StringIndexOutOfBoundsException e) { // convert from our PyIOFile abstraction to what marshal in CPython returns // (although it's really just looking for no bombing) throw Py.EOFError("EOF read where object expected"); }
// in src/org/python/core/PyString.java
catch (StringIndexOutOfBoundsException exc) { throw Py.ValueError("invalid literal for int() with base " + base + ": " + getString()); }
// in src/org/python/core/PyString.java
catch (StringIndexOutOfBoundsException exc) { throw Py.ValueError("invalid literal for long() with base " + base + ": " + getString()); }
// in src/org/python/core/PyString.java
catch (StringIndexOutOfBoundsException e) { throw Py.ValueError("incomplete format"); }
0
checked (Lib) Throwable 0 0 7
            
// in src/org/python/jsr223/PyScriptEngine.java
public <T> T getInterface(Object obj, Class<T> clazz) { if (obj == null) { throw new IllegalArgumentException("object expected"); } if (clazz == null || !clazz.isInterface()) { throw new IllegalArgumentException("interface expected"); } interp.setLocals(new PyScriptEngineScope(this, context)); final PyObject thiz = Py.java2py(obj); @SuppressWarnings("unchecked") T proxy = (T) Proxy.newProxyInstance( clazz.getClassLoader(), new Class[] { clazz }, new InvocationHandler() { public Object invoke(Object proxy, Method method, Object[] args) throws Throwable { try { interp.setLocals(new PyScriptEngineScope(PyScriptEngine.this, context)); PyObject pyMethod = thiz.__findattr__(method.getName()); if (pyMethod == null) throw new NoSuchMethodException(method.getName()); PyObject result = pyMethod.__call__(Py.javas2pys(args)); return result.__tojava__(Object.class); } catch (PyException pye) { throw scriptException(pye); } } }); return proxy; }
// in src/org/python/jsr223/PyScriptEngine.java
public Object invoke(Object proxy, Method method, Object[] args) throws Throwable { try { interp.setLocals(new PyScriptEngineScope(PyScriptEngine.this, context)); PyObject pyMethod = thiz.__findattr__(method.getName()); if (pyMethod == null) throw new NoSuchMethodException(method.getName()); PyObject result = pyMethod.__call__(Py.javas2pys(args)); return result.__tojava__(Object.class); } catch (PyException pye) { throw scriptException(pye); } }
// in src/org/python/modules/jffi/AllocatedNativeMemory.java
Override protected void finalize() throws Throwable { try { if (!released && autorelease) { IO.freeMemory(storage); released = true; } } finally { super.finalize(); } }
// in src/org/python/core/PyObject.java
public PyObject _jcallexc(Object[] args) throws Throwable { try { return __call__(Py.javas2pys(args)); } catch (PyException e) { if (e.value.getJavaProxy() != null) { Object t = e.value.__tojava__(Throwable.class); if (t != null && t != Py.NoConversion) { throw (Throwable) t; } } else { ThreadState ts = Py.getThreadState(); if (ts.frame == null) { Py.maybeSystemExit(e); } if (Options.showPythonProxyExceptions) { Py.stderr.println( "Exception in Python proxy returning to Java:"); Py.printException(e); } } throw e; } }
// in src/org/python/core/PyFile.java
Override protected void finalize() throws Throwable { super.finalize(); if (closer != null) { closer.close(); } }
// in src/org/python/core/PyFunction.java
public Object invoke( Object proxy, Method method, Object[] args ) throws Throwable { // Handle invocation when invoked through Proxy (as coerced to single method interface) if (method.getDeclaringClass() == Object.class) { return method.invoke( this, args ); } else if (args == null || args.length == 0) { return __call__().__tojava__(method.getReturnType()); } else { return __call__(Py.javas2pys(args)).__tojava__(method.getReturnType()); } }
// in src/org/python/core/ParserFacade.java
private static mod parse(ExpectedEncodingBufferedReader reader, CompileMode kind, String filename, CompilerFlags cflags) throws Throwable { reader.mark(MARK_LIMIT); // We need the ability to move back on the // reader, for the benefit of fixParseError and // validPartialSentence if (kind != null) { CharStream cs = new NoCloseReaderStream(reader); BaseParser parser = new BaseParser(cs, filename, cflags.encoding); return kind.dispatch(parser); } else { throw Py.ValueError("parse kind must be eval, exec, or single"); } }
// in src/org/python/core/PyGenerator.java
Override protected void finalize() throws Throwable { if (gi_frame == null || gi_frame.f_lasti == -1) { return; } try { close(); } catch (PyException pye) { // PEP 342 specifies that if an exception is raised by close, // we output to stderr and then forget about it; String className = PyException.exceptionClassName(pye.type); int lastDot = className.lastIndexOf('.'); if (lastDot != -1) { className = className.substring(lastDot + 1); } String msg = String.format("Exception %s: %s in %s", className, pye.value.__repr__(), __repr__()); Py.println(Py.getSystemState().stderr, Py.newString(msg)); } catch (Throwable t) { // but we currently ignore any Java exception completely. perhaps we // can also output something meaningful too? } finally { super.finalize(); } }
55
            
// in src/com/ziclix/python/sql/handler/RowIdHandler.java
catch (Throwable t) { ROWIDS.put(c, CHECKED); }
// in src/com/ziclix/python/sql/handler/RowIdHandler.java
catch (Throwable t) {}
// in src/com/ziclix/python/sql/Fetch.java
catch (Throwable t) { // ok }
// in src/com/ziclix/python/sql/Fetch.java
catch (Throwable e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/Fetch.java
catch (Throwable e) { }
// in src/com/ziclix/python/sql/Fetch.java
catch (Throwable e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/Fetch.java
catch (Throwable e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/Fetch.java
catch (Throwable e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/Fetch.java
catch (Throwable t) { throw zxJDBC.makeException(t); }
// in src/com/ziclix/python/sql/zxJDBC.java
catch (Throwable t) { throw makeException(t); }
// in src/com/ziclix/python/sql/zxJDBC.java
catch (Throwable t) { Py.writeComment("zxJDBC", "failed to load connector [" + name + "] using class [" + className + "]"); }
// in src/com/ziclix/python/sql/DataHandler.java
catch (Throwable t) { SQLException cause = null; SQLException ex = new SQLException("error setting index [" + index + "], coltype [" + colType + "], datatype [" + dataType + "], datatypename [" + dataTypeName + "]"); if (t instanceof SQLException) { cause = (SQLException)t; } else { cause = new SQLException(t.getMessage()); } ex.setNextException(cause); throw ex; }
// in src/com/ziclix/python/sql/DataHandler.java
catch (Throwable t) {}
// in src/com/ziclix/python/sql/Jython22DataHandler.java
catch (Throwable t) {}
// in src/com/ziclix/python/sql/Jython22DataHandler.java
catch (Throwable t) { bd = set.getBigDecimal(col, 10); }
// in src/com/ziclix/python/sql/Jython22DataHandler.java
catch (Throwable t) { SQLException cause = null; SQLException ex = new SQLException("error setting index [" + index + "], coltype [" + colType + "], datatype [" + dataType + "], datatypename [" + dataTypeName + "]"); if (t instanceof SQLException) { cause = (SQLException)t; } else { cause = new SQLException(t.getMessage()); } ex.setNextException(cause); throw ex; }
// in src/com/ziclix/python/sql/connect/Connect.java
catch (Throwable e) { throw zxJDBC.makeException(zxJDBC.DatabaseError, "driver [" + driver + "] not found"); }
// in src/com/ziclix/python/sql/pipe/Pipe.java
catch (Throwable e) { this.exception = e.fillInStackTrace(); this.queue.close(); }
// in src/com/ziclix/python/sql/PyCursor.java
catch (Throwable t) {}
// in src/com/ziclix/python/sql/PyCursor.java
catch (Throwable e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyCursor.java
catch (Throwable t) { if (statement != null) { statement.close(); } throw zxJDBC.makeException(t); }
// in src/com/ziclix/python/sql/PyCursor.java
catch (Throwable t) { if (statement != null && !(sql instanceof PyStatement)) { // only close static, single-use statements statement.close(); } throw zxJDBC.makeException(zxJDBC.Error, t, rowIndex); }
// in src/com/ziclix/python/sql/PyCursor.java
catch (Throwable e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyCursor.java
catch (Throwable e) { // ok }
// in src/org/python/compiler/ScopesCompiler.java
catch (Throwable t) { throw ParserFacade.fixParseError(null, t, code_compiler.getFilename()); }
// in src/org/python/core/PyBeanProperty.java
catch (Throwable t) { throw Py.JavaError(t); }
// in src/org/python/core/PyObject.java
catch (Throwable t) { _jthrow(t); return null; }
// in src/org/python/core/PyReflectedConstructor.java
catch (Throwable t) { throw Py.JavaError(t); }
// in src/org/python/core/PyReflectedConstructor.java
catch (Throwable t) { throw Py.JavaError(t); }
// in src/org/python/core/PyTableCode.java
catch (Throwable t) { // Convert exceptions that occured in Java code to PyExceptions PyException pye = Py.JavaError(t); pye.tracebackHere(frame); frame.f_lasti = -1; if (frame.tracefunc != null) { frame.tracefunc.traceException(frame, pye); } if (ts.profilefunc != null) { ts.profilefunc.traceException(frame, pye); } // Rethrow the exception to the next stack frame ts.exception = previous_exception; ts.frame = ts.frame.f_back; throw pye; }
// in src/org/python/core/PyReflectedFunction.java
catch (Throwable t) { throw Py.JavaError(t); }
// in src/org/python/core/PyBaseCode.java
catch (Throwable t) { // Convert exceptions that occured in Java code to PyExceptions PyException pye = Py.JavaError(t); pye.tracebackHere(frame); frame.f_lasti = -1; if (frame.tracefunc != null) { frame.tracefunc.traceException(frame, pye); } if (ts.profilefunc != null) { ts.profilefunc.traceException(frame, pye); } // Rethrow the exception to the next stack frame ts.exception = previous_exception; ts.frame = ts.frame.f_back; throw pye; }
// in src/org/python/core/exceptions.java
catch (Throwable t) { throw Py.JavaError(t); }
// in src/org/python/core/CompilerFacade.java
catch (Throwable t) { throw ParserFacade.fixParseError(null, t, filename); }
// in src/org/python/core/Py.java
catch (Throwable t) { // continue }
// in src/org/python/core/Py.java
catch (Throwable t) { t.printStackTrace(); }
// in src/org/python/core/Py.java
catch (Throwable t) { throw Py.JavaError(t); }
// in src/org/python/core/PySequence.java
catch (Throwable t) { // ok }
// in src/org/python/core/ParserFacade.java
catch (Throwable t) { if (bufReader == null) throw Py.JavaError(t); // can't do any more try { // then, try parsing as a module bufReader.reset(); return parse(bufReader, CompileMode.exec, filename, cflags); } catch (Throwable tt) { throw fixParseError(bufReader, tt, filename); } }
// in src/org/python/core/ParserFacade.java
catch (Throwable tt) { throw fixParseError(bufReader, tt, filename); }
// in src/org/python/core/ParserFacade.java
catch (Throwable t) { throw fixParseError(bufReader, t, filename); }
// in src/org/python/core/ParserFacade.java
catch (Throwable t) { throw fixParseError(bufReader, t, filename); }
// in src/org/python/core/ParserFacade.java
catch (Throwable t) { throw fixParseError(bufReader, t, filename); }
// in src/org/python/core/ParserFacade.java
catch (Throwable t) { PyException p = fixParseError(reader, t, filename); if (reader != null && validPartialSentence(reader, kind, filename)) { return null; } throw p; }
// in src/org/python/core/PyBytecode.java
catch (Throwable t) { PyException pye = Py.setException(t, f); why = Why.EXCEPTION; ts.exception = pye; if (debug) { System.err.println("Caught exception:" + pye); } }
// in src/org/python/core/imp.java
catch (Throwable t) { if (testing) { return null; } else { throw Py.JavaError(t); } }
// in src/org/python/core/imp.java
catch(Throwable t) { throw ParserFacade.fixParseError(null, t, filename); }
// in src/org/python/core/PyGenerator.java
catch (Throwable t) { // but we currently ignore any Java exception completely. perhaps we // can also output something meaningful too? }
// in src/org/python/util/jython.java
catch (Throwable t) { Py.printException(t); System.exit(-1); }
// in src/org/python/util/jython.java
catch (Throwable t) { Py.printException(t); }
// in src/org/python/util/jython.java
catch (Throwable t) { if (t instanceof PyException && ((PyException)t).match(_systemrestart.SystemRestart)) { // Shutdown this instance... shouldRestart = true; shutdownInterpreter(); interp.cleanup(); // ..reset the state... Py.setSystemState(new PySystemState()); // ...and start again return; } else { Py.printException(t); interp.cleanup(); System.exit(-1); } }
// in src/org/python/util/jython.java
catch (Throwable t) { Py.printException(t); System.exit(1); }
// in src/org/python/util/jython.java
catch (Throwable t) { Py.printException(t); interp.cleanup(); System.exit(-1); }
// in src/org/python/util/jython.java
catch (Throwable t) { Py.printException(t); }
// in src/org/python/util/jython.java
catch (Throwable t) { // fall through }
31
            
// in src/com/ziclix/python/sql/Fetch.java
catch (Throwable e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/Fetch.java
catch (Throwable e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/Fetch.java
catch (Throwable e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/Fetch.java
catch (Throwable e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/Fetch.java
catch (Throwable t) { throw zxJDBC.makeException(t); }
// in src/com/ziclix/python/sql/zxJDBC.java
catch (Throwable t) { throw makeException(t); }
// in src/com/ziclix/python/sql/DataHandler.java
catch (Throwable t) { SQLException cause = null; SQLException ex = new SQLException("error setting index [" + index + "], coltype [" + colType + "], datatype [" + dataType + "], datatypename [" + dataTypeName + "]"); if (t instanceof SQLException) { cause = (SQLException)t; } else { cause = new SQLException(t.getMessage()); } ex.setNextException(cause); throw ex; }
// in src/com/ziclix/python/sql/Jython22DataHandler.java
catch (Throwable t) { SQLException cause = null; SQLException ex = new SQLException("error setting index [" + index + "], coltype [" + colType + "], datatype [" + dataType + "], datatypename [" + dataTypeName + "]"); if (t instanceof SQLException) { cause = (SQLException)t; } else { cause = new SQLException(t.getMessage()); } ex.setNextException(cause); throw ex; }
// in src/com/ziclix/python/sql/connect/Connect.java
catch (Throwable e) { throw zxJDBC.makeException(zxJDBC.DatabaseError, "driver [" + driver + "] not found"); }
// in src/com/ziclix/python/sql/PyCursor.java
catch (Throwable e) { throw zxJDBC.makeException(e); }
// in src/com/ziclix/python/sql/PyCursor.java
catch (Throwable t) { if (statement != null) { statement.close(); } throw zxJDBC.makeException(t); }
// in src/com/ziclix/python/sql/PyCursor.java
catch (Throwable t) { if (statement != null && !(sql instanceof PyStatement)) { // only close static, single-use statements statement.close(); } throw zxJDBC.makeException(zxJDBC.Error, t, rowIndex); }
// in src/com/ziclix/python/sql/PyCursor.java
catch (Throwable e) { throw zxJDBC.makeException(e); }
// in src/org/python/compiler/ScopesCompiler.java
catch (Throwable t) { throw ParserFacade.fixParseError(null, t, code_compiler.getFilename()); }
// in src/org/python/core/PyBeanProperty.java
catch (Throwable t) { throw Py.JavaError(t); }
// in src/org/python/core/PyReflectedConstructor.java
catch (Throwable t) { throw Py.JavaError(t); }
// in src/org/python/core/PyReflectedConstructor.java
catch (Throwable t) { throw Py.JavaError(t); }
// in src/org/python/core/PyTableCode.java
catch (Throwable t) { // Convert exceptions that occured in Java code to PyExceptions PyException pye = Py.JavaError(t); pye.tracebackHere(frame); frame.f_lasti = -1; if (frame.tracefunc != null) { frame.tracefunc.traceException(frame, pye); } if (ts.profilefunc != null) { ts.profilefunc.traceException(frame, pye); } // Rethrow the exception to the next stack frame ts.exception = previous_exception; ts.frame = ts.frame.f_back; throw pye; }
// in src/org/python/core/PyReflectedFunction.java
catch (Throwable t) { throw Py.JavaError(t); }
// in src/org/python/core/PyBaseCode.java
catch (Throwable t) { // Convert exceptions that occured in Java code to PyExceptions PyException pye = Py.JavaError(t); pye.tracebackHere(frame); frame.f_lasti = -1; if (frame.tracefunc != null) { frame.tracefunc.traceException(frame, pye); } if (ts.profilefunc != null) { ts.profilefunc.traceException(frame, pye); } // Rethrow the exception to the next stack frame ts.exception = previous_exception; ts.frame = ts.frame.f_back; throw pye; }
// in src/org/python/core/exceptions.java
catch (Throwable t) { throw Py.JavaError(t); }
// in src/org/python/core/CompilerFacade.java
catch (Throwable t) { throw ParserFacade.fixParseError(null, t, filename); }
// in src/org/python/core/Py.java
catch (Throwable t) { throw Py.JavaError(t); }
// in src/org/python/core/ParserFacade.java
catch (Throwable t) { if (bufReader == null) throw Py.JavaError(t); // can't do any more try { // then, try parsing as a module bufReader.reset(); return parse(bufReader, CompileMode.exec, filename, cflags); } catch (Throwable tt) { throw fixParseError(bufReader, tt, filename); } }
// in src/org/python/core/ParserFacade.java
catch (Throwable tt) { throw fixParseError(bufReader, tt, filename); }
// in src/org/python/core/ParserFacade.java
catch (Throwable t) { throw fixParseError(bufReader, t, filename); }
// in src/org/python/core/ParserFacade.java
catch (Throwable t) { throw fixParseError(bufReader, t, filename); }
// in src/org/python/core/ParserFacade.java
catch (Throwable t) { throw fixParseError(bufReader, t, filename); }
// in src/org/python/core/ParserFacade.java
catch (Throwable t) { PyException p = fixParseError(reader, t, filename); if (reader != null && validPartialSentence(reader, kind, filename)) { return null; } throw p; }
// in src/org/python/core/imp.java
catch (Throwable t) { if (testing) { return null; } else { throw Py.JavaError(t); } }
// in src/org/python/core/imp.java
catch(Throwable t) { throw ParserFacade.fixParseError(null, t, filename); }
0
unknown (Lib) UnsupportedCharsetException 0 0 0 2
            
// in src/org/python/core/PySystemState.java
catch (UnsupportedCharsetException e) { Py.writeWarning("initializer", "Unable to load the UTF-8 charset to read an initializer definition"); e.printStackTrace(System.err); }
// in src/org/python/core/ParserFacade.java
catch (UnsupportedCharsetException exc) { throw new PySyntaxError("Unknown encoding: " + encoding, 1, 0, "", filename); }
1
            
// in src/org/python/core/ParserFacade.java
catch (UnsupportedCharsetException exc) { throw new PySyntaxError("Unknown encoding: " + encoding, 1, 0, "", filename); }
1
unknown (Lib) UnsupportedEncodingException 0 0 0 1
            
// in src/org/python/core/util/StringUtil.java
catch(UnsupportedEncodingException uee) { // This JVM is whacked, it doesn't even have iso-8859-1 throw Py.SystemError("Java couldn't find the ISO-8859-1 encoding"); }
1
            
// in src/org/python/core/util/StringUtil.java
catch(UnsupportedEncodingException uee) { // This JVM is whacked, it doesn't even have iso-8859-1 throw Py.SystemError("Java couldn't find the ISO-8859-1 encoding"); }
0
runtime (Lib) UnsupportedOperationException 43
            
// in src/org/python/indexer/Outliner.java
public void setChildren(List<Entry> children) { throw new UnsupportedOperationException("Leaf nodes cannot have children."); }
// in src/org/python/indexer/ast/NNode.java
protected void bindNames(Scope s) throws Exception { throw new UnsupportedOperationException("Not a name-binding node type"); }
// in src/org/python/modules/jffi/MemoryOp.java
public static final MemoryOp getMemoryOp(NativeType type) { switch (type) { case VOID: return VOID; case BYTE: return INT8; case UBYTE: return UINT8; case SHORT: return INT16; case USHORT: return UINT16; case INT: return INT32; case UINT: return UINT32; case LONGLONG: return INT64; case ULONGLONG: return UINT64; case LONG: return com.kenai.jffi.Platform.getPlatform().longSize() == 32 ? INT32 : INT64; case ULONG: return com.kenai.jffi.Platform.getPlatform().longSize() == 32 ? UINT32 : UINT64; case FLOAT: return FLOAT; case DOUBLE: return DOUBLE; case POINTER: return POINTER; case STRING: return STRING; case BOOL: return BOOL; default: throw new UnsupportedOperationException("No MemoryOp for " + type); } }
// in src/org/python/core/PyFrozenSet.java
public void clear() { throw new UnsupportedOperationException(); }
// in src/org/python/core/PyFrozenSet.java
public boolean add(Object o) { throw new UnsupportedOperationException(); }
// in src/org/python/core/PyFrozenSet.java
public boolean remove(Object o) { throw new UnsupportedOperationException(); }
// in src/org/python/core/PyFrozenSet.java
public boolean addAll(Collection c) { throw new UnsupportedOperationException(); }
// in src/org/python/core/PyFrozenSet.java
public boolean removeAll(Collection c) { throw new UnsupportedOperationException(); }
// in src/org/python/core/PyFrozenSet.java
public boolean retainAll(Collection c) { throw new UnsupportedOperationException(); }
// in src/org/python/core/PyFrozenSet.java
public void remove() { throw new UnsupportedOperationException(); }
// in src/org/python/core/PyUnicode.java
public void remove() { throw new UnsupportedOperationException("Not supported on PyUnicode objects (immutable)"); }
// in src/org/python/core/PyUnicode.java
public void remove() { throw new UnsupportedOperationException(); }
// in src/org/python/core/PyUnicode.java
public void remove() { throw new UnsupportedOperationException(); }
// in src/org/python/core/PyUnicode.java
public void remove() { throw new UnsupportedOperationException(); }
// in src/org/python/core/PyUnicode.java
public void remove() { throw new UnsupportedOperationException(); }
// in src/org/python/core/PyUnicode.java
public void remove() { throw new UnsupportedOperationException(); }
// in src/org/python/core/PyUnicode.java
public void remove() { throw new UnsupportedOperationException(); }
// in src/org/python/core/PyTuple.java
public void remove() { throw new UnsupportedOperationException(); }
// in src/org/python/core/PyTuple.java
public boolean add(Object o) { throw new UnsupportedOperationException(); }
// in src/org/python/core/PyTuple.java
public boolean remove(Object o) { throw new UnsupportedOperationException(); }
// in src/org/python/core/PyTuple.java
public boolean addAll(Collection coll) { throw new UnsupportedOperationException(); }
// in src/org/python/core/PyTuple.java
public boolean removeAll(Collection coll) { throw new UnsupportedOperationException(); }
// in src/org/python/core/PyTuple.java
public boolean retainAll(Collection coll) { throw new UnsupportedOperationException(); }
// in src/org/python/core/PyTuple.java
public void clear() { throw new UnsupportedOperationException(); }
// in src/org/python/core/PyTuple.java
public Object set(int index, Object element) { throw new UnsupportedOperationException(); }
// in src/org/python/core/PyTuple.java
public void add(int index, Object element) { throw new UnsupportedOperationException(); }
// in src/org/python/core/PyTuple.java
public Object remove(int index) { throw new UnsupportedOperationException(); }
// in src/org/python/core/PyTuple.java
public boolean addAll(int index, Collection c) { throw new UnsupportedOperationException(); }
// in src/org/python/core/PyTuple.java
public void remove() { throw new UnsupportedOperationException(); }
// in src/org/python/core/PyTuple.java
public void set(Object o) { throw new UnsupportedOperationException(); }
// in src/org/python/core/PyTuple.java
public void add(Object o) { throw new UnsupportedOperationException(); }
// in src/org/python/core/PyTuple.java
Override public void pyadd(int index, PyObject element) { throw new UnsupportedOperationException(); }
// in src/org/python/core/PyTuple.java
Override public boolean pyadd(PyObject o) { throw new UnsupportedOperationException(); }
// in src/org/python/core/PyTuple.java
Override public void remove(int start, int stop) { throw new UnsupportedOperationException(); }
// in src/org/python/core/PyDataDescr.java
public void invokeSet(PyObject obj, Object converted) { throw new UnsupportedOperationException("Must be overriden by a subclass"); }
// in src/org/python/core/PyDataDescr.java
public void invokeDelete(PyObject obj) { throw new UnsupportedOperationException("Must be overriden by a subclass"); }
// in src/org/python/core/PyDictionary.java
public Object setValue(Object val) { throw new UnsupportedOperationException("Not supported by this view"); }
// in src/org/python/core/PyTableCode.java
Override protected PyObject interpret(PyFrame f, ThreadState ts) { throw new UnsupportedOperationException("Inlined interpret to improve call performance (may want to reconsider in the future)."); }
// in src/org/python/core/WrappedIterIterator.java
public void remove() { throw new UnsupportedOperationException("Can't remove from a Python iterator"); }
// in src/org/python/core/CodeFlag.java
public void remove() { throw new UnsupportedOperationException(); }
// in src/org/python/core/codecs.java
public static String PyUnicode_EncodeIDNA(PyUnicode input, String errors) { throw new UnsupportedOperationException(); // 1. If the sequence contains any code points outside the ASCII range // (0..7F) then proceed to step 2, otherwise skip to step 3. // // 2. Perform the steps specified in [NAMEPREP] and fail if there is an // error. The AllowUnassigned flag is used in [NAMEPREP]. // this basically enails changing out space, etc. // // 3. If the UseSTD3ASCIIRules flag is set, then perform these checks: // // (a) Verify the absence of non-LDH ASCII code points; that is, the // absence of 0..2C, 2E..2F, 3A..40, 5B..60, and 7B..7F. // // (b) Verify the absence of leading and trailing hyphen-minus; that // is, the absence of U+002D at the beginning and end of the // sequence. // // 4. If the sequence contains any code points outside the ASCII range // (0..7F) then proceed to step 5, otherwise skip to step 8. // // 5. Verify that the sequence does NOT begin with the ACE prefix. // // 6. Encode the sequence using the encoding algorithm in [PUNYCODE] and // fail if there is an error. // // 7. Prepend the ACE prefix. // // 8. Verify that the number of code points is in the range 1 to 63 // inclusive. }
// in src/org/python/core/codecs.java
public static PyUnicode PyUnicode_DecodeIDNA(String input, String errors) { throw new UnsupportedOperationException(); }
// in src/org/python/core/codecs.java
public void remove() { throw new UnsupportedOperationException("Not supported on String objects (immutable)"); }
0 0 1
            
// in src/org/python/util/ReadlineConsole.java
catch (UnsupportedOperationException uoe) { // parseAndBind not supported by this readline }
0 0

Miscellanous Metrics

nF = Number of Finally 214
nF = Number of Try-Finally (without catch) 191
Number of Methods with Finally (nMF) 183 / 19495 (0.9%)
Number of Finally with a Continue 0
Number of Finally with a Return 0
Number of Finally with a Throw 5
Number of Finally with a Break 0
Number of different exception types thrown 30
Number of Domain exception types thrown 8
Number of different exception types caught 52
Number of Domain exception types caught 7
Number of exception declarations in signatures 803
Number of different exceptions types declared in method signatures 21
Number of library exceptions types declared in method signatures 18
Number of Domain exceptions types declared in method signatures 3
Number of Catch with a continue 3
Number of Catch with a return 440
Number of Catch with a Break 2
nbIf = Number of If 26958
nbFor = Number of For 1199
Number of Method with an if 12743 / 19495
Number of Methods with a for 794 / 19495
Number of Method starting with a try 85 / 19495 (0.4%)
Number of Expressions 238891
Number of Expressions in try 9645 (4%)