Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 230361

Summary: [refactoring] Move Class changes behaviour in presence of overloading
Product: [Eclipse Project] JDT Reporter: Friedrich Steimann <steimann>
Component: UIAssignee: JDT-UI-Inbox <jdt-ui-inbox>
Status: CLOSED WONTFIX QA Contact:
Severity: normal    
Priority: P3 CC: markus.kell.r, martinae
Version: 3.3.1   
Target Milestone: ---   
Hardware: PC   
OS: Windows XP   
Whiteboard: stalebug

Description Friedrich Steimann CLA 2008-05-06 06:20:05 EDT
The semantics of the following trivial program is changed by moving either A or B to another package:

package a;

public class A {
	public void m(Object o) {System.out.println("o");}
	void m(String s) {System.out.println("s");}
}

package a;

public class B {
	public static void main(String[] a) {
		(new A()).m("abc");
	}
}

Is anyone working on visibility constraints (analogous to type constraints)? This could also answer the question whether visibility of m(Object) could be increased without changing behaviour.

-- Friedrich
Comment 1 Martin Aeschlimann CLA 2008-05-06 09:43:37 EDT
Markus, can you comment?
Comment 2 Eclipse Genie CLA 2019-11-05 11:37:30 EST
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.