-
-
Notifications
You must be signed in to change notification settings - Fork 84
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
Fix Exception Flow Control - Update Trap Comparison (Issue 1175) #1176
Conversation
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.
lets add a test (input is already pushed) that checks that the correct exceptional successor is linked. for simplicity sth like graph.getBlocks().stream().filter(b -> b.toString().contains("return o")).findFirst().get().getExceptionalSuccessors().values().stream().filter(ehb -> ehb.toString().contains("return 2")).findAny() == true; (beware: its possible the exceptionhandler consists of multiple blocks)
@swissiety I've added the test as you requested. It's not completely generic, but it should suffice. Let me know if you want me to change anything. |
Wow thats a lot of assertions. Thank you for the testcase! |
import java.util.HashMap; | ||
import java.util.Map; | ||
|
||
public class NestedTryCatchFlowTest { |
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.
Please annotate it with the test category tag (see other tests with java8 something something)
Please execute the coveo plugin with the fmt goal to apply the code style before committing |
i think i did. not sure if that's what you wanted |
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.
Good work @A1K28 👍
Closes [Bug]: Incorrect Exception Control Flow Analysis for Nested Try-Catch Blocks (1.3.0) #1175