This crazy patch makes the test pass on s390x in groovy: --- a/decode.go +++ b/decode.go @@ -500,7 +500,8 @@ return true } case float64: - if resolved <= math.MaxInt64 && !out.OverflowInt(int64(resolved)) { + is_overflow := out.OverflowInt(int64(resolved)) + if resolved <= math.MaxInt64 && !is_overflow { out.SetInt(int64(resolved)) return true }
This crazy patch makes the test pass on s390x in groovy: t(int64( resolved) ) { (int64( resolved) ) SetInt( int64(resolved) )
--- a/decode.go
+++ b/decode.go
@@ -500,7 +500,8 @@
return true
}
case float64:
- if resolved <= math.MaxInt64 && !out.OverflowIn
+ is_overflow := out.OverflowInt
+ if resolved <= math.MaxInt64 && !is_overflow {
out.
return true
}