Ensure non-Double types are boxed in expression function calls. Fixes #2315

This commit is contained in:
Madeline Miller 2023-05-21 15:02:59 +10:00
parent abc8c1f256
commit 237ebc1016
No known key found for this signature in database
GPG Key ID: B8EA2E5693115D81

View File

@ -72,6 +72,7 @@ private static MethodHandle clean(MethodHandle handle) {
"Function does not return a number");
handle = handle.asType(handle.type().changeReturnType(Number.class));
handle = filterReturnValue(handle, DOUBLE_VALUE);
handle = handle.asType(handle.type().wrap());
}
// return vararg-ity
if (wasVarargs) {