summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
Diffstat (limited to 'test')
-rw-r--r--test/422-type-conversion/src/Main.java4
1 files changed, 4 insertions, 0 deletions
diff --git a/test/422-type-conversion/src/Main.java b/test/422-type-conversion/src/Main.java
index 146f309c81..7754b751ee 100644
--- a/test/422-type-conversion/src/Main.java
+++ b/test/422-type-conversion/src/Main.java
@@ -390,6 +390,8 @@ public class Main {
assertLongEquals(9223372036854775807L, $opt$noinline$FloatToLong(9223372036854775807F)); // 2^63 - 1
assertLongEquals(-9223372036854775808L, $opt$noinline$FloatToLong(-9223372036854775807F)); // -(2^63 - 1)
assertLongEquals(-9223372036854775808L, $opt$noinline$FloatToLong(-9223372036854775808F)); // -(2^63)
+ assertLongEquals(9223371487098961920L, $opt$noinline$FloatToLong(9223371487098961920F)); // Math.nextAfter(2F^63, 0)
+ assertLongEquals(-9223371487098961920L, $opt$noinline$FloatToLong(-9223371487098961920F)); // Math.nextAfter(-2F^63, 0)
assertLongEquals(0L, $opt$noinline$FloatToLong(Float.NaN));
assertLongEquals(9223372036854775807L, $opt$noinline$FloatToLong(Float.POSITIVE_INFINITY));
assertLongEquals(-9223372036854775808L, $opt$noinline$FloatToLong(Float.NEGATIVE_INFINITY));
@@ -469,6 +471,8 @@ public class Main {
assertLongEquals(-9223372036854775808L, $opt$noinline$DoubleToLong(-9223372036854775807D)); // -(2^63 - 1)
assertLongEquals(-9223372036854775808L, $opt$noinline$DoubleToLong(-9223372036854775808D)); // -(2^63)
assertLongEquals(0L, $opt$noinline$DoubleToLong(Double.NaN));
+ assertLongEquals(9223372036854774784L, $opt$noinline$DoubleToLong(9223372036854774784D)); // Math.nextAfter(2D^63, 0)
+ assertLongEquals(-9223372036854774784L, $opt$noinline$DoubleToLong(-9223372036854774784D)); // Math.nextAfter(-2D^63, 0)
assertLongEquals(9223372036854775807L, $opt$noinline$DoubleToLong(Double.POSITIVE_INFINITY));
assertLongEquals(-9223372036854775808L, $opt$noinline$DoubleToLong(Double.NEGATIVE_INFINITY));
}