Skip to content
  • oliver@apple.com's avatar
    Support structured clone of Map and Set · 901740c2
    oliver@apple.com authored
    https://bugs.webkit.org/show_bug.cgi?id=120654
    
    Reviewed by Simon Fraser.
    
    Source/JavaScriptCore:
    
    Make xcode copy the required headers, and add appropriate export attributes
    
    * JavaScriptCore.xcodeproj/project.pbxproj:
    * runtime/JSMap.h:
    * runtime/JSSet.h:
    * runtime/MapData.h:
    
    Source/WebCore:
    
    Add support for cloning Map and Set.  Fairly self explanatory change.
    Needed to add Forwarding headers for the JSMap, JSSet and MapData classes.
    
    * ForwardingHeaders/runtime/JSMap.h: Added.
    * ForwardingHeaders/runtime/JSSet.h: Added.
    * ForwardingHeaders/runtime/MapData.h: Added.
    * bindings/js/SerializedScriptValue.cpp:
    (WebCore::CloneSerializer::isMap):
    (WebCore::CloneSerializer::isSet):
    (WebCore::CloneSerializer::startSet):
    (WebCore::CloneSerializer::startMap):
    (WebCore::CloneSerializer::serialize):
    (WebCore::CloneDeserializer::consumeMapDataTerminationIfPossible):
    (WebCore::CloneDeserializer::deserialize):
    
    LayoutTests:
    
    Tests!
    
    * fast/dom/Window/script-tests/postmessage-clone.js:
    (set new):
    (set add.set add):
    
    git-svn-id: http://svn.webkit.org/repository/webkit/trunk@155008 268f45cc-cd09-0410-ab3c-d52691b4dbfc
    901740c2