@Override protected BlockNode initBlockNode() { return new ScopedBlockNode(); }
/** * Constructor. */ public MemberedNode() { super(); contentsNode = new ScopedBlockNode(); }
/** * Constructor. */ public MemberedNode() { super(); contentsNode = new ScopedBlockNode(); }
@Override protected BlockNode initBlockNode() { return new ScopedBlockNode(); }
/** * Constructor. * * @param packageNameNode node holding this package name */ public PackageNode(ExpressionNodeBase packageNameNode, IASToken packageKeyword) { super(); init(packageNameNode); this.packageNameNode = packageNameNode; contentsNode = new ScopedBlockNode(); if (packageKeyword != null) packageKeywordStart = packageKeyword.getStart(); else packageKeywordStart = -1; }
/** * Constructor. * * @param packageNameNode node holding this package name */ public PackageNode(ExpressionNodeBase packageNameNode, IASToken packageKeyword) { super(); init(packageNameNode); this.packageNameNode = packageNameNode; contentsNode = new ScopedBlockNode(); if (packageKeyword != null) packageKeywordStart = packageKeyword.getStart(); else packageKeywordStart = -1; }
public FunctionContentsPart() { super(); argumentsNode = new ContainerNode(2); argumentsNode.setContainerType(ContainerType.PARENTHESIS); contentsNode = new ScopedBlockNode(false); // Set the contents to implicit - the parser will set to BRACES if it // sees a function body contentsNode.setContainerType(ContainerType.SYNTHESIZED); }
public FunctionContentsPart() { super(); argumentsNode = new ContainerNode(2); argumentsNode.setContainerType(ContainerType.PARENTHESIS); contentsNode = new ScopedBlockNode(false); // Set the contents to implicit - the parser will set to BRACES if it // sees a function body contentsNode.setContainerType(ContainerType.SYNTHESIZED); }
/** * * @param code * @param problems * @return */ public static IASNode parseExpression(String code, List<ICompilerProblem> problems) { IWorkspace workspace = new Workspace(); DebuggerUtil.InMemoryFileSpecification imfs = new DebuggerUtil.InMemoryFileSpecification(code); EnumSet<PostProcessStep> empty = EnumSet.noneOf(PostProcessStep.class); IASNode exprAST = ASParser.parseFile(imfs, workspace, empty, null, false, false, new ArrayList<String>(), null, null, null); // Have to create a fake ScopedBlockNode so the expression can do things // like resolve, which means it has to be able to find a scope. // For parsing an expression in a file, one would hook up the expression // AST to whatever the real scope was. ScopedBlockNode scopedNode = new ScopedBlockNode(); scopedNode.addChild((NodeBase)exprAST); scopedNode.setScope(new ASFileScope(workspace, "fake")); scopedNode.runPostProcess(EnumSet.of(PostProcessStep.CALCULATE_OFFSETS)); // return the first (and only child). This is essentially unwrapping the // FileNode that was wrapped around the expression being parsed return exprAST.getChild(0); }
final ScopedBlockNode container = new ScopedBlockNode(); container.setScope(containingScope); try
final ScopedBlockNode container = new ScopedBlockNode(); container.setScope(containingScope); try
final int compilableTextColumn = mxmlTextData.getCompilableTextColumn(); final ScopedBlockNode container = new ScopedBlockNode();
final int compilableTextColumn = mxmlTextData.getCompilableTextColumn(); final ScopedBlockNode container = new ScopedBlockNode();
ScopedBlockNode container = new ScopedBlockNode(); ASParser parser = null;
ScopedBlockNode container = new ScopedBlockNode(); ASParser parser = null;