8081813: JSONListAdapter should delegate its [[DefaultValue]] to wrapped object
Reviewed-by: lagergren, sundar
--- a/nashorn/src/jdk.scripting.nashorn/share/classes/jdk/nashorn/internal/runtime/JSONListAdapter.java Wed Jun 03 18:44:12 2015 +0530
+++ b/nashorn/src/jdk.scripting.nashorn/share/classes/jdk/nashorn/internal/runtime/JSONListAdapter.java Wed Jun 03 16:28:57 2015 +0200
@@ -148,4 +148,14 @@
public boolean isArray() {
return obj.isArray();
}
+
+ @Override @Deprecated
+ public double toNumber() {
+ return obj.toNumber();
+ }
+
+ @Override
+ public Object getDefaultValue(Class<?> hint) throws UnsupportedOperationException {
+ return obj.getDefaultValue(hint);
+ }
}