Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [wtp-dev] ASTView for JSDT

btw. ASTVisitor (astview.GenericVisitor class) in that ASTView is skipping some nodes (see attached diff for details).
Is that intentional or shall I open a bug?

cheers

Jacek


Jacek Pospychala wrote:
thanks!
I knew it must have been somewhere!

Jacek

Nitin Dahyabhai wrote:
I've committed a version modified from the JDT plug-in into :pserver:anonymous@xxxxxxxxxxxxxxx:/cvsroot/webtools under sourceediting/development/org.eclipse.wst.jsdt.astview. For now I have no plans to provide it as a built plug-in.


Regards,
---
Nitin Dahyabhai
Eclipse WTP Source Editing
IBM Rational

_______________________________________________
wtp-dev mailing list
wtp-dev@xxxxxxxxxxx
https://dev.eclipse.org/mailman/listinfo/wtp-dev

_______________________________________________
wtp-dev mailing list
wtp-dev@xxxxxxxxxxx
https://dev.eclipse.org/mailman/listinfo/wtp-dev

### Eclipse Workspace Patch 1.0
#P org.eclipse.wst.jsdt.astview
Index: src/org/eclipse/wst/jsdt/astview/GenericVisitor.java
===================================================================
RCS file: /cvsroot/webtools/sourceediting/development/org.eclipse.wst.jsdt.astview/src/org/eclipse/wst/jsdt/astview/GenericVisitor.java,v
retrieving revision 1.1
diff -u -r1.1 GenericVisitor.java
--- src/org/eclipse/wst/jsdt/astview/GenericVisitor.java	8 Dec 2009 21:57:48 -0000	1.1
+++ src/org/eclipse/wst/jsdt/astview/GenericVisitor.java	8 Dec 2009 23:07:29 -0000
@@ -34,13 +34,16 @@
 import org.eclipse.wst.jsdt.core.dom.ExpressionStatement;
 import org.eclipse.wst.jsdt.core.dom.FieldAccess;
 import org.eclipse.wst.jsdt.core.dom.FieldDeclaration;
+import org.eclipse.wst.jsdt.core.dom.ForInStatement;
 import org.eclipse.wst.jsdt.core.dom.ForStatement;
 import org.eclipse.wst.jsdt.core.dom.FunctionDeclaration;
+import org.eclipse.wst.jsdt.core.dom.FunctionExpression;
 import org.eclipse.wst.jsdt.core.dom.FunctionInvocation;
 import org.eclipse.wst.jsdt.core.dom.FunctionRef;
 import org.eclipse.wst.jsdt.core.dom.FunctionRefParameter;
 import org.eclipse.wst.jsdt.core.dom.IfStatement;
 import org.eclipse.wst.jsdt.core.dom.ImportDeclaration;
+import org.eclipse.wst.jsdt.core.dom.InferredType;
 import org.eclipse.wst.jsdt.core.dom.InfixExpression;
 import org.eclipse.wst.jsdt.core.dom.Initializer;
 import org.eclipse.wst.jsdt.core.dom.InstanceofExpression;
@@ -48,10 +51,13 @@
 import org.eclipse.wst.jsdt.core.dom.JavaScriptUnit;
 import org.eclipse.wst.jsdt.core.dom.LabeledStatement;
 import org.eclipse.wst.jsdt.core.dom.LineComment;
+import org.eclipse.wst.jsdt.core.dom.ListExpression;
 import org.eclipse.wst.jsdt.core.dom.MemberRef;
 import org.eclipse.wst.jsdt.core.dom.Modifier;
 import org.eclipse.wst.jsdt.core.dom.NullLiteral;
 import org.eclipse.wst.jsdt.core.dom.NumberLiteral;
+import org.eclipse.wst.jsdt.core.dom.ObjectLiteral;
+import org.eclipse.wst.jsdt.core.dom.ObjectLiteralField;
 import org.eclipse.wst.jsdt.core.dom.PackageDeclaration;
 import org.eclipse.wst.jsdt.core.dom.ParenthesizedExpression;
 import org.eclipse.wst.jsdt.core.dom.PostfixExpression;
@@ -59,6 +65,7 @@
 import org.eclipse.wst.jsdt.core.dom.PrimitiveType;
 import org.eclipse.wst.jsdt.core.dom.QualifiedName;
 import org.eclipse.wst.jsdt.core.dom.QualifiedType;
+import org.eclipse.wst.jsdt.core.dom.RegularExpressionLiteral;
 import org.eclipse.wst.jsdt.core.dom.ReturnStatement;
 import org.eclipse.wst.jsdt.core.dom.SimpleName;
 import org.eclipse.wst.jsdt.core.dom.SimpleType;
@@ -77,10 +84,12 @@
 import org.eclipse.wst.jsdt.core.dom.TypeDeclaration;
 import org.eclipse.wst.jsdt.core.dom.TypeDeclarationStatement;
 import org.eclipse.wst.jsdt.core.dom.TypeLiteral;
+import org.eclipse.wst.jsdt.core.dom.UndefinedLiteral;
 import org.eclipse.wst.jsdt.core.dom.VariableDeclarationExpression;
 import org.eclipse.wst.jsdt.core.dom.VariableDeclarationFragment;
 import org.eclipse.wst.jsdt.core.dom.VariableDeclarationStatement;
 import org.eclipse.wst.jsdt.core.dom.WhileStatement;
+import org.eclipse.wst.jsdt.core.dom.WithStatement;
 import org.eclipse.wst.jsdt.internal.compiler.ast.Javadoc;
 
 public class GenericVisitor extends ASTVisitor {
@@ -351,6 +360,41 @@
 	public boolean visit(TextElement node) {
 		return visitNode(node);
 	}
+	public boolean visit(RegularExpressionLiteral node) {
+		return visitNode(node);
+	}
+	
+	public boolean visit(ForInStatement node) {
+		return visitNode(node);
+	}
+	
+	public boolean visit(InferredType node) {
+		return visitNode(node);
+	}
+	
+	public boolean visit(ListExpression node) {
+		return visitNode(node);
+	}
+	
+	public boolean visit(UndefinedLiteral node) {
+		return visitNode(node);
+	}
+	
+	public boolean visit(WithStatement node) {
+		return visitNode(node);
+	}
+	
+	public boolean visit(ObjectLiteral node) {
+		return visitNode(node);
+	}
+	
+	public boolean visit(ObjectLiteralField node) {
+		return visitNode(node);
+	}
+	
+	public boolean visit(FunctionExpression node) {
+		return visitNode(node);
+	}
 	public void endVisit(AnonymousClassDeclaration node) {
 		endVisitNode(node);
 	}
@@ -590,4 +634,39 @@
 	public void endVisit(TextElement node) {
 		endVisitNode(node);
 	}
+	public void endVisit(RegularExpressionLiteral node) {
+		endVisitNode(node);
+	}
+	
+	public void endVisit(ForInStatement node) {
+		endVisitNode(node);
+	}
+	
+	public void endVisit(InferredType node) {
+		endVisitNode(node);
+	}
+	
+	public void endVisit(ListExpression node) {
+		endVisitNode(node);
+	}
+	
+	public void endVisit(UndefinedLiteral node) {
+		endVisitNode(node);
+	}
+	
+	public void endVisit(WithStatement node) {
+		endVisitNode(node);
+	}
+	
+	public void endVisit(ObjectLiteral node) {
+		endVisitNode(node);
+	}
+	
+	public void endVisit(ObjectLiteralField node) {
+		endVisitNode(node);
+	}
+	
+	public void endVisit(FunctionExpression node) {
+		endVisitNode(node);
+	}
 }

Back to the top