Fix #1371992: Error with switch when last case block omits break or return
[phpeclipse.git] / net.sourceforge.phpeclipse / src / net / sourceforge / phpdt / internal / compiler / lookup / LookupEnvironment.java
index c2be8ee..54e6de2 100644 (file)
@@ -11,6 +11,7 @@
 package net.sourceforge.phpdt.internal.compiler.lookup;
 
 import net.sourceforge.phpdt.core.compiler.CharOperation;
+import net.sourceforge.phpdt.internal.compiler.ast.CompilationUnitDeclaration;
 import net.sourceforge.phpdt.internal.compiler.env.IBinaryType;
 import net.sourceforge.phpdt.internal.compiler.env.INameEnvironment;
 import net.sourceforge.phpdt.internal.compiler.env.NameEnvironmentAnswer;
@@ -18,7 +19,6 @@ import net.sourceforge.phpdt.internal.compiler.impl.ITypeRequestor;
 import net.sourceforge.phpdt.internal.compiler.problem.ProblemReporter;
 import net.sourceforge.phpdt.internal.compiler.util.HashtableOfPackage;
 import net.sourceforge.phpdt.internal.compiler.util.Util;
-import net.sourceforge.phpeclipse.internal.compiler.ast.CompilationUnitDeclaration;
 
 public class LookupEnvironment implements BaseTypes, ProblemReasons, TypeConstants {
 //     public CompilerOptions options;
@@ -217,12 +217,13 @@ public void completeTypeBindings(CompilationUnitDeclaration parsedUnit) {
 public void completeTypeBindings(CompilationUnitDeclaration parsedUnit, boolean buildFieldsAndMethods) {
        if (parsedUnit.scope == null) return; // parsing errors were too severe
 
-//     parsedUnit.scope.checkAndSetImports();
+       parsedUnit.scope.checkAndSetImports();
        parsedUnit.scope.connectTypeHierarchy();
 
        if (buildFieldsAndMethods)
                parsedUnit.scope.buildFieldsAndMethods();
 }
+
 private PackageBinding computePackageFrom(char[][] constantPoolName) {
        if (constantPoolName.length == 1)
                return defaultPackage;