Re: [w3c/IndexedDB] Use StructuredSerialize/StructuredDeserialize (#171)

annevk commented on this pull request.



>      Rethrow any exceptions.
 
+    <details class=note>
+      <summary>Why create a copy of the value?</summary>
+      The value must be serialized when stored. Treating it as a copy
+      here allows other algorithms in this specification to treat it as
+      an ECMAScript value, but implementations may optimize this
+      if the difference in behavior is not observable.
+    </details>

This difference can be observable, especially with very large ArrayBuffer objects. With those the initial copy might succeed, but then a later serialization could fail in a naive implementation. That seems somewhat bad.

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/w3c/IndexedDB/pull/171#pullrequestreview-28575587

Received on Thursday, 23 March 2017 06:17:26 UTC