Bug 360945 - [nls tooling] Externalize strings wizard does not update all references
Summary: [nls tooling] Externalize strings wizard does not update all references
Status: ASSIGNED
Alias: None
Product: JDT
Classification: Eclipse Project
Component: Text (show other bugs)
Version: 3.8   Edit
Hardware: All All
: P3 normal (vote)
Target Milestone: ---   Edit
Assignee: JDT-Text-Inbox CLA
QA Contact:
URL:
Whiteboard: stalebug
Keywords:
Depends on:
Blocks:
 
Reported: 2011-10-14 07:15 EDT by Deepak Azad CLA
Modified: 2023-06-02 19:29 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 Deepak Azad CLA 2011-10-14 07:15:09 EDT
- Have 2 classes which use the same NLSed strings. e.g.
--------------------------------------------------------
public class A {
	void foo() {
		String s= Messages.A_0;
		String t= Messages.A_0;
		String u= Messages.A_1;
	}
}

public class B {
	void foo() {
		String s= Messages.A_0;
		String t= Messages.A_0;
		String u= Messages.A_1;
	}
}
--------------------------------------------------------

- Select 'A' in PE
- Source -> Externalize strings
- Internalize A_0 and A_1
=> Class B is not updated resulting in compile errors

- Select 'A' in PE
- Source -> Externalize strings
- Edit the names of the 2 keys A_0 and A_1
=> Class B is not updated resulting in compile errors

At least the user needs to be warned that the refactoring will result in compile errors.
Comment 1 Dani Megert CLA 2011-10-24 04:51:21 EDT
The wizard currently only works in the scope of the given CU.

> At least the user needs to be warned that the refactoring will result in
> compile errors.
If we add code to detect this then we should ask the user whether to internalize all occurrences or not.
Comment 2 Eclipse Genie CLA 2019-06-01 17:56:55 EDT
This bug hasn't had any activity in quite some time. Maybe the problem got resolved, was a duplicate of something else, or became less pressing for some reason - or maybe it's still relevant but just hasn't been looked at yet.

If you have further information on the current state of the bug, please add it. The information can be, for example, that the problem still occurs, that you still want the feature, that more information is needed, or that the bug is (for whatever reason) no longer relevant.

--
The automated Eclipse Genie.
Comment 3 Eclipse Genie CLA 2021-05-24 01:53:14 EDT
This bug hasn't had any activity in quite some time. Maybe the problem got resolved, was a duplicate of something else, or became less pressing for some reason - or maybe it's still relevant but just hasn't been looked at yet.

If you have further information on the current state of the bug, please add it. The information can be, for example, that the problem still occurs, that you still want the feature, that more information is needed, or that the bug is (for whatever reason) no longer relevant.

--
The automated Eclipse Genie.
Comment 4 Eclipse Genie CLA 2023-06-02 19:29:41 EDT
This bug hasn't had any activity in quite some time. Maybe the problem got resolved, was a duplicate of something else, or became less pressing for some reason - or maybe it's still relevant but just hasn't been looked at yet.

If you have further information on the current state of the bug, please add it. The information can be, for example, that the problem still occurs, that you still want the feature, that more information is needed, or that the bug is (for whatever reason) no longer relevant.

--
The automated Eclipse Genie.