import java.util.ArrayList;
+import net.sourceforge.phpdt.internal.compiler.ast.ASTNode;
import net.sourceforge.phpdt.internal.compiler.codegen.ObjectCache;
import net.sourceforge.phpdt.internal.compiler.lookup.BlockScope;
import net.sourceforge.phpdt.internal.compiler.lookup.ReferenceBinding;
import net.sourceforge.phpdt.internal.compiler.lookup.Scope;
import net.sourceforge.phpdt.internal.compiler.lookup.TypeBinding;
-import net.sourceforge.phpeclipse.internal.compiler.ast.ASTNode;
-import net.sourceforge.phpeclipse.internal.compiler.ast.TryStatement;
/**
* Reflects the context of code analysis, keeping track of enclosing
System.arraycopy(this.isReached, 0, this.isNeeded, 0, cacheSize);
this.initsOnReturn = FlowInfo.DEAD_END;
}
-
- public void complainIfUnusedExceptionHandlers(
- ASTNode[] exceptionHandlers,
- BlockScope scope,
- TryStatement tryStatement) {
- // report errors for unreachable exception handlers
- for (int i = 0, count = handledExceptions.length; i < count; i++) {
- int index = indexes.get(handledExceptions[i]);
- int cacheIndex = index / BitCacheSize;
- int bitMask = 1 << (index % BitCacheSize);
- if ((isReached[cacheIndex] & bitMask) == 0) {
- scope.problemReporter().unreachableExceptionHandler(
- handledExceptions[index],
- exceptionHandlers[index]);
- } else {
- if ((isNeeded[cacheIndex] & bitMask) == 0) {
- scope.problemReporter().maskedExceptionHandler(
- handledExceptions[index],
- exceptionHandlers[index]);
- }
- }
- }
- // will optimized out unnecessary catch block during code gen
- tryStatement.preserveExceptionHandler = isNeeded;
- }
+
+
+// public void complainIfUnusedExceptionHandlers(
+// ASTNode[] exceptionHandlers,
+// BlockScope scope,
+// TryStatement tryStatement) {
+// // report errors for unreachable exception handlers
+// for (int i = 0, count = handledExceptions.length; i < count; i++) {
+// int index = indexes.get(handledExceptions[i]);
+// int cacheIndex = index / BitCacheSize;
+// int bitMask = 1 << (index % BitCacheSize);
+// if ((isReached[cacheIndex] & bitMask) == 0) {
+// scope.problemReporter().unreachableExceptionHandler(
+// handledExceptions[index],
+// exceptionHandlers[index]);
+// } else {
+// if ((isNeeded[cacheIndex] & bitMask) == 0) {
+// scope.problemReporter().maskedExceptionHandler(
+// handledExceptions[index],
+// exceptionHandlers[index]);
+// }
+// }
+// }
+// // will optimized out unnecessary catch block during code gen
+// tryStatement.preserveExceptionHandler = isNeeded;
+// }
public String individualToString() {