-
Notifications
You must be signed in to change notification settings - Fork 1.6k
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
[GR-47449] Verify return types of substituted methods #7340
[GR-47449] Verify return types of substituted methods #7340
Conversation
@@ -375,6 +375,7 @@ def extra_image_build_argument(self, benchmark, args): | |||
'-H:+AllowFoldMethods', | |||
'-H:-UseServiceLoaderFeature', | |||
'-H:+AllowDeprecatedBuilderClassesOnImageClasspath', # needs to be removed once GR-41746 is fixed | |||
'-H:+DisableSubstitutionReturnTypeCheck', # remove once Quarkus fixed their substitutions (GR-48152) |
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.
@zakkak I had to add this for our Quarkus jobs because in the (quite old) version we are using there were substitutions with return type mismatches. The offending substitution seems to be gone on master, but I have not checked all the others. Maybe things are fine, maybe not. Just a heads up. :)
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.
Hi @zapster, thanks for the heads up.
It looks like there are some failures on Quarkus main
as well which I am working on in quarkusio/quarkus#35847 and quarkusio/quarkus#35956
fa39f59
to
bcf1261
Compare
Resolves issues with new strict checking introduced with oracle/graal#7340
Resolves issues with new strict checking introduced with oracle/graal#7340
Resolves issues with new strict checking introduced with oracle/graal#7340
Resolves issues with new strict checking introduced with oracle/graal#7340
The return types of substitution methods must match the return type of the target method. Incompatible types can lead to failures in the compiled code, e.g., unexpected
NullPointerException
, which are hard to debug. Note that none of the changed substitutions suffered from these problems because although there were mismatches, the specified types were usually a super type of the target return types (e.g.Object
instead of the concrete type). Still, this verification helps catching problems in new substitutions early.