Package org.python.indexer.ast

Examples of org.python.indexer.ast.NModule


        // Put it in the cache now to prevent circular import from recursing.
        NModuleType mod = new NModuleType(Util.moduleNameFor(file), file, globaltable);
        moduleTable.put(file, new NUrl("file://" + file), mod, NBinding.Kind.MODULE);

        try {
            NModule ast = null;
            if (contents != null) {
                ast = getAstForFile(file, contents);
            } else {
                ast = getAstForFile(file);
            }
            if (ast == null) {
                return null;
            }

            finer("resolving: " + file);
            ast.resolve(globaltable);
            finer("[success]");
            loadedFiles++;
            return mod;
        } catch (OutOfMemoryError e) {
            if (astCache != null) {
View Full Code Here


        return new NListComp(convExpr(n.getInternalElt()), generators, start(n), stop(n));
    }

    @Override
    public Object visitModule(Module n) throws Exception {
        return new NModule(convertListStmt(n.getInternalBody()), start(n), stop(n));
    }
View Full Code Here

TOP

Related Classes of org.python.indexer.ast.NModule

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.