Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 320231 - [rename] rename package with subpackes needs organize imports
Summary: [rename] rename package with subpackes needs organize imports
Status: RESOLVED WORKSFORME
Alias: None
Product: JDT
Classification: Eclipse Project
Component: UI (show other bugs)
Version: 3.7   Edit
Hardware: PC Windows XP
: P3 normal (vote)
Target Milestone: ---   Edit
Assignee: JDT-UI-Inbox CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2010-07-19 05:10 EDT by Sebastian Dietrich CLA
Modified: 2010-07-28 09:04 EDT (History)
1 user (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Sebastian Dietrich CLA 2010-07-19 05:10:15 EDT
Build Identifier: 20100218-1602

I have a package that is the root of a package structure. When I rename the package and select "include subpackages", some imports in classes of my package structure still point to the old package names and thus result in a compile error. Organize imports on the whole package structure helps.

Reproducible: Always

Steps to Reproduce:
1. create a package structure with subpackages
2. create some classes that import classes from other subpackes in the package structure
3. rename the root package
4. some imports still reference the old package names

Workaround: use "organize imports" on the whole package structure after renaming it.
Comment 1 Dani Megert CLA 2010-07-28 09:04:35 EDT
This works fine fore me. Make sure to check the 'Rename subpackagse' option in the rename dialog.

If you still see the problem using
http://download.eclipse.org/eclipse/downloads/drops/R-3.6-201006080911/index.php
then please provide detailed steps and reopen this bug.