### Eclipse Workspace Patch 1.0 #P org.eclipse.jdt.core Index: compiler/org/eclipse/jdt/internal/compiler/lookup/Scope.java =================================================================== RCS file: /cvsroot/eclipse/org.eclipse.jdt.core/compiler/org/eclipse/jdt/internal/compiler/lookup/Scope.java,v retrieving revision 1.254 diff -u -r1.254 Scope.java --- compiler/org/eclipse/jdt/internal/compiler/lookup/Scope.java 10 Jan 2006 21:01:07 -0000 1.254 +++ compiler/org/eclipse/jdt/internal/compiler/lookup/Scope.java 19 Jan 2006 22:12:12 -0000 @@ -2786,6 +2786,14 @@ if (context != null && context.isViewedAsDeprecated()) return true; break; + case Scope.COMPILATION_UNIT_SCOPE : + // consider import as being deprecated if first type is itself deprecated (123522) + CompilationUnitDeclaration unit = referenceCompilationUnit(); + if (unit.types != null && unit.types.length > 0) { + SourceTypeBinding type = unit.types[0].binding; + if (type != null && type.isViewedAsDeprecated()) + return true; + } } return false; }