-
Notifications
You must be signed in to change notification settings - Fork 95
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Warn about a pull up method overriding calls to super class method (#…
…1682) - add logic ot PullUpRefactoringProcessor to check if pulling up a method may override existing calls to a super class method of the same name and change program semantics - add new test to PullUpTests - fixes #1677
- Loading branch information
Showing
4 changed files
with
68 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
19 changes: 19 additions & 0 deletions
19
org.eclipse.jdt.ui.tests.refactoring/resources/PullUp/testFail35/in/A.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
package p; | ||
|
||
class A { | ||
void method() { | ||
System.out.println("ParentClass method"); | ||
} | ||
} | ||
|
||
class B extends SubClass { | ||
void method() { | ||
System.out.println("Class B method"); | ||
} | ||
} | ||
|
||
class SubClass extends A { | ||
void test() { | ||
method(); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters