aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorzzhongwei2012-11-05 23:18:26 (EST)
committerzzhongwei2012-11-05 23:32:27 (EST)
commitd7a859fe75b15a93b820fcf404b8f48e23395f23 (patch)
treeaf4febf41c4384bd8907d107902a24e51dc06830
parentca764f841740732188c817d0b562e3622eddb862 (diff)
downloadorg.eclipse.pdt-d7a859fe75b15a93b820fcf404b8f48e23395f23.zip
org.eclipse.pdt-d7a859fe75b15a93b820fcf404b8f48e23395f23.tar.gz
org.eclipse.pdt-d7a859fe75b15a93b820fcf404b8f48e23395f23.tar.bz2
fix test failures
-rw-r--r--plugins/org.eclipse.php.core/src/org/eclipse/php/internal/core/ast/rewrite/ASTRewriteAnalyzer.java3
1 files changed, 2 insertions, 1 deletions
diff --git a/plugins/org.eclipse.php.core/src/org/eclipse/php/internal/core/ast/rewrite/ASTRewriteAnalyzer.java b/plugins/org.eclipse.php.core/src/org/eclipse/php/internal/core/ast/rewrite/ASTRewriteAnalyzer.java
index d2b6c2f..f332135 100644
--- a/plugins/org.eclipse.php.core/src/org/eclipse/php/internal/core/ast/rewrite/ASTRewriteAnalyzer.java
+++ b/plugins/org.eclipse.php.core/src/org/eclipse/php/internal/core/ast/rewrite/ASTRewriteAnalyzer.java
@@ -465,7 +465,8 @@ public final class ASTRewriteAnalyzer extends AbstractVisitor {
protected int getStartOfNextNode(int nextIndex, int defaultPos) {
// workaround for bug 393253
- if (nextIndex > 0
+ if (isInsertUseStatement
+ && nextIndex > 0
&& this.list[nextIndex].getChangeKind() == RewriteEvent.INSERTED
&& this.list[nextIndex - 1].getChangeKind() == RewriteEvent.UNCHANGED
&& this.list[nextIndex].getNewValue() instanceof UseStatement