snuyanzin commented on code in PR #29026:
URL: https://github.com/apache/flink/pull/29026#discussion_r3894127506
##########
flink-core/src/main/java/org/apache/flink/types/variant/BinaryVariantInternalBuilder.java:
##########
@@ -621,25 +676,27 @@ private int getIntegerSize(int value) {
return U24_SIZE;
}
- private void parseFloatingPoint(JsonParser parser) throws IOException {
- if (!tryParseDecimal(parser.getText())) {
- final double d = parser.getDoubleValue();
- // Jackson coerces out-of-range numbers like 1e400 to +/-Infinity.
Reject them instead
- // of storing a non-finite double that toJson() could not render
as valid JSON.
- if (Double.isInfinite(d) || Double.isNaN(d)) {
- throw new JsonParseException(
- parser,
+ private void appendFloatingPoint(JsonTokenSource source, String text)
throws IOException {
+ if (!tryParseDecimal(text)) {
+ final double d = Double.parseDouble(text);
+ // Out-of-range numbers like 1e400 parse to +/-Infinity. Reject
them instead of storing
Review Comment:
how `+Infinity` will come here if `tryParseDecimal` allows only `-` and not
`+`?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]