Project: JDT
Bug 100212 [refactoring] Encapsulate field breaks static import statement.
Reported: 2005-06-15 11:26:39 | Status: verified fixed

To Import.x do Refactor>>EncapsulateField. See the resulting static import statement is illegal. -------------------- bug/Bug.java ---------------------- package bug; import static bug.Import.x; class Bug { int y=x; } -------------------- bug/Import.java ------------------- package bug; class Import { static int x; }

Files changed in fix:
org.eclipse.jdt.ui.tests.refactoring/resources/SefWorkSpace/SefTests/static_in/TestStaticImportNone.java org.eclipse.jdt.ui.tests.refactoring/resources/SefWorkSpace/SefTests/static_in/TestStaticImportRead.java org.eclipse.jdt.ui.tests.refactoring/resources/SefWorkSpace/SefTests/static_in/TestStaticImportReadWrite.java org.eclipse.jdt.ui.tests.refactoring/resources/SefWorkSpace/SefTests/static_in/TestStaticImportWrite.java org.eclipse.jdt.ui.tests.refactoring/resources/SefWorkSpace/SefTests/static_out/TestStaticImportNone.java org.eclipse.jdt.ui.tests.refactoring/resources/SefWorkSpace/SefTests/static_out/TestStaticImportRead.java org.eclipse.jdt.ui.tests.refactoring/resources/SefWorkSpace/SefTests/static_out/TestStaticImportReadWrite.java org.eclipse.jdt.ui.tests.refactoring/resources/SefWorkSpace/SefTests/static_out/TestStaticImportWrite.java org.eclipse.jdt.ui.tests.refactoring/resources/SefWorkSpace/SefTests/static_ref_in/StaticImportNoReference.java org.eclipse.jdt.ui.tests.refactoring/resources/SefWorkSpace/SefTests/static_ref_in/StaticImportReadReference.java org.eclipse.jdt.ui.tests.refactoring/resources/SefWorkSpace/SefTests/static_ref_in/StaticImportReadWriteReference.java org.eclipse.jdt.ui.tests.refactoring/resources/SefWorkSpace/SefTests/static_ref_in/StaticImportWriteReference.java org.eclipse.jdt.ui.tests.refactoring/resources/SefWorkSpace/SefTests/static_ref_out/StaticImportNoReference.java org.eclipse.jdt.ui.tests.refactoring/resources/SefWorkSpace/SefTests/static_ref_out/StaticImportReadReference.java org.eclipse.jdt.ui.tests.refactoring/resources/SefWorkSpace/SefTests/static_ref_out/StaticImportReadWriteReference.java org.eclipse.jdt.ui.tests.refactoring/resources/SefWorkSpace/SefTests/static_ref_out/StaticImportWriteReference.java org.eclipse.jdt.ui.tests.refactoring/test cases/org/eclipse/jdt/ui/tests/refactoring/SefTestSetup.java org.eclipse.jdt.ui.tests.refactoring/test cases/org/eclipse/jdt/ui/tests/refactoring/SefTests.java org.eclipse.jdt.ui/core refactoring/org/eclipse/jdt/internal/corext/refactoring/sef/AccessAnalyzer.java org.eclipse.jdt.ui/core refactoring/org/eclipse/jdt/internal/corext/refactoring/sef/SelfEncapsulateFieldRefactoring.java