SerializedScriptValue isn't aware of indexed storage, but should be
https://bugs.webkit.org/show_bug.cgi?id=97515
<rdar://problem/12361874>

Reviewed by Sam Weinig.

Source/JavaScriptCore: 

Export a method that WebCore now uses.

* JavaScriptCore.vcproj/JavaScriptCore/JavaScriptCore.def:
* runtime/JSObject.h:
(JSObject):

Source/WebCore: 

New test: fast/js/post-message-numeric-property.html

* bindings/js/SerializedScriptValue.cpp:
(WebCore::CloneDeserializer::putProperty):

LayoutTests: 

* fast/js/post-message-numeric-property-expected.txt: Added.
* fast/js/post-message-numeric-property.html: Added.
* fast/js/script-tests/post-message-numeric-property.js: Added.
(window.onmessage):



git-svn-id: http://svn.webkit.org/repository/webkit/trunk@129457 268f45cc-cd09-0410-ab3c-d52691b4dbfc
diff --git a/Source/WebCore/bindings/js/SerializedScriptValue.cpp b/Source/WebCore/bindings/js/SerializedScriptValue.cpp
index 6ae5e38..02f8cff 100644
--- a/Source/WebCore/bindings/js/SerializedScriptValue.cpp
+++ b/Source/WebCore/bindings/js/SerializedScriptValue.cpp
@@ -1320,7 +1320,7 @@
 
     void putProperty(JSObject* object, const Identifier& property, JSValue value)
     {
-        object->putDirect(m_exec->globalData(), property, value);
+        object->putDirectMayBeIndex(m_exec, property, value);
     }
 
     bool readFile(RefPtr<File>& file)