-
Notifications
You must be signed in to change notification settings - Fork 273
Make disjuncts in instanceof and virtual method removal stable #2058
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
peterschrammel
merged 3 commits into
diffblue:develop
from
peterschrammel:stable-disjuncts
Apr 16, 2018
Merged
Changes from all commits
Commits
Show all changes
3 commits
Select commit
Hold shift + click to select a range
3afff86
Make disjuncts in virtual method removal independent of class loading
peterschrammel b44589e
Make disjuncts in instanceof removal independent of class loading
peterschrammel 4222a94
Regression tests for unstable instanceof and virtual method disjuncts
peterschrammel File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
Binary file not shown.
This file contains hidden or 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,16 @@ | ||
class A { | ||
} | ||
|
||
class B extends A { | ||
} | ||
|
||
public class Test { | ||
|
||
public boolean foo(A x) { | ||
if (x instanceof A) { | ||
return true; | ||
} else { | ||
return false; | ||
} | ||
} | ||
} |
Binary file not shown.
This file contains hidden or 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,22 @@ | ||
/* | ||
old.jar needs to be created by first adding B.class and Test.class and then | ||
updated to add A.class. This makes the class loader load the classes A and B | ||
in reverse order. | ||
*/ | ||
|
||
class A { | ||
} | ||
|
||
class B extends A { | ||
} | ||
|
||
public class Test { | ||
|
||
public boolean foo(A x) { | ||
if (x instanceof A) { | ||
return true; | ||
} else { | ||
return false; | ||
} | ||
} | ||
} |
This file contains hidden or 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,10 @@ | ||
CORE | ||
new.jar | ||
old.jar | ||
// Enable multi-line checking | ||
activate-multi-line-match | ||
EXIT=0 | ||
SIGNAL=0 | ||
new functions:\nmodified functions:\ndeleted functions: | ||
-- | ||
^warning: ignoring |
Binary file not shown.
This file contains hidden or 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,18 @@ | ||
class A { | ||
boolean bar() { | ||
return true; | ||
} | ||
} | ||
|
||
class B extends A { | ||
boolean bar() { | ||
return false; | ||
} | ||
} | ||
|
||
public class Test { | ||
|
||
public boolean foo(A x) { | ||
return x.bar(); | ||
} | ||
} |
Binary file not shown.
This file contains hidden or 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,24 @@ | ||
/* | ||
old.jar needs to be created by first adding B.class and Test.class and then | ||
updated to add A.class. This makes the class loader load the classes A and B | ||
in reverse order. | ||
*/ | ||
|
||
class A { | ||
boolean bar() { | ||
return true; | ||
} | ||
} | ||
|
||
class B extends A { | ||
boolean bar() { | ||
return false; | ||
} | ||
} | ||
|
||
public class Test { | ||
|
||
public boolean foo(A x) { | ||
return x.bar(); | ||
} | ||
} |
This file contains hidden or 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,10 @@ | ||
CORE | ||
new.jar | ||
old.jar | ||
// Enable multi-line checking | ||
activate-multi-line-match | ||
EXIT=0 | ||
SIGNAL=0 | ||
new functions:\nmodified functions:\ndeleted functions: | ||
-- | ||
^warning: ignoring |
This file contains hidden or 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 hidden or 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
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
So if the function names are equal then sort by class names? Don't the function names include the class names though?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
class_id
is the name of the class, whereassymbol_expr
is the name of the target method to call (which might be defined in a parent class). We are sorting by target method and if the same target method is used by several classes (these generate the big or expression in the dispatch condition) then we sort by these classes.