-
Enhancement
-
Resolution: Fixed
-
P3
-
8
-
None
-
b105
-
generic
-
generic
An upcoming change to Nashorn JDK-8022903 will change the type of indices returned from a for-in iteration over a Java array from String to Integer, e.g. if "a" is a Java array object with at least element, then
for(var i in a) { print(typeof i); break; }
will now print "number" instead of "string". While it is highly unlikely this change will break anything, it is nevertheless an externally visible change, so all .js files in the JDK should be assessed for impact and necessary changes made.
for(var i in a) { print(typeof i); break; }
will now print "number" instead of "string". While it is highly unlikely this change will break anything, it is nevertheless an externally visible change, so all .js files in the JDK should be assessed for impact and necessary changes made.
- blocks
-
JDK-8022903 Enhance for-in and for-each for Lists and Maps
- Resolved