Package org.python.pydev.parser.jython.ast

Examples of org.python.pydev.parser.jython.ast.exprType.accept()


            if (i >= 1) { //more than one assign
                doc.add(lowerAndHigher.o2.getLine(), lowerAndHigher.o2.getBeginCol(),
                        this.prefs.getAssignPunctuation(), node);
            }
            id = this.doc.pushRecordChanges();
            target.accept(this);
            recordChanges = this.doc.popRecordChanges(id);
            lowerAndHigher = doc.getLowerAndHigerFound(recordChanges);
        }
        doc.add(lowerAndHigher.o2.getLine(), lowerAndHigher.o2.getBeginCol(), this.prefs.getAssignPunctuation(), node);
View Full Code Here


        node.context_expr.accept(this);

        exprType optional = node.optional_vars;
        if (optional != null && lastNode != null) {
            doc.addRequire("as", lastNode);
            optional.accept(this);
        }

        afterNode(node);
        return null;
    }
View Full Code Here

                if (i > 0 || node.dest != null) {
                    doc.addRequire(",", lastNode);
                }
                exprType value = node.values[i];
                if (value != null) {
                    value.accept(this);
                }
            }
        }

        afterNode(node);
View Full Code Here

                exprType str = node.strs[i];
                if (str != null) {
                    if (last != null && last.beginLine != str.beginLine) {
                        this.doc.addRequire("\\", last);
                    }
                    str.accept(this);
                    //                    if(last == null){
                    //                        doc.addIndent(str); //Only add an indent after the 1st string
                    //                    }
                    last = str;
                }
View Full Code Here

            }
            exprType argName = args[i];

            //this is something as >>var:int=10<<
            //handle argument
            argName.accept(this);

            //handle annotation
            if (anns != null) {
                exprType ann = anns[i];
                if (ann != null) {
View Full Code Here

            //handle annotation
            if (anns != null) {
                exprType ann = anns[i];
                if (ann != null) {
                    doc.addRequire(":", lastNode);
                    ann.accept(this); //right after the '='
                }
            }

            //handle defaults
            if (i >= diff) {
View Full Code Here

            //handle defaults
            if (i >= diff) {
                exprType defaulArgValue = d[i - diff];
                if (defaulArgValue != null) {
                    doc.addRequire("=", lastNode);
                    defaulArgValue.accept(this);
                }
            }

        }
View Full Code Here

                foundBefore = true;

                exprType kwonlyarg = completeArgs.kwonlyargs[i];
                if (kwonlyarg != null) {

                    kwonlyarg.accept(this);

                    if (completeArgs.kwonlyargannotation != null && completeArgs.kwonlyargannotation[i] != null) {
                        doc.addRequire(":", lastNode);
                        completeArgs.kwonlyargannotation[i].accept(this);
                    }
View Full Code Here

    public Object visitAssign(Assign node) throws Exception {
        fixNode(node);

        for (int i = 0; i < node.targets.length; i++) {
            exprType target = node.targets[i];
            target.accept(this);
            nextCol();
        }

        node.value.accept(this);
        nextCol();
View Full Code Here

                if (i > 0 || node.dest != null) {

                }
                exprType value = node.values[i];
                if (value != null) {
                    value.accept(this);
                }
            }
        }
        fixAfterNode(node);
View Full Code Here

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