Details
-
Bug
-
Resolution: Fixed
-
P4
-
None
-
None
-
b93
-
Verified
Description
the following expressions all evaluate to NaN:
+[]
+[1]
+[1,2,3]
They should evaluate to 0, 1, NaN respectively.
It looks like somewhere the array literal node is replaced with a NaN constant as the generated bytecode always looks like this:
LDC NaN
INVOKESTATIC java/lang/Double.valueOf (D)Ljava/lang/Double;
+[]
+[1]
+[1,2,3]
They should evaluate to 0, 1, NaN respectively.
It looks like somewhere the array literal node is replaced with a NaN constant as the generated bytecode always looks like this:
LDC NaN
INVOKESTATIC java/lang/Double.valueOf (D)Ljava/lang/Double;
Attachments
Issue Links
- relates to
-
JDK-8012092 Add tests for JavaScript WATs/WTFs
- Closed