JDK-6996626 : Scope fix issues for ImportScope
  • Type: Bug
  • Component: tools
  • Sub-Component: javac
  • Affected Version: 7
  • Priority: P1
  • Status: Closed
  • Resolution: Fixed
  • OS: generic
  • CPU: generic
  • Submitted: 2010-11-01
  • Updated: 2011-05-18
  • Resolved: 2011-05-18
The Version table provides details related to the release that this issue/RFE will be addressed.

Unresolved : Release in which this issue/RFE will be addressed.
Resolved: Release in which this issue/RFE has been resolved.
Fixed : Release in which this issue/RFE has been fixed. The release containing this fix may be available for download as an Early Access Release or a General Availability Release.

To download the current JDK release, click here.
JDK 7
7 b118Fixed
Related Reports
Relates :  
Relates :  
Relates :  
Relates :  
Description
The recent Scope fix for 6460352 has uncovered some issues with ImportScope.

Test case -- compile langtools, touch javac.main.JavaCompiler, compile langtools again. See the errors.

Comments
EVALUATION http://hg.openjdk.java.net/jdk7/build/langtools/rev/6ce6ee1b831a
04-12-2010

EVALUATION Reverted fix for 6460352 for now. :-(
02-11-2010

EVALUATION Problem caused by the way symbols for nested classes are handled from class files. Initially, they are entered as top level classes in the package. When they are attributed and found to be nested classes, the entry is removed from the package scope and re-entered in the correct class scope. But, in the meantime the symbol may have been imported, and now in an import scope. The entry under the original name is *not* removed from the import scope, and so may still be visible. Worse, if the nested classes are themselves imported, the symbol may now be in the import scope twice, two entries for the same symbol, hashed under different names. If the table is resized, the old entry conflicts with the new entry.
01-11-2010