-
Notifications
You must be signed in to change notification settings - Fork 1.7k
Java: Support Argument[this] and parameters of bodiless interface methods in framework mode metadata extraction #13823
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
Java: Support Argument[this] and parameters of bodiless interface methods in framework mode metadata extraction #13823
Conversation
f56aff4
to
b5862ae
Compare
…, so we can support both Argument[this] and interface-method parameters
b5862ae
to
8ed773b
Compare
@atorralba — the one integration test that passed was a fluke, I think (I restarted it). With that, the PR is ready for review. Are you able to do that? You've seen most of the implementation already. Thank you for your help, and also thanks to @aschackmull for the valuable input! |
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.
As discussed, LGTM :)
In PR #13823, we had rewritten the endpoints that are being considered for framework mode. We used to use `DataFlow::ParameterNode` as endpoints. However, `ParameterNode`s do not exist for the implicit `this` parameter; they also do not exist for bodiless interface-methods. In PR #13823, we forgot to model that `this` only exists for non-static methods and to only consider parameters that we have source code for.
In PR #13823, we had rewritten the endpoints that are being considered for framework mode. We used to use `DataFlow::ParameterNode` as endpoints. However, `ParameterNode`s do not exist for the implicit `this` parameter; they also do not exist for bodiless interface-methods. In PR #13823, we forgot to model that `this` only exists for non-static methods and to only consider parameters that we have source code for.
ExplicitParameterNode
s in framework mode, but skipped thethis
parameter. This PR fixes the problem. I'll add a test case to the currently open test PR once this is merged.DataFlow::ParameterNode
types local to the automodel code (if needed).