<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN"
"http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head><meta http-equiv="content-type" content="text/html; charset=utf-8" />
<title>[209184] trunk</title>
</head>
<body>

<style type="text/css"><!--
#msg dl.meta { border: 1px #006 solid; background: #369; padding: 6px; color: #fff; }
#msg dl.meta dt { float: left; width: 6em; font-weight: bold; }
#msg dt:after { content:':';}
#msg dl, #msg dt, #msg ul, #msg li, #header, #footer, #logmsg { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt;  }
#msg dl a { font-weight: bold}
#msg dl a:link    { color:#fc3; }
#msg dl a:active  { color:#ff0; }
#msg dl a:visited { color:#cc6; }
h3 { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt; font-weight: bold; }
#msg pre { overflow: auto; background: #ffc; border: 1px #fa0 solid; padding: 6px; }
#logmsg { background: #ffc; border: 1px #fa0 solid; padding: 1em 1em 0 1em; }
#logmsg p, #logmsg pre, #logmsg blockquote { margin: 0 0 1em 0; }
#logmsg p, #logmsg li, #logmsg dt, #logmsg dd { line-height: 14pt; }
#logmsg h1, #logmsg h2, #logmsg h3, #logmsg h4, #logmsg h5, #logmsg h6 { margin: .5em 0; }
#logmsg h1:first-child, #logmsg h2:first-child, #logmsg h3:first-child, #logmsg h4:first-child, #logmsg h5:first-child, #logmsg h6:first-child { margin-top: 0; }
#logmsg ul, #logmsg ol { padding: 0; list-style-position: inside; margin: 0 0 0 1em; }
#logmsg ul { text-indent: -1em; padding-left: 1em; }#logmsg ol { text-indent: -1.5em; padding-left: 1.5em; }
#logmsg > ul, #logmsg > ol { margin: 0 0 1em 0; }
#logmsg pre { background: #eee; padding: 1em; }
#logmsg blockquote { border: 1px solid #fa0; border-left-width: 10px; padding: 1em 1em 0 1em; background: white;}
#logmsg dl { margin: 0; }
#logmsg dt { font-weight: bold; }
#logmsg dd { margin: 0; padding: 0 0 0.5em 0; }
#logmsg dd:before { content:'\00bb';}
#logmsg table { border-spacing: 0px; border-collapse: collapse; border-top: 4px solid #fa0; border-bottom: 1px solid #fa0; background: #fff; }
#logmsg table th { text-align: left; font-weight: normal; padding: 0.2em 0.5em; border-top: 1px dotted #fa0; }
#logmsg table td { text-align: right; border-top: 1px dotted #fa0; padding: 0.2em 0.5em; }
#logmsg table thead th { text-align: center; border-bottom: 1px solid #fa0; }
#logmsg table th.Corner { text-align: left; }
#logmsg hr { border: none 0; border-top: 2px dashed #fa0; height: 1px; }
#header, #footer { color: #fff; background: #636; border: 1px #300 solid; padding: 6px; }
#patch { width: 100%; }
#patch h4 {font-family: verdana,arial,helvetica,sans-serif;font-size:10pt;padding:8px;background:#369;color:#fff;margin:0;}
#patch .propset h4, #patch .binary h4 {margin:0;}
#patch pre {padding:0;line-height:1.2em;margin:0;}
#patch .diff {width:100%;background:#eee;padding: 0 0 10px 0;overflow:auto;}
#patch .propset .diff, #patch .binary .diff  {padding:10px 0;}
#patch span {display:block;padding:0 10px;}
#patch .modfile, #patch .addfile, #patch .delfile, #patch .propset, #patch .binary, #patch .copfile {border:1px solid #ccc;margin:10px 0;}
#patch ins {background:#dfd;text-decoration:none;display:block;padding:0 10px;}
#patch del {background:#fdd;text-decoration:none;display:block;padding:0 10px;}
#patch .lines, .info {color:#888;background:#fff;}
--></style>
<div id="msg">
<dl class="meta">
<dt>Revision</dt> <dd><a href="http://trac.webkit.org/projects/webkit/changeset/209184">209184</a></dd>
<dt>Author</dt> <dd>weinig@apple.com</dd>
<dt>Date</dt> <dd>2016-12-01 10:04:58 -0800 (Thu, 01 Dec 2016)</dd>
</dl>

<h3>Log Message</h3>
<pre>[WebIDL] Remove custom bindings for File and Blob constructors
https://bugs.webkit.org/show_bug.cgi?id=165218

Reviewed by Darin Adler.

LayoutTests/imported/w3c:

* web-platform-tests/fetch/api/basic/request-headers-expected.txt:
* web-platform-tests/fetch/api/basic/request-headers-worker-expected.txt:
Update results (still failing) to account for stricter rules about dictionary default values.

Source/WebCore:

* CMakeLists.txt:
* DerivedSources.make:
* WebCore.xcodeproj/project.pbxproj:
Add/remove new files.

* bindings/js/JSBlobCustom.cpp:
(WebCore::constructJSBlob): Deleted.
* bindings/js/JSFileCustom.cpp: Removed.
Remove custom constructors.

* bindings/scripts/CodeGeneratorJS.pm:
(GenerateDefaultValue):
(GenerateDictionaryImplementationContent):
(GenerateParametersCheck):
Add support for optional sequences without default values. Move string default value
optimizations into GenerateDefaultValue.

* fileapi/Blob.cpp:
(WebCore::Blob::Blob):
* fileapi/Blob.h:
(WebCore::Blob::create):
* fileapi/Blob.idl:
* fileapi/File.cpp:
(WebCore::File::File):
* fileapi/File.h:
* fileapi/File.idl:
Add support for the generated constructors.

* fileapi/BlobBuilder.cpp: Copied from Source/WebCore/fileapi/WebKitBlobBuilder.cpp.
* fileapi/BlobBuilder.h: Copied from Source/WebCore/fileapi/WebKitBlobBuilder.h.
* fileapi/WebKitBlobBuilder.cpp: Removed.
* fileapi/WebKitBlobBuilder.h: Removed.
Rename WebKitBlobBuilder to BlobBuilder, and update to work with generated constructor.

* fileapi/BlobPropertyBag.h: Added.
* fileapi/BlobPropertyBag.idl: Added.
Added.

* fileapi/ThreadableBlobRegistry.cpp:
(WebCore::ThreadableBlobRegistry::registerBlobURL):
* fileapi/ThreadableBlobRegistry.h:
* platform/network/BlobRegistry.h:
* platform/network/BlobRegistryImpl.cpp:
(WebCore::BlobRegistryImpl::registerBlobURL):
* platform/network/BlobRegistryImpl.h:
Avoid copies of the BlobPart Vector.

* platform/network/BlobPart.h:
Replace header-guards with #pragma once.

Source/WebKit2:

* NetworkProcess/FileAPI/NetworkBlobRegistry.cpp:
(WebKit::NetworkBlobRegistry::registerBlobURL):
* NetworkProcess/FileAPI/NetworkBlobRegistry.h:
* NetworkProcess/NetworkConnectionToWebProcess.cpp:
(WebKit::NetworkConnectionToWebProcess::registerBlobURL):
* NetworkProcess/NetworkConnectionToWebProcess.h:
* WebProcess/FileAPI/BlobRegistryProxy.cpp:
(WebKit::BlobRegistryProxy::registerBlobURL):
* WebProcess/FileAPI/BlobRegistryProxy.h:
Avoid copies of the BlobPart Vector.

LayoutTests:

* fast/files/blob-constructor-expected.txt:
* fast/files/file-constructor-expected.txt:
* fast/files/file-constructor.html:
* fast/files/script-tests/blob-constructor.js:
Update for stricter parsing and changed error text. (The error text
is regressed, but consistent with all generated bindings. I will work
on making improvements on this soon.)

* http/tests/fetch/fetch-as-blob.js:
Update to account for stricter rules about dictionary default values.</pre>

<h3>Modified Paths</h3>
<ul>
<li><a href="#trunkLayoutTestsChangeLog">trunk/LayoutTests/ChangeLog</a></li>
<li><a href="#trunkLayoutTestsfastfilesblobconstructorexpectedtxt">trunk/LayoutTests/fast/files/blob-constructor-expected.txt</a></li>
<li><a href="#trunkLayoutTestsfastfilesfileconstructorexpectedtxt">trunk/LayoutTests/fast/files/file-constructor-expected.txt</a></li>
<li><a href="#trunkLayoutTestsfastfilesfileconstructorhtml">trunk/LayoutTests/fast/files/file-constructor.html</a></li>
<li><a href="#trunkLayoutTestsfastfilesscripttestsblobconstructorjs">trunk/LayoutTests/fast/files/script-tests/blob-constructor.js</a></li>
<li><a href="#trunkLayoutTestshttptestsfetchfetchasblobjs">trunk/LayoutTests/http/tests/fetch/fetch-as-blob.js</a></li>
<li><a href="#trunkLayoutTestsimportedw3cChangeLog">trunk/LayoutTests/imported/w3c/ChangeLog</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfetchapibasicrequestheadersexpectedtxt">trunk/LayoutTests/imported/w3c/web-platform-tests/fetch/api/basic/request-headers-expected.txt</a></li>
<li><a href="#trunkLayoutTestsimportedw3cwebplatformtestsfetchapibasicrequestheadersworkerexpectedtxt">trunk/LayoutTests/imported/w3c/web-platform-tests/fetch/api/basic/request-headers-worker-expected.txt</a></li>
<li><a href="#trunkSourceWebCoreCMakeListstxt">trunk/Source/WebCore/CMakeLists.txt</a></li>
<li><a href="#trunkSourceWebCoreChangeLog">trunk/Source/WebCore/ChangeLog</a></li>
<li><a href="#trunkSourceWebCoreDerivedSourcescpp">trunk/Source/WebCore/DerivedSources.cpp</a></li>
<li><a href="#trunkSourceWebCoreDerivedSourcesmake">trunk/Source/WebCore/DerivedSources.make</a></li>
<li><a href="#trunkSourceWebCoreWebCorexcodeprojprojectpbxproj">trunk/Source/WebCore/WebCore.xcodeproj/project.pbxproj</a></li>
<li><a href="#trunkSourceWebCorebindingsjsJSBlobCustomcpp">trunk/Source/WebCore/bindings/js/JSBlobCustom.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsscriptsCodeGeneratorJSpm">trunk/Source/WebCore/bindings/scripts/CodeGeneratorJS.pm</a></li>
<li><a href="#trunkSourceWebCorebindingsscriptstestJSJSTestEventConstructorcpp">trunk/Source/WebCore/bindings/scripts/test/JS/JSTestEventConstructor.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsscriptstestJSJSTestObjcpp">trunk/Source/WebCore/bindings/scripts/test/JS/JSTestObj.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsscriptstestJSJSTestOverloadedConstructorsWithSequencecpp">trunk/Source/WebCore/bindings/scripts/test/JS/JSTestOverloadedConstructorsWithSequence.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsscriptstestJSJSTestTypedefscpp">trunk/Source/WebCore/bindings/scripts/test/JS/JSTestTypedefs.cpp</a></li>
<li><a href="#trunkSourceWebCorefileapiBlobcpp">trunk/Source/WebCore/fileapi/Blob.cpp</a></li>
<li><a href="#trunkSourceWebCorefileapiBlobh">trunk/Source/WebCore/fileapi/Blob.h</a></li>
<li><a href="#trunkSourceWebCorefileapiBlobidl">trunk/Source/WebCore/fileapi/Blob.idl</a></li>
<li><a href="#trunkSourceWebCorefileapiFilecpp">trunk/Source/WebCore/fileapi/File.cpp</a></li>
<li><a href="#trunkSourceWebCorefileapiFileh">trunk/Source/WebCore/fileapi/File.h</a></li>
<li><a href="#trunkSourceWebCorefileapiFileidl">trunk/Source/WebCore/fileapi/File.idl</a></li>
<li><a href="#trunkSourceWebCorefileapiThreadableBlobRegistrycpp">trunk/Source/WebCore/fileapi/ThreadableBlobRegistry.cpp</a></li>
<li><a href="#trunkSourceWebCorefileapiThreadableBlobRegistryh">trunk/Source/WebCore/fileapi/ThreadableBlobRegistry.h</a></li>
<li><a href="#trunkSourceWebCoreplatformnetworkBlobParth">trunk/Source/WebCore/platform/network/BlobPart.h</a></li>
<li><a href="#trunkSourceWebCoreplatformnetworkBlobRegistryh">trunk/Source/WebCore/platform/network/BlobRegistry.h</a></li>
<li><a href="#trunkSourceWebCoreplatformnetworkBlobRegistryImplcpp">trunk/Source/WebCore/platform/network/BlobRegistryImpl.cpp</a></li>
<li><a href="#trunkSourceWebCoreplatformnetworkBlobRegistryImplh">trunk/Source/WebCore/platform/network/BlobRegistryImpl.h</a></li>
<li><a href="#trunkSourceWebKit2ChangeLog">trunk/Source/WebKit2/ChangeLog</a></li>
<li><a href="#trunkSourceWebKit2NetworkProcessFileAPINetworkBlobRegistrycpp">trunk/Source/WebKit2/NetworkProcess/FileAPI/NetworkBlobRegistry.cpp</a></li>
<li><a href="#trunkSourceWebKit2NetworkProcessFileAPINetworkBlobRegistryh">trunk/Source/WebKit2/NetworkProcess/FileAPI/NetworkBlobRegistry.h</a></li>
<li><a href="#trunkSourceWebKit2NetworkProcessNetworkConnectionToWebProcesscpp">trunk/Source/WebKit2/NetworkProcess/NetworkConnectionToWebProcess.cpp</a></li>
<li><a href="#trunkSourceWebKit2NetworkProcessNetworkConnectionToWebProcessh">trunk/Source/WebKit2/NetworkProcess/NetworkConnectionToWebProcess.h</a></li>
<li><a href="#trunkSourceWebKit2WebProcessFileAPIBlobRegistryProxycpp">trunk/Source/WebKit2/WebProcess/FileAPI/BlobRegistryProxy.cpp</a></li>
<li><a href="#trunkSourceWebKit2WebProcessFileAPIBlobRegistryProxyh">trunk/Source/WebKit2/WebProcess/FileAPI/BlobRegistryProxy.h</a></li>
</ul>

<h3>Added Paths</h3>
<ul>
<li><a href="#trunkSourceWebCorefileapiBlobBuildercpp">trunk/Source/WebCore/fileapi/BlobBuilder.cpp</a></li>
<li><a href="#trunkSourceWebCorefileapiBlobBuilderh">trunk/Source/WebCore/fileapi/BlobBuilder.h</a></li>
<li><a href="#trunkSourceWebCorefileapiBlobLineEndingsh">trunk/Source/WebCore/fileapi/BlobLineEndings.h</a></li>
<li><a href="#trunkSourceWebCorefileapiBlobLineEndingsidl">trunk/Source/WebCore/fileapi/BlobLineEndings.idl</a></li>
<li><a href="#trunkSourceWebCorefileapiBlobPropertyBagh">trunk/Source/WebCore/fileapi/BlobPropertyBag.h</a></li>
<li><a href="#trunkSourceWebCorefileapiBlobPropertyBagidl">trunk/Source/WebCore/fileapi/BlobPropertyBag.idl</a></li>
</ul>

<h3>Removed Paths</h3>
<ul>
<li><a href="#trunkSourceWebCorebindingsjsJSFileCustomcpp">trunk/Source/WebCore/bindings/js/JSFileCustom.cpp</a></li>
<li><a href="#trunkSourceWebCorefileapiWebKitBlobBuildercpp">trunk/Source/WebCore/fileapi/WebKitBlobBuilder.cpp</a></li>
<li><a href="#trunkSourceWebCorefileapiWebKitBlobBuilderh">trunk/Source/WebCore/fileapi/WebKitBlobBuilder.h</a></li>
</ul>

</div>
<div id="patch">
<h3>Diff</h3>
<a id="trunkLayoutTestsChangeLog"></a>
<div class="modfile"><h4>Modified: trunk/LayoutTests/ChangeLog (209183 => 209184)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/ChangeLog        2016-12-01 17:48:28 UTC (rev 209183)
+++ trunk/LayoutTests/ChangeLog        2016-12-01 18:04:58 UTC (rev 209184)
</span><span class="lines">@@ -1,3 +1,21 @@
</span><ins>+2016-11-30  Sam Weinig  &lt;sam@webkit.org&gt;
+
+        [WebIDL] Remove custom bindings for File and Blob constructors
+        https://bugs.webkit.org/show_bug.cgi?id=165218
+
+        Reviewed by Darin Adler.
+
+        * fast/files/blob-constructor-expected.txt:
+        * fast/files/file-constructor-expected.txt:
+        * fast/files/file-constructor.html:
+        * fast/files/script-tests/blob-constructor.js:
+        Update for stricter parsing and changed error text. (The error text
+        is regressed, but consistent with all generated bindings. I will work
+        on making improvements on this soon.)
+
+        * http/tests/fetch/fetch-as-blob.js:
+        Update to account for stricter rules about dictionary default values.
+
</ins><span class="cx"> 2016-12-01  Ryan Haddad  &lt;ryanhaddad@apple.com&gt;
</span><span class="cx"> 
</span><span class="cx">         Marking media/modern-media-controls/audio/audio-controls-buttons.html as a timeout.
</span></span></pre></div>
<a id="trunkLayoutTestsfastfilesblobconstructorexpectedtxt"></a>
<div class="modfile"><h4>Modified: trunk/LayoutTests/fast/files/blob-constructor-expected.txt (209183 => 209184)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/fast/files/blob-constructor-expected.txt        2016-12-01 17:48:28 UTC (rev 209183)
+++ trunk/LayoutTests/fast/files/blob-constructor-expected.txt        2016-12-01 18:04:58 UTC (rev 209184)
</span><span class="lines">@@ -24,20 +24,20 @@
</span><span class="cx"> PASS (new Blob([toStringingObj])).size is 8
</span><span class="cx"> PASS new Blob([throwingObj]) threw exception Error.
</span><span class="cx"> PASS (new Blob([], {unknownKey:'value'})) instanceof window.Blob is true
</span><del>-PASS new Blob([], {endings:'illegalValue'}) threw exception TypeError: The endings property must be either &quot;transparent&quot; or &quot;native&quot;.
-PASS new Blob([], {endings:throwingObj}) threw exception Error.
</del><ins>+PASS new Blob([], {endings:'illegalValue'}) threw exception TypeError: Type error.
+PASS new Blob([], {endings:throwingObj}) threw exception TypeError: Type error.
</ins><span class="cx"> PASS new Blob([], {type:throwingObj}) threw exception Error.
</span><del>-PASS new Blob([], {endings:throwingObj1, type:throwingObj2}) threw exception Error 1.
-PASS new Blob([], {type:throwingObj2, endings:throwingObj1}) threw exception Error 1.
-PASS new Blob([], {type:throwingObj2, endings:'illegal'}) threw exception TypeError: The endings property must be either &quot;transparent&quot; or &quot;native&quot;.
-PASS (new Blob([], null)) instanceof window.Blob threw exception TypeError: Second argument of the constructor is not of type Object.
-PASS (new Blob([], undefined)) instanceof window.Blob threw exception TypeError: Second argument of the constructor is not of type Object.
-PASS (new Blob([], 123)) instanceof window.Blob threw exception TypeError: Second argument of the constructor is not of type Object.
-PASS (new Blob([], 123.4)) instanceof window.Blob threw exception TypeError: Second argument of the constructor is not of type Object.
-PASS (new Blob([], true)) instanceof window.Blob threw exception TypeError: Second argument of the constructor is not of type Object.
-PASS (new Blob([], 'abc')) instanceof window.Blob threw exception TypeError: Second argument of the constructor is not of type Object.
</del><ins>+PASS new Blob([], {endings:throwingObj1, type:throwingObj2}) threw exception TypeError: Type error.
+PASS new Blob([], {type:throwingObj2, endings:throwingObj1}) threw exception TypeError: Type error.
+PASS new Blob([], {type:throwingObj2, endings:'illegal'}) threw exception TypeError: Type error.
+PASS (new Blob([], null)) instanceof window.Blob is true
+PASS (new Blob([], undefined)) instanceof window.Blob is true
+PASS (new Blob([], 123)) instanceof window.Blob threw exception TypeError: Type error.
+PASS (new Blob([], 123.4)) instanceof window.Blob threw exception TypeError: Type error.
+PASS (new Blob([], true)) instanceof window.Blob threw exception TypeError: Type error.
+PASS (new Blob([], 'abc')) instanceof window.Blob threw exception TypeError: Type error.
</ins><span class="cx"> PASS (new Blob([], [])) instanceof window.Blob is true
</span><del>-PASS (new Blob([], /abc/)) instanceof window.Blob is true
</del><ins>+PASS (new Blob([], /abc/)) threw exception TypeError: Type error.
</ins><span class="cx"> PASS (new Blob([], function () {})) instanceof window.Blob is true
</span><span class="cx"> PASS (new Blob([], {type:'text/html'})).type is 'text/html'
</span><span class="cx"> PASS (new Blob([], {type:'text/html'})).size is 0
</span><span class="lines">@@ -72,13 +72,6 @@
</span><span class="cx"> PASS new Blob([(new Float64Array(100)).buffer]).size is 800
</span><span class="cx"> PASS new Blob([(new Float64Array(100)).buffer, (new Int32Array(100)).buffer, (new Uint8Array(100)).buffer, (new DataView(new ArrayBuffer(100))).buffer]).size is 1400
</span><span class="cx"> PASS new Blob([new Blob([(new Int32Array(100)).buffer]), (new Uint8Array(100)).buffer, (new Float32Array(100)).buffer, (new DataView(new ArrayBuffer(100))).buffer]).size is 1000
</span><del>-PASS new Blob({length: 0}) instanceof window.Blob is true
-PASS new Blob({length: 0}).size is 0
-PASS new Blob({length: 1, 0: 'string'}).size is 6
-PASS new Blob({length: 2, 0: new Uint8Array(100), 1: new Int16Array(100)}).size is 300
-PASS new Blob({length: 1, 0: 'string'}, {type: 'text/html'}).type is 'text/html'
-PASS new Blob({length: 0}, {endings:'illegal'}) threw exception TypeError: The endings property must be either &quot;transparent&quot; or &quot;native&quot;.
-PASS new Blob(throwingSequence) threw exception Error: Misbehaving property.
</del><span class="cx"> PASS successfullyParsed is true
</span><span class="cx"> 
</span><span class="cx"> TEST COMPLETE
</span></span></pre></div>
<a id="trunkLayoutTestsfastfilesfileconstructorexpectedtxt"></a>
<div class="modfile"><h4>Modified: trunk/LayoutTests/fast/files/file-constructor-expected.txt (209183 => 209184)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/fast/files/file-constructor-expected.txt        2016-12-01 17:48:28 UTC (rev 209183)
+++ trunk/LayoutTests/fast/files/file-constructor-expected.txt        2016-12-01 18:04:58 UTC (rev 209184)
</span><span class="lines">@@ -10,8 +10,8 @@
</span><span class="cx"> PASS (new File(['hello'], 'world.html', {type:'text/html', endings:'native'})) instanceof window.File is true
</span><span class="cx"> PASS (new File(['hello'], 'world.html', {type:'text/html', endings:'transparent'})) instanceof window.File is true
</span><span class="cx"> PASS (new File([], 'world.html')) instanceof window.File is true
</span><del>-PASS (new File()) threw exception TypeError: Argument 1 ('fileBits') to the File constructor must be an instance of sequence.
-PASS (new File([])) threw exception TypeError: Argument 2 ('filename') to the File constructor must be an instance of DOMString.
</del><ins>+PASS (new File()) threw exception TypeError: Not enough arguments.
+PASS (new File([])) threw exception TypeError: Not enough arguments.
</ins><span class="cx"> PASS (new File([], null)) instanceof window.File is true
</span><span class="cx"> PASS (new File([], 1)) instanceof window.File is true
</span><span class="cx"> PASS (new File([], '')) instanceof window.File is true
</span><span class="lines">@@ -18,7 +18,7 @@
</span><span class="cx"> PASS (new File([], document)) instanceof window.File is true
</span><span class="cx"> PASS new File('hello', 'world.html') threw exception TypeError: Value is not a sequence.
</span><span class="cx"> PASS new File(0, 'world.html') threw exception TypeError: Value is not a sequence.
</span><del>-PASS new File(null, 'world.html') threw exception TypeError: Argument 1 ('fileBits') to the File constructor must be an instance of sequence.
</del><ins>+PASS new File(null, 'world.html') threw exception TypeError: Value is not a sequence.
</ins><span class="cx"> PASS (new File([], 'world.html')) instanceof window.File is true
</span><span class="cx"> PASS (new File(['stringPrimitive'], 'world.html')) instanceof window.File is true
</span><span class="cx"> PASS (new File([String('stringObject')], 'world.html')) instanceof window.File is true
</span><span class="lines">@@ -46,18 +46,18 @@
</span><span class="cx"> PASS (new File([], 'world.html', {type:'helloî'})) instanceof window.File is true
</span><span class="cx"> PASS (new File([], 'world.html', {type:'helloî'})).type is ''
</span><span class="cx"> PASS (new File([], 'world.html', {lastModified: 555, type:'goodbye'})).lastModified is 555
</span><del>-PASS (new File([], 'world.html', {lastModified: 555, type:'goodbyeî'})).lastModified is not 555
</del><ins>+PASS (new File([], 'world.html', {lastModified: 555, type:'goodbyeî'})).lastModified is 555
</ins><span class="cx"> PASS (new File([], 'world.html', null)) instanceof window.File is true
</span><span class="cx"> PASS (new File([], 'world.html', undefined)) instanceof window.File is true
</span><del>-PASS (new File([], 'world.html', 123)) instanceof window.File threw exception TypeError: Argument 3 ('options') to the File constructor must be an instance of FilePropertyBag.
-PASS (new File([], 'world.html', 123.4)) instanceof window.File threw exception TypeError: Argument 3 ('options') to the File constructor must be an instance of FilePropertyBag.
-PASS (new File([], 'world.html', true)) instanceof window.File threw exception TypeError: Argument 3 ('options') to the File constructor must be an instance of FilePropertyBag.
-PASS (new File([], 'world.html', 'abc')) instanceof window.File threw exception TypeError: Argument 3 ('options') to the File constructor must be an instance of FilePropertyBag.
</del><ins>+PASS (new File([], 'world.html', 123)) instanceof window.File threw exception TypeError: Type error.
+PASS (new File([], 'world.html', 123.4)) instanceof window.File threw exception TypeError: Type error.
+PASS (new File([], 'world.html', true)) instanceof window.File threw exception TypeError: Type error.
+PASS (new File([], 'world.html', 'abc')) instanceof window.File threw exception TypeError: Type error.
</ins><span class="cx"> PASS (new File([], 'world.html', [])) instanceof window.File is true
</span><del>-PASS (new File([], 'world.html', /abc/)) instanceof window.File is true
</del><ins>+PASS (new File([], 'world.html', /abc/)) instanceof window.File threw exception TypeError: Type error.
</ins><span class="cx"> PASS (new File([], 'world.html', function () {})) instanceof window.File is true
</span><span class="cx"> PASS (new File([], 'world.html')).name is 'world.html'
</span><del>-PASS (new File([], 'w/orld/ht/m.l')).name is 'w:orld:ht:m.l'
</del><ins>+PASS (new File([], 'w/orld/ht/m.l')).name is 'w/orld/ht/m.l'
</ins><span class="cx"> PASS (new File([], 'world.html', {type:'text/html'})).name is 'world.html'
</span><span class="cx"> PASS (new File([], 'world.html', {type:'text/html'})).type is 'text/html'
</span><span class="cx"> PASS (new File([], 'world.html', {type:'text/html'})).size is 0
</span><span class="lines">@@ -96,8 +96,6 @@
</span><span class="cx"> PASS new File([new Blob([(new Int32Array(100)).buffer]), new File([new Uint16Array(100).buffer], 'world.txt'), (new Uint8Array(100)).buffer, (new Float32Array(100)).buffer, (new DataView(new ArrayBuffer(100))).buffer], 'world.html').size is 1200
</span><span class="cx"> PASS new Blob([new Blob([new Int32Array(100)]), new File([new Uint16Array(100)], 'world.txt'), new Uint8Array(100), new Float32Array(100), new DataView(new ArrayBuffer(100))]).size is 1200
</span><span class="cx"> PASS new Blob([new Blob([(new Int32Array(100)).buffer]), new File([new Uint16Array(100).buffer], 'world.txt'), (new Uint8Array(100)).buffer, (new Float32Array(100)).buffer, (new DataView(new ArrayBuffer(100))).buffer]).size is 1200
</span><del>-PASS new File({length: 0}, 'world.txt').size is 0
-PASS new File({length: 1, 0: 'string'}, 'world.txt').size is 6
</del><span class="cx"> PASS successfullyParsed is true
</span><span class="cx"> 
</span><span class="cx"> TEST COMPLETE
</span></span></pre></div>
<a id="trunkLayoutTestsfastfilesfileconstructorhtml"></a>
<div class="modfile"><h4>Modified: trunk/LayoutTests/fast/files/file-constructor.html (209183 => 209184)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/fast/files/file-constructor.html        2016-12-01 17:48:28 UTC (rev 209183)
+++ trunk/LayoutTests/fast/files/file-constructor.html        2016-12-01 18:04:58 UTC (rev 209184)
</span><span class="lines">@@ -16,8 +16,8 @@
</span><span class="cx"> shouldBeTrue(&quot;(new File([], 'world.html')) instanceof window.File&quot;)
</span><span class="cx"> 
</span><span class="cx"> // Verify that the file name argument is required.
</span><del>-shouldThrow(&quot;(new File())&quot;, &quot;'TypeError: Argument 1 (\\'fileBits\\') to the File constructor must be an instance of sequence'&quot;);
-shouldThrow(&quot;(new File([]))&quot;, &quot;'TypeError: Argument 2 (\\'filename\\') to the File constructor must be an instance of DOMString'&quot;);
</del><ins>+shouldThrow(&quot;(new File())&quot;, &quot;'TypeError: Not enough arguments'&quot;);
+shouldThrow(&quot;(new File([]))&quot;, &quot;'TypeError: Not enough arguments'&quot;);
</ins><span class="cx"> 
</span><span class="cx"> // Test valid file names.
</span><span class="cx"> shouldBeTrue(&quot;(new File([], null)) instanceof window.File&quot;);
</span><span class="lines">@@ -28,7 +28,7 @@
</span><span class="cx"> // Test invalid file parts.
</span><span class="cx"> shouldThrow(&quot;new File('hello', 'world.html')&quot;, '&quot;TypeError: Value is not a sequence&quot;');
</span><span class="cx"> shouldThrow(&quot;new File(0, 'world.html')&quot;, '&quot;TypeError: Value is not a sequence&quot;');
</span><del>-shouldThrow(&quot;new File(null, 'world.html')&quot;, &quot;'TypeError: Argument 1 (\\'fileBits\\') to the File constructor must be an instance of sequence'&quot;);
</del><ins>+shouldThrow(&quot;new File(null, 'world.html')&quot;, &quot;'TypeError: Value is not a sequence'&quot;);
</ins><span class="cx"> 
</span><span class="cx"> // Test valid file parts.
</span><span class="cx"> shouldBeTrue(&quot;(new File([], 'world.html')) instanceof window.File&quot;);
</span><span class="lines">@@ -72,24 +72,24 @@
</span><span class="cx"> shouldBeTrue(&quot;(new File([], 'world.html', {type:'hello\u00EE'})) instanceof window.File&quot;);
</span><span class="cx"> shouldBe(&quot;(new File([], 'world.html', {type:'hello\u00EE'})).type&quot;, &quot;''&quot;);
</span><span class="cx"> 
</span><del>-// FilePropertyBag  substeps: Type with non-ascii characters should prevent lastModified from being extracted.
</del><ins>+// FilePropertyBag  substeps: Type with non-ascii characters should not prevent lastModified from being extracted.
</ins><span class="cx"> shouldBe(&quot;(new File([], 'world.html', {lastModified: 555, type:'goodbye'})).lastModified&quot;, &quot;555&quot;);
</span><del>-shouldNotBe(&quot;(new File([], 'world.html', {lastModified: 555, type:'goodbye\u00EE'})).lastModified&quot;, &quot;555&quot;);
</del><ins>+shouldBe(&quot;(new File([], 'world.html', {lastModified: 555, type:'goodbye\u00EE'})).lastModified&quot;, &quot;555&quot;);
</ins><span class="cx"> 
</span><span class="cx"> // Test various non-object literals being used as property bags.
</span><span class="cx"> shouldBeTrue(&quot;(new File([], 'world.html', null)) instanceof window.File&quot;);
</span><span class="cx"> shouldBeTrue(&quot;(new File([], 'world.html', undefined)) instanceof window.File&quot;);
</span><del>-shouldThrow(&quot;(new File([], 'world.html', 123)) instanceof window.File&quot;, &quot;'TypeError: Argument 3 (\\'options\\') to the File constructor must be an instance of FilePropertyBag'&quot;);
-shouldThrow(&quot;(new File([], 'world.html', 123.4)) instanceof window.File&quot;, &quot;'TypeError: Argument 3 (\\'options\\') to the File constructor must be an instance of FilePropertyBag'&quot;);
-shouldThrow(&quot;(new File([], 'world.html', true)) instanceof window.File&quot;, &quot;'TypeError: Argument 3 (\\'options\\') to the File constructor must be an instance of FilePropertyBag'&quot;);
-shouldThrow(&quot;(new File([], 'world.html', 'abc')) instanceof window.File&quot;, &quot;'TypeError: Argument 3 (\\'options\\') to the File constructor must be an instance of FilePropertyBag'&quot;);
</del><ins>+shouldThrow(&quot;(new File([], 'world.html', 123)) instanceof window.File&quot;, &quot;'TypeError: Type error'&quot;);
+shouldThrow(&quot;(new File([], 'world.html', 123.4)) instanceof window.File&quot;, &quot;'TypeError: Type error'&quot;);
+shouldThrow(&quot;(new File([], 'world.html', true)) instanceof window.File&quot;, &quot;'TypeError: Type error'&quot;);
+shouldThrow(&quot;(new File([], 'world.html', 'abc')) instanceof window.File&quot;, &quot;'TypeError: Type error'&quot;);
</ins><span class="cx"> shouldBeTrue(&quot;(new File([], 'world.html', [])) instanceof window.File&quot;);
</span><del>-shouldBeTrue(&quot;(new File([], 'world.html', /abc/)) instanceof window.File&quot;);
</del><ins>+shouldThrow(&quot;(new File([], 'world.html', /abc/)) instanceof window.File&quot;, &quot;'TypeError: Type error'&quot;);
</ins><span class="cx"> shouldBeTrue(&quot;(new File([], 'world.html', function () {})) instanceof window.File&quot;);
</span><span class="cx"> 
</span><span class="cx"> // Test that the name/type/size are correctly added to the File.
</span><span class="cx"> shouldBe(&quot;(new File([], 'world.html')).name&quot;, &quot;'world.html'&quot;);
</span><del>-shouldBe(&quot;(new File([], 'w/orld/ht/m.l')).name&quot;, &quot;'w:orld:ht:m.l'&quot;);
</del><ins>+shouldBe(&quot;(new File([], 'w/orld/ht/m.l')).name&quot;, &quot;'w/orld/ht/m.l'&quot;);
</ins><span class="cx"> shouldBe(&quot;(new File([], 'world.html', {type:'text/html'})).name&quot;, &quot;'world.html'&quot;);
</span><span class="cx"> shouldBe(&quot;(new File([], 'world.html', {type:'text/html'})).type&quot;, &quot;'text/html'&quot;);
</span><span class="cx"> shouldBe(&quot;(new File([], 'world.html', {type:'text/html'})).size&quot;, &quot;0&quot;);
</span><span class="lines">@@ -141,9 +141,4 @@
</span><span class="cx"> // Test building Blobs with ArrayBuffer / ArrayBufferView parts enclosed in files.
</span><span class="cx"> shouldBe(&quot;new Blob([new Blob([new Int32Array(100)]), new File([new Uint16Array(100)], 'world.txt'), new Uint8Array(100), new Float32Array(100), new DataView(new ArrayBuffer(100))]).size&quot;, &quot;1200&quot;);
</span><span class="cx"> shouldBe(&quot;new Blob([new Blob([(new Int32Array(100)).buffer]), new File([new Uint16Array(100).buffer], 'world.txt'), (new Uint8Array(100)).buffer, (new Float32Array(100)).buffer, (new DataView(new ArrayBuffer(100))).buffer]).size&quot;, &quot;1200&quot;);
</span><del>-
-// Test passing blob parts in objects with indexed properties.
-// (This depends on the bindings code handling of sequence&lt;T&gt;)
-shouldBe(&quot;new File({length: 0}, 'world.txt').size&quot;, &quot;0&quot;);
-shouldBe(&quot;new File({length: 1, 0: 'string'}, 'world.txt').size&quot;, &quot;6&quot;);
</del><span class="cx"> &lt;/script&gt;
</span></span></pre></div>
<a id="trunkLayoutTestsfastfilesscripttestsblobconstructorjs"></a>
<div class="modfile"><h4>Modified: trunk/LayoutTests/fast/files/script-tests/blob-constructor.js (209183 => 209184)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/fast/files/script-tests/blob-constructor.js        2016-12-01 17:48:28 UTC (rev 209183)
+++ trunk/LayoutTests/fast/files/script-tests/blob-constructor.js        2016-12-01 18:04:58 UTC (rev 209184)
</span><span class="lines">@@ -34,26 +34,26 @@
</span><span class="cx"> 
</span><span class="cx"> // Test some invalid property bags
</span><span class="cx"> shouldBeTrue(&quot;(new Blob([], {unknownKey:'value'})) instanceof window.Blob&quot;);    // Ignore invalid keys
</span><del>-shouldThrow(&quot;new Blob([], {endings:'illegalValue'})&quot;, &quot;'TypeError: The endings property must be either \&quot;transparent\&quot; or \&quot;native\&quot;'&quot;);
-shouldThrow(&quot;new Blob([], {endings:throwingObj})&quot;, &quot;'Error'&quot;);
</del><ins>+shouldThrow(&quot;new Blob([], {endings:'illegalValue'})&quot;, &quot;'TypeError: Type error'&quot;);
+shouldThrow(&quot;new Blob([], {endings:throwingObj})&quot;, &quot;'TypeError: Type error'&quot;);
</ins><span class="cx"> shouldThrow(&quot;new Blob([], {type:throwingObj})&quot;, &quot;'Error'&quot;);
</span><span class="cx"> 
</span><span class="cx"> // Test that order of property bag evaluation is lexigraphical
</span><span class="cx"> var throwingObj1 = { toString: function() { throw &quot;Error 1&quot;; } };
</span><span class="cx"> var throwingObj2 = { toString: function() { throw &quot;Error 2&quot;; } };
</span><del>-shouldThrow(&quot;new Blob([], {endings:throwingObj1, type:throwingObj2})&quot;, &quot;'Error 1'&quot;);
-shouldThrow(&quot;new Blob([], {type:throwingObj2, endings:throwingObj1})&quot;, &quot;'Error 1'&quot;);
-shouldThrow(&quot;new Blob([], {type:throwingObj2, endings:'illegal'})&quot;, &quot;'TypeError: The endings property must be either \&quot;transparent\&quot; or \&quot;native\&quot;'&quot;);
</del><ins>+shouldThrow(&quot;new Blob([], {endings:throwingObj1, type:throwingObj2})&quot;, &quot;'TypeError: Type error'&quot;);
+shouldThrow(&quot;new Blob([], {type:throwingObj2, endings:throwingObj1})&quot;, &quot;'TypeError: Type error'&quot;);
+shouldThrow(&quot;new Blob([], {type:throwingObj2, endings:'illegal'})&quot;, &quot;'TypeError: Type error'&quot;);
</ins><span class="cx"> 
</span><span class="cx"> // Test various non-object literals being used as property bags
</span><del>-shouldThrow(&quot;(new Blob([], null)) instanceof window.Blob&quot;, &quot;'TypeError: Second argument of the constructor is not of type Object'&quot;);
-shouldThrow(&quot;(new Blob([], undefined)) instanceof window.Blob&quot;, &quot;'TypeError: Second argument of the constructor is not of type Object'&quot;);
-shouldThrow(&quot;(new Blob([], 123)) instanceof window.Blob&quot;, &quot;'TypeError: Second argument of the constructor is not of type Object'&quot;);
-shouldThrow(&quot;(new Blob([], 123.4)) instanceof window.Blob&quot;, &quot;'TypeError: Second argument of the constructor is not of type Object'&quot;);
-shouldThrow(&quot;(new Blob([], true)) instanceof window.Blob&quot;, &quot;'TypeError: Second argument of the constructor is not of type Object'&quot;);
-shouldThrow(&quot;(new Blob([], 'abc')) instanceof window.Blob&quot;, &quot;'TypeError: Second argument of the constructor is not of type Object'&quot;);
</del><ins>+shouldBeTrue(&quot;(new Blob([], null)) instanceof window.Blob&quot;);
+shouldBeTrue(&quot;(new Blob([], undefined)) instanceof window.Blob&quot;);
+shouldThrow(&quot;(new Blob([], 123)) instanceof window.Blob&quot;, &quot;'TypeError: Type error'&quot;);
+shouldThrow(&quot;(new Blob([], 123.4)) instanceof window.Blob&quot;, &quot;'TypeError: Type error'&quot;);
+shouldThrow(&quot;(new Blob([], true)) instanceof window.Blob&quot;, &quot;'TypeError: Type error'&quot;);
+shouldThrow(&quot;(new Blob([], 'abc')) instanceof window.Blob&quot;, &quot;'TypeError: Type error'&quot;);
</ins><span class="cx"> shouldBeTrue(&quot;(new Blob([], [])) instanceof window.Blob&quot;);
</span><del>-shouldBeTrue(&quot;(new Blob([], /abc/)) instanceof window.Blob&quot;);
</del><ins>+shouldThrow(&quot;(new Blob([], /abc/))&quot;, &quot;'TypeError: Type error'&quot;);
</ins><span class="cx"> shouldBeTrue(&quot;(new Blob([], function () {})) instanceof window.Blob&quot;);
</span><span class="cx"> 
</span><span class="cx"> // Test that the type/size is correctly added to the Blob
</span><span class="lines">@@ -98,23 +98,3 @@
</span><span class="cx"> shouldBe(&quot;new Blob([(new Float64Array(100)).buffer]).size&quot;, &quot;800&quot;);
</span><span class="cx"> shouldBe(&quot;new Blob([(new Float64Array(100)).buffer, (new Int32Array(100)).buffer, (new Uint8Array(100)).buffer, (new DataView(new ArrayBuffer(100))).buffer]).size&quot;, &quot;1400&quot;);
</span><span class="cx"> shouldBe(&quot;new Blob([new Blob([(new Int32Array(100)).buffer]), (new Uint8Array(100)).buffer, (new Float32Array(100)).buffer, (new DataView(new ArrayBuffer(100))).buffer]).size&quot;, &quot;1000&quot;);
</span><del>-
-// Test passing blob parts in sequences.
-shouldBeTrue(&quot;new Blob({length: 0}) instanceof window.Blob&quot;);
-shouldBe(&quot;new Blob({length: 0}).size&quot;, &quot;0&quot;);
-shouldBe(&quot;new Blob({length: 1, 0: 'string'}).size&quot;, &quot;6&quot;);
-shouldBe(&quot;new Blob({length: 2, 0: new Uint8Array(100), 1: new Int16Array(100)}).size&quot;, &quot;300&quot;);
-shouldBe(&quot;new Blob({length: 1, 0: 'string'}, {type: 'text/html'}).type&quot;, &quot;'text/html'&quot;);
-shouldThrow(&quot;new Blob({length: 0}, {endings:'illegal'})&quot;, &quot;'TypeError: The endings property must be either \&quot;transparent\&quot; or \&quot;native\&quot;'&quot;);
-
-// Test passing blog parts in a sequence-like object that throws on property access.
-var throwingSequence = {length: 4, 0: 'hello', 3: 'world'};
-Object.defineProperty(throwingSequence, &quot;1&quot;, {
-    get: function() { throw new Error(&quot;Misbehaving property&quot;); },
-    enumerable: true, configurable: true
-});
-Object.defineProperty(throwingSequence, &quot;2&quot;, {
-    get: function() { throw new Error(&quot;This should not be thrown&quot;); },
-    enumerable: true, configurable: true
-});
-shouldThrow(&quot;new Blob(throwingSequence)&quot;, &quot;'Error: Misbehaving property'&quot;);
</del></span></pre></div>
<a id="trunkLayoutTestshttptestsfetchfetchasblobjs"></a>
<div class="modfile"><h4>Modified: trunk/LayoutTests/http/tests/fetch/fetch-as-blob.js (209183 => 209184)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/http/tests/fetch/fetch-as-blob.js        2016-12-01 17:48:28 UTC (rev 209183)
+++ trunk/LayoutTests/http/tests/fetch/fetch-as-blob.js        2016-12-01 18:04:58 UTC (rev 209184)
</span><span class="lines">@@ -29,7 +29,7 @@
</span><span class="cx">     return req.blob()
</span><span class="cx">       .then(function(blob) {
</span><span class="cx">           assert_equals(blob.type, '');
</span><del>-          assert_equals(req.headers.get('Content-Type'), null);
</del><ins>+          assert_equals(req.headers.get('Content-Type'), '');
</ins><span class="cx">         });
</span><span class="cx">   }, 'MIME type for Blob');
</span><span class="cx"> 
</span></span></pre></div>
<a id="trunkLayoutTestsimportedw3cChangeLog"></a>
<div class="modfile"><h4>Modified: trunk/LayoutTests/imported/w3c/ChangeLog (209183 => 209184)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/ChangeLog        2016-12-01 17:48:28 UTC (rev 209183)
+++ trunk/LayoutTests/imported/w3c/ChangeLog        2016-12-01 18:04:58 UTC (rev 209184)
</span><span class="lines">@@ -1,3 +1,14 @@
</span><ins>+2016-11-30  Sam Weinig  &lt;sam@webkit.org&gt;
+
+        [WebIDL] Remove custom bindings for File and Blob constructors
+        https://bugs.webkit.org/show_bug.cgi?id=165218
+
+        Reviewed by Darin Adler.
+
+        * web-platform-tests/fetch/api/basic/request-headers-expected.txt:
+        * web-platform-tests/fetch/api/basic/request-headers-worker-expected.txt:
+        Update results (still failing) to account for stricter rules about dictionary default values.
+
</ins><span class="cx"> 2016-11-30  Jiewen Tan  &lt;jiewen_tan@apple.com&gt;
</span><span class="cx"> 
</span><span class="cx">         SubtleCrypto::deriveKey always return NOT_SUPPORTED_ERR for now
</span></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfetchapibasicrequestheadersexpectedtxt"></a>
<div class="modfile"><h4>Modified: trunk/LayoutTests/imported/w3c/web-platform-tests/fetch/api/basic/request-headers-expected.txt (209183 => 209184)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/fetch/api/basic/request-headers-expected.txt        2016-12-01 17:48:28 UTC (rev 209183)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/fetch/api/basic/request-headers-expected.txt        2016-12-01 18:04:58 UTC (rev 209184)
</span><span class="lines">@@ -7,7 +7,7 @@
</span><span class="cx"> PASS Fetch with POST with text body 
</span><span class="cx"> PASS Fetch with POST with FormData body 
</span><span class="cx"> PASS Fetch with POST with URLSearchParams body 
</span><del>-FAIL Fetch with POST with Blob body assert_equals: Request should have header content-type: null expected (object) null but got (string) &quot;application/x-www-form-urlencoded&quot;
</del><ins>+FAIL Fetch with POST with Blob body assert_equals: Request should have header content-type: null expected (object) null but got (string) &quot;&quot;
</ins><span class="cx"> FAIL Fetch with POST with ArrayBuffer body assert_equals: Request should have header content-type: null expected (object) null but got (string) &quot;application/x-www-form-urlencoded&quot;
</span><span class="cx"> FAIL Fetch with POST with Uint8Array body assert_equals: Request should have header content-type: null expected (object) null but got (string) &quot;application/x-www-form-urlencoded&quot;
</span><span class="cx"> FAIL Fetch with POST with Int8Array body assert_equals: Request should have header content-type: null expected (object) null but got (string) &quot;application/x-www-form-urlencoded&quot;
</span></span></pre></div>
<a id="trunkLayoutTestsimportedw3cwebplatformtestsfetchapibasicrequestheadersworkerexpectedtxt"></a>
<div class="modfile"><h4>Modified: trunk/LayoutTests/imported/w3c/web-platform-tests/fetch/api/basic/request-headers-worker-expected.txt (209183 => 209184)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/imported/w3c/web-platform-tests/fetch/api/basic/request-headers-worker-expected.txt        2016-12-01 17:48:28 UTC (rev 209183)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/fetch/api/basic/request-headers-worker-expected.txt        2016-12-01 18:04:58 UTC (rev 209184)
</span><span class="lines">@@ -7,7 +7,7 @@
</span><span class="cx"> PASS Fetch with POST with text body 
</span><span class="cx"> FAIL Fetch with POST with FormData body Can't find variable: FormData
</span><span class="cx"> PASS Fetch with POST with URLSearchParams body 
</span><del>-FAIL Fetch with POST with Blob body assert_equals: Request should have header content-type: null expected (object) null but got (string) &quot;application/x-www-form-urlencoded&quot;
</del><ins>+FAIL Fetch with POST with Blob body assert_equals: Request should have header content-type: null expected (object) null but got (string) &quot;&quot;
</ins><span class="cx"> FAIL Fetch with POST with ArrayBuffer body assert_equals: Request should have header content-type: null expected (object) null but got (string) &quot;application/x-www-form-urlencoded&quot;
</span><span class="cx"> FAIL Fetch with POST with Uint8Array body assert_equals: Request should have header content-type: null expected (object) null but got (string) &quot;application/x-www-form-urlencoded&quot;
</span><span class="cx"> FAIL Fetch with POST with Int8Array body assert_equals: Request should have header content-type: null expected (object) null but got (string) &quot;application/x-www-form-urlencoded&quot;
</span></span></pre></div>
<a id="trunkSourceWebCoreCMakeListstxt"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/CMakeLists.txt (209183 => 209184)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/CMakeLists.txt        2016-12-01 17:48:28 UTC (rev 209183)
+++ trunk/Source/WebCore/CMakeLists.txt        2016-12-01 18:04:58 UTC (rev 209184)
</span><span class="lines">@@ -468,6 +468,8 @@
</span><span class="cx">     dom/XMLDocument.idl
</span><span class="cx"> 
</span><span class="cx">     fileapi/Blob.idl
</span><ins>+    fileapi/BlobLineEndings.idl
+    fileapi/BlobPropertyBag.idl
</ins><span class="cx">     fileapi/File.idl
</span><span class="cx">     fileapi/FileError.idl
</span><span class="cx">     fileapi/FileException.idl
</span><span class="lines">@@ -1135,7 +1137,6 @@
</span><span class="cx">     bindings/js/JSEventListener.cpp
</span><span class="cx">     bindings/js/JSEventTargetCustom.cpp
</span><span class="cx">     bindings/js/JSExceptionBase.cpp
</span><del>-    bindings/js/JSFileCustom.cpp
</del><span class="cx">     bindings/js/JSFileReaderCustom.cpp
</span><span class="cx">     bindings/js/JSGeolocationCustom.cpp
</span><span class="cx">     bindings/js/JSHTMLAllCollectionCustom.cpp
</span><span class="lines">@@ -1615,6 +1616,7 @@
</span><span class="cx"> 
</span><span class="cx">     fileapi/AsyncFileStream.cpp
</span><span class="cx">     fileapi/Blob.cpp
</span><ins>+    fileapi/BlobBuilder.cpp
</ins><span class="cx">     fileapi/BlobURL.cpp
</span><span class="cx">     fileapi/File.cpp
</span><span class="cx">     fileapi/FileException.cpp
</span><span class="lines">@@ -1623,7 +1625,6 @@
</span><span class="cx">     fileapi/FileReaderLoader.cpp
</span><span class="cx">     fileapi/FileReaderSync.cpp
</span><span class="cx">     fileapi/ThreadableBlobRegistry.cpp
</span><del>-    fileapi/WebKitBlobBuilder.cpp
</del><span class="cx"> 
</span><span class="cx">     history/BackForwardController.cpp
</span><span class="cx">     history/CachedFrame.cpp
</span></span></pre></div>
<a id="trunkSourceWebCoreChangeLog"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/ChangeLog (209183 => 209184)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/ChangeLog        2016-12-01 17:48:28 UTC (rev 209183)
+++ trunk/Source/WebCore/ChangeLog        2016-12-01 18:04:58 UTC (rev 209184)
</span><span class="lines">@@ -1,3 +1,60 @@
</span><ins>+2016-11-30  Sam Weinig  &lt;sam@webkit.org&gt;
+
+        [WebIDL] Remove custom bindings for File and Blob constructors
+        https://bugs.webkit.org/show_bug.cgi?id=165218
+
+        Reviewed by Darin Adler.
+
+        * CMakeLists.txt:
+        * DerivedSources.make:
+        * WebCore.xcodeproj/project.pbxproj:
+        Add/remove new files.
+
+        * bindings/js/JSBlobCustom.cpp:
+        (WebCore::constructJSBlob): Deleted.
+        * bindings/js/JSFileCustom.cpp: Removed.
+        Remove custom constructors.
+
+        * bindings/scripts/CodeGeneratorJS.pm:
+        (GenerateDefaultValue):
+        (GenerateDictionaryImplementationContent):
+        (GenerateParametersCheck):
+        Add support for optional sequences without default values. Move string default value
+        optimizations into GenerateDefaultValue.
+
+        * fileapi/Blob.cpp:
+        (WebCore::Blob::Blob):
+        * fileapi/Blob.h:
+        (WebCore::Blob::create):
+        * fileapi/Blob.idl:
+        * fileapi/File.cpp:
+        (WebCore::File::File):
+        * fileapi/File.h:
+        * fileapi/File.idl:
+        Add support for the generated constructors.
+
+        * fileapi/BlobBuilder.cpp: Copied from Source/WebCore/fileapi/WebKitBlobBuilder.cpp.
+        * fileapi/BlobBuilder.h: Copied from Source/WebCore/fileapi/WebKitBlobBuilder.h.
+        * fileapi/WebKitBlobBuilder.cpp: Removed.
+        * fileapi/WebKitBlobBuilder.h: Removed.
+        Rename WebKitBlobBuilder to BlobBuilder, and update to work with generated constructor.
+
+        * fileapi/BlobPropertyBag.h: Added.
+        * fileapi/BlobPropertyBag.idl: Added.
+        Added.
+
+        * fileapi/ThreadableBlobRegistry.cpp:
+        (WebCore::ThreadableBlobRegistry::registerBlobURL):
+        * fileapi/ThreadableBlobRegistry.h:
+        * platform/network/BlobRegistry.h:
+        * platform/network/BlobRegistryImpl.cpp:
+        (WebCore::BlobRegistryImpl::registerBlobURL):
+        * platform/network/BlobRegistryImpl.h:
+        Avoid copies of the BlobPart Vector.
+
+        * platform/network/BlobPart.h:
+        Replace header-guards with #pragma once.
+
</ins><span class="cx"> 2016-12-01  Antoine Quint  &lt;graouts@apple.com&gt;
</span><span class="cx"> 
</span><span class="cx">         [Modern Media Controls] Provide a UI object to show a list of tracks
</span></span></pre></div>
<a id="trunkSourceWebCoreDerivedSourcescpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/DerivedSources.cpp (209183 => 209184)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/DerivedSources.cpp        2016-12-01 17:48:28 UTC (rev 209183)
+++ trunk/Source/WebCore/DerivedSources.cpp        2016-12-01 18:04:58 UTC (rev 209184)
</span><span class="lines">@@ -45,6 +45,8 @@
</span><span class="cx"> #include &quot;JSBiquadFilterNode.cpp&quot;
</span><span class="cx"> #endif
</span><span class="cx"> #include &quot;JSBlob.cpp&quot;
</span><ins>+#include &quot;JSBlobLineEndings.cpp&quot;
+#include &quot;JSBlobPropertyBag.cpp&quot;
</ins><span class="cx"> #include &quot;JSCanvasGradient.cpp&quot;
</span><span class="cx"> #include &quot;JSCanvasPattern.cpp&quot;
</span><span class="cx"> #include &quot;JSCanvasProxy.cpp&quot;
</span></span></pre></div>
<a id="trunkSourceWebCoreDerivedSourcesmake"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/DerivedSources.make (209183 => 209184)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/DerivedSources.make        2016-12-01 17:48:28 UTC (rev 209183)
+++ trunk/Source/WebCore/DerivedSources.make        2016-12-01 18:04:58 UTC (rev 209184)
</span><span class="lines">@@ -389,6 +389,8 @@
</span><span class="cx">     $(WebCore)/dom/WheelEvent.idl \
</span><span class="cx">     $(WebCore)/dom/XMLDocument.idl \
</span><span class="cx">     $(WebCore)/fileapi/Blob.idl \
</span><ins>+    $(WebCore)/fileapi/BlobLineEndings.idl \
+    $(WebCore)/fileapi/BlobPropertyBag.idl \
</ins><span class="cx">     $(WebCore)/fileapi/File.idl \
</span><span class="cx">     $(WebCore)/fileapi/FileError.idl \
</span><span class="cx">     $(WebCore)/fileapi/FileException.idl \
</span></span></pre></div>
<a id="trunkSourceWebCoreWebCorexcodeprojprojectpbxproj"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/WebCore.xcodeproj/project.pbxproj (209183 => 209184)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/WebCore.xcodeproj/project.pbxproj        2016-12-01 17:48:28 UTC (rev 209183)
+++ trunk/Source/WebCore/WebCore.xcodeproj/project.pbxproj        2016-12-01 18:04:58 UTC (rev 209184)
</span><span class="lines">@@ -2129,7 +2129,6 @@
</span><span class="cx">                 516D7D701BB5F0BD00AF7C77 /* IDBConnectionToServerDelegate.h in Headers */ = {isa = PBXBuildFile; fileRef = 5185FCBD1BB5CB770012898F /* IDBConnectionToServerDelegate.h */; settings = {ATTRIBUTES = (Private, ); }; };
</span><span class="cx">                 516D7D711BB5F0BD00AF7C77 /* IDBConnectionToClient.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 516D7D6D1BB5F06500AF7C77 /* IDBConnectionToClient.cpp */; };
</span><span class="cx">                 516D7D721BB5F0BD00AF7C77 /* IDBConnectionToClientDelegate.h in Headers */ = {isa = PBXBuildFile; fileRef = 516D7D6E1BB5F06500AF7C77 /* IDBConnectionToClientDelegate.h */; settings = {ATTRIBUTES = (Private, ); }; };
</span><del>-                516E54FA1CCB2EA80040D954 /* JSFileCustom.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 516E54F91CCB27FF0040D954 /* JSFileCustom.cpp */; };
</del><span class="cx">                 516F7F6D1C31E39A00F111DC /* ServerOpenDBRequest.h in Headers */ = {isa = PBXBuildFile; fileRef = 516F7F6C1C31C79D00F111DC /* ServerOpenDBRequest.h */; settings = {ATTRIBUTES = (Private, ); }; };
</span><span class="cx">                 516F7F6E1C31E39C00F111DC /* ServerOpenDBRequest.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 516F7F6B1C31C79D00F111DC /* ServerOpenDBRequest.cpp */; };
</span><span class="cx">                 517138EF1BED1D1A000D5F01 /* IndexKey.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 517138ED1BED1D17000D5F01 /* IndexKey.cpp */; };
</span><span class="lines">@@ -2896,6 +2895,12 @@
</span><span class="cx">                 7C73FB11191EF6F4007DE061 /* JSUserMessageHandler.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 7C73FB0F191EF6F4007DE061 /* JSUserMessageHandler.cpp */; };
</span><span class="cx">                 7C73FB12191EF6F4007DE061 /* JSUserMessageHandler.h in Headers */ = {isa = PBXBuildFile; fileRef = 7C73FB10191EF6F4007DE061 /* JSUserMessageHandler.h */; };
</span><span class="cx">                 7C73FB19191EF808007DE061 /* JSUserMessageHandlersNamespaceCustom.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 7C73FB17191EF808007DE061 /* JSUserMessageHandlersNamespaceCustom.cpp */; };
</span><ins>+                7C77C3D11DEE472400A50BFA /* BlobPropertyBag.h in Headers */ = {isa = PBXBuildFile; fileRef = 7C77C3D01DEE472400A50BFA /* BlobPropertyBag.h */; settings = {ATTRIBUTES = (Private, ); }; };
+                7C77C3D41DEF178E00A50BFA /* JSBlobPropertyBag.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 7C77C3D21DEF178E00A50BFA /* JSBlobPropertyBag.cpp */; };
+                7C77C3D51DEF178E00A50BFA /* JSBlobPropertyBag.h in Headers */ = {isa = PBXBuildFile; fileRef = 7C77C3D31DEF178E00A50BFA /* JSBlobPropertyBag.h */; };
+                7C77C3D71DEF850A00A50BFA /* BlobLineEndings.h in Headers */ = {isa = PBXBuildFile; fileRef = 7C77C3D61DEF850A00A50BFA /* BlobLineEndings.h */; settings = {ATTRIBUTES = (Private, ); }; };
+                7C77C3DB1DEF86D700A50BFA /* JSBlobLineEndings.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 7C77C3D91DEF86D700A50BFA /* JSBlobLineEndings.cpp */; };
+                7C77C3DC1DEF86D700A50BFA /* JSBlobLineEndings.h in Headers */ = {isa = PBXBuildFile; fileRef = 7C77C3DA1DEF86D700A50BFA /* JSBlobLineEndings.h */; };
</ins><span class="cx">                 7C7941E41C56C29300A4C58E /* DataDetectorsCoreSoftLink.mm in Sources */ = {isa = PBXBuildFile; fileRef = 7C7941E21C56C29300A4C58E /* DataDetectorsCoreSoftLink.mm */; };
</span><span class="cx">                 7C7941E51C56C29300A4C58E /* DataDetectorsCoreSoftLink.h in Headers */ = {isa = PBXBuildFile; fileRef = 7C7941E31C56C29300A4C58E /* DataDetectorsCoreSoftLink.h */; };
</span><span class="cx">                 7C83DE861D04CC5D00FEBCF3 /* SpringSolver.h in Headers */ = {isa = PBXBuildFile; fileRef = 7C83DE851D04CBD400FEBCF3 /* SpringSolver.h */; };
</span><span class="lines">@@ -3630,8 +3635,8 @@
</span><span class="cx">                 9767CE0C145ABC13005E64DB /* ExceptionInterfaces.h in Headers */ = {isa = PBXBuildFile; fileRef = 9767CE0A145ABC13005E64DB /* ExceptionInterfaces.h */; };
</span><span class="cx">                 976D6C78122B8A3D001FD1F7 /* Blob.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 976D6C59122B8A3D001FD1F7 /* Blob.cpp */; };
</span><span class="cx">                 976D6C79122B8A3D001FD1F7 /* Blob.h in Headers */ = {isa = PBXBuildFile; fileRef = 976D6C5A122B8A3D001FD1F7 /* Blob.h */; settings = {ATTRIBUTES = (Private, ); }; };
</span><del>-                976D6C7B122B8A3D001FD1F7 /* WebKitBlobBuilder.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 976D6C5C122B8A3D001FD1F7 /* WebKitBlobBuilder.cpp */; };
-                976D6C7C122B8A3D001FD1F7 /* WebKitBlobBuilder.h in Headers */ = {isa = PBXBuildFile; fileRef = 976D6C5D122B8A3D001FD1F7 /* WebKitBlobBuilder.h */; };
</del><ins>+                976D6C7B122B8A3D001FD1F7 /* BlobBuilder.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 976D6C5C122B8A3D001FD1F7 /* BlobBuilder.cpp */; };
+                976D6C7C122B8A3D001FD1F7 /* BlobBuilder.h in Headers */ = {isa = PBXBuildFile; fileRef = 976D6C5D122B8A3D001FD1F7 /* BlobBuilder.h */; };
</ins><span class="cx">                 976D6C7E122B8A3D001FD1F7 /* BlobURL.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 976D6C5F122B8A3D001FD1F7 /* BlobURL.cpp */; };
</span><span class="cx">                 976D6C7F122B8A3D001FD1F7 /* BlobURL.h in Headers */ = {isa = PBXBuildFile; fileRef = 976D6C60122B8A3D001FD1F7 /* BlobURL.h */; };
</span><span class="cx">                 976D6C80122B8A3D001FD1F7 /* File.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 976D6C61122B8A3D001FD1F7 /* File.cpp */; };
</span><span class="lines">@@ -9371,7 +9376,6 @@
</span><span class="cx">                 516C62241950E2B900337E75 /* JSGamepadEvent.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = JSGamepadEvent.h; sourceTree = &quot;&lt;group&gt;&quot;; };
</span><span class="cx">                 516D7D6D1BB5F06500AF7C77 /* IDBConnectionToClient.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = IDBConnectionToClient.cpp; sourceTree = &quot;&lt;group&gt;&quot;; };
</span><span class="cx">                 516D7D6E1BB5F06500AF7C77 /* IDBConnectionToClientDelegate.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = IDBConnectionToClientDelegate.h; sourceTree = &quot;&lt;group&gt;&quot;; };
</span><del>-                516E54F91CCB27FF0040D954 /* JSFileCustom.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = JSFileCustom.cpp; sourceTree = &quot;&lt;group&gt;&quot;; };
</del><span class="cx">                 516F7F6B1C31C79D00F111DC /* ServerOpenDBRequest.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = ServerOpenDBRequest.cpp; sourceTree = &quot;&lt;group&gt;&quot;; };
</span><span class="cx">                 516F7F6C1C31C79D00F111DC /* ServerOpenDBRequest.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ServerOpenDBRequest.h; sourceTree = &quot;&lt;group&gt;&quot;; };
</span><span class="cx">                 517138ED1BED1D17000D5F01 /* IndexKey.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = IndexKey.cpp; sourceTree = &quot;&lt;group&gt;&quot;; };
</span><span class="lines">@@ -10382,6 +10386,14 @@
</span><span class="cx">                 7C73FB0F191EF6F4007DE061 /* JSUserMessageHandler.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = JSUserMessageHandler.cpp; sourceTree = &quot;&lt;group&gt;&quot;; };
</span><span class="cx">                 7C73FB10191EF6F4007DE061 /* JSUserMessageHandler.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = JSUserMessageHandler.h; sourceTree = &quot;&lt;group&gt;&quot;; };
</span><span class="cx">                 7C73FB17191EF808007DE061 /* JSUserMessageHandlersNamespaceCustom.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = JSUserMessageHandlersNamespaceCustom.cpp; sourceTree = &quot;&lt;group&gt;&quot;; };
</span><ins>+                7C77C3CF1DEE471800A50BFA /* BlobPropertyBag.idl */ = {isa = PBXFileReference; lastKnownFileType = text; path = BlobPropertyBag.idl; sourceTree = &quot;&lt;group&gt;&quot;; };
+                7C77C3D01DEE472400A50BFA /* BlobPropertyBag.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = BlobPropertyBag.h; sourceTree = &quot;&lt;group&gt;&quot;; };
+                7C77C3D21DEF178E00A50BFA /* JSBlobPropertyBag.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = JSBlobPropertyBag.cpp; sourceTree = &quot;&lt;group&gt;&quot;; };
+                7C77C3D31DEF178E00A50BFA /* JSBlobPropertyBag.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = JSBlobPropertyBag.h; sourceTree = &quot;&lt;group&gt;&quot;; };
+                7C77C3D61DEF850A00A50BFA /* BlobLineEndings.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = BlobLineEndings.h; sourceTree = &quot;&lt;group&gt;&quot;; };
+                7C77C3D81DEF854000A50BFA /* BlobLineEndings.idl */ = {isa = PBXFileReference; lastKnownFileType = text; path = BlobLineEndings.idl; sourceTree = &quot;&lt;group&gt;&quot;; };
+                7C77C3D91DEF86D700A50BFA /* JSBlobLineEndings.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = JSBlobLineEndings.cpp; sourceTree = &quot;&lt;group&gt;&quot;; };
+                7C77C3DA1DEF86D700A50BFA /* JSBlobLineEndings.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = JSBlobLineEndings.h; sourceTree = &quot;&lt;group&gt;&quot;; };
</ins><span class="cx">                 7C7941E21C56C29300A4C58E /* DataDetectorsCoreSoftLink.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = DataDetectorsCoreSoftLink.mm; sourceTree = &quot;&lt;group&gt;&quot;; };
</span><span class="cx">                 7C7941E31C56C29300A4C58E /* DataDetectorsCoreSoftLink.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = DataDetectorsCoreSoftLink.h; sourceTree = &quot;&lt;group&gt;&quot;; };
</span><span class="cx">                 7C83DE851D04CBD400FEBCF3 /* SpringSolver.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SpringSolver.h; sourceTree = &quot;&lt;group&gt;&quot;; };
</span><span class="lines">@@ -11211,8 +11223,8 @@
</span><span class="cx">                 9767CE0A145ABC13005E64DB /* ExceptionInterfaces.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ExceptionInterfaces.h; sourceTree = &quot;&lt;group&gt;&quot;; };
</span><span class="cx">                 976D6C59122B8A3D001FD1F7 /* Blob.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = Blob.cpp; sourceTree = &quot;&lt;group&gt;&quot;; };
</span><span class="cx">                 976D6C5A122B8A3D001FD1F7 /* Blob.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = Blob.h; sourceTree = &quot;&lt;group&gt;&quot;; };
</span><del>-                976D6C5C122B8A3D001FD1F7 /* WebKitBlobBuilder.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = WebKitBlobBuilder.cpp; sourceTree = &quot;&lt;group&gt;&quot;; };
-                976D6C5D122B8A3D001FD1F7 /* WebKitBlobBuilder.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = WebKitBlobBuilder.h; sourceTree = &quot;&lt;group&gt;&quot;; };
</del><ins>+                976D6C5C122B8A3D001FD1F7 /* BlobBuilder.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = BlobBuilder.cpp; sourceTree = &quot;&lt;group&gt;&quot;; };
+                976D6C5D122B8A3D001FD1F7 /* BlobBuilder.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = BlobBuilder.h; sourceTree = &quot;&lt;group&gt;&quot;; };
</ins><span class="cx">                 976D6C5F122B8A3D001FD1F7 /* BlobURL.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = BlobURL.cpp; sourceTree = &quot;&lt;group&gt;&quot;; };
</span><span class="cx">                 976D6C60122B8A3D001FD1F7 /* BlobURL.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = BlobURL.h; sourceTree = &quot;&lt;group&gt;&quot;; };
</span><span class="cx">                 976D6C61122B8A3D001FD1F7 /* File.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = File.cpp; sourceTree = &quot;&lt;group&gt;&quot;; };
</span><span class="lines">@@ -18308,6 +18320,10 @@
</span><span class="cx">                         children = (
</span><span class="cx">                                 2E2D99CB10E2BBDA00496337 /* JSBlob.cpp */,
</span><span class="cx">                                 2E2D99CC10E2BBDA00496337 /* JSBlob.h */,
</span><ins>+                                7C77C3D21DEF178E00A50BFA /* JSBlobPropertyBag.cpp */,
+                                7C77C3D31DEF178E00A50BFA /* JSBlobPropertyBag.h */,
+                                7C77C3D91DEF86D700A50BFA /* JSBlobLineEndings.cpp */,
+                                7C77C3DA1DEF86D700A50BFA /* JSBlobLineEndings.h */,
</ins><span class="cx">                                 BC00F0100E0A189500FD04E3 /* JSFile.cpp */,
</span><span class="cx">                                 BC00F0110E0A189500FD04E3 /* JSFile.h */,
</span><span class="cx">                                 2E3BC0C8117D3E0800B9409A /* JSFileError.cpp */,
</span><span class="lines">@@ -19231,6 +19247,12 @@
</span><span class="cx">                                 976D6C59122B8A3D001FD1F7 /* Blob.cpp */,
</span><span class="cx">                                 976D6C5A122B8A3D001FD1F7 /* Blob.h */,
</span><span class="cx">                                 14A98E05136386A200C9FED2 /* Blob.idl */,
</span><ins>+                                976D6C5C122B8A3D001FD1F7 /* BlobBuilder.cpp */,
+                                976D6C5D122B8A3D001FD1F7 /* BlobBuilder.h */,
+                                7C77C3D01DEE472400A50BFA /* BlobPropertyBag.h */,
+                                7C77C3CF1DEE471800A50BFA /* BlobPropertyBag.idl */,
+                                7C77C3D61DEF850A00A50BFA /* BlobLineEndings.h */,
+                                7C77C3D81DEF854000A50BFA /* BlobLineEndings.idl */,
</ins><span class="cx">                                 976D6C5F122B8A3D001FD1F7 /* BlobURL.cpp */,
</span><span class="cx">                                 976D6C60122B8A3D001FD1F7 /* BlobURL.h */,
</span><span class="cx">                                 976D6C61122B8A3D001FD1F7 /* File.cpp */,
</span><span class="lines">@@ -19256,8 +19278,6 @@
</span><span class="cx">                                 E1AB1EBD14E9E3A800449E13 /* FileReaderSync.idl */,
</span><span class="cx">                                 976D6C75122B8A3D001FD1F7 /* ThreadableBlobRegistry.cpp */,
</span><span class="cx">                                 976D6C76122B8A3D001FD1F7 /* ThreadableBlobRegistry.h */,
</span><del>-                                976D6C5C122B8A3D001FD1F7 /* WebKitBlobBuilder.cpp */,
-                                976D6C5D122B8A3D001FD1F7 /* WebKitBlobBuilder.h */,
</del><span class="cx">                         );
</span><span class="cx">                         path = fileapi;
</span><span class="cx">                         sourceTree = &quot;&lt;group&gt;&quot;;
</span><span class="lines">@@ -22040,7 +22060,6 @@
</span><span class="cx">                                 ADEC78F718EE5308001315C2 /* JSElementCustom.h */,
</span><span class="cx">                                 A56D02A21D0B9AF30095E5D3 /* JSErrorEventCustom.cpp */,
</span><span class="cx">                                 BCEFAF4D0C317E6900FA81F6 /* JSEventCustom.cpp */,
</span><del>-                                516E54F91CCB27FF0040D954 /* JSFileCustom.cpp */,
</del><span class="cx">                                 2E7582ED12764F260062628B /* JSFileReaderCustom.cpp */,
</span><span class="cx">                                 C28083411C6DC96A001451B6 /* JSFontFaceCustom.cpp */,
</span><span class="cx">                                 1C24EEAA1C72AA0A0080F8FC /* JSFontFaceSetCustom.cpp */,
</span><span class="lines">@@ -24944,6 +24963,7 @@
</span><span class="cx">                                 FD31602512B0267600C1A359 /* BiquadDSPKernel.h in Headers */,
</span><span class="cx">                                 FDC54F051399B0DA008D9117 /* BiquadFilterNode.h in Headers */,
</span><span class="cx">                                 FD31602712B0267600C1A359 /* BiquadProcessor.h in Headers */,
</span><ins>+                                7C77C3D11DEE472400A50BFA /* BlobPropertyBag.h in Headers */,
</ins><span class="cx">                                 A89943280B42338800D7C802 /* BitmapImage.h in Headers */,
</span><span class="cx">                                 976D6C79122B8A3D001FD1F7 /* Blob.h in Headers */,
</span><span class="cx">                                 2EDEF1F4121B0EFC00726DB2 /* BlobData.h in Headers */,
</span><span class="lines">@@ -25428,6 +25448,7 @@
</span><span class="cx">                                 188604B40F2E654A000B6443 /* DOMTimer.h in Headers */,
</span><span class="cx">                                 05FD69E012845D4300B2BEB3 /* DOMTimeStamp.h in Headers */,
</span><span class="cx">                                 76FC2B0C12370DA0006A991A /* DOMTokenList.h in Headers */,
</span><ins>+                                7C77C3DC1DEF86D700A50BFA /* JSBlobLineEndings.h in Headers */,
</ins><span class="cx">                                 2E37DFDB12DBAFB800A6B233 /* DOMURL.h in Headers */,
</span><span class="cx">                                 CD9DE18217AAD6A400EA386D /* DOMURLMediaSource.h in Headers */,
</span><span class="cx">                                 15FCC9FE1B4DF85E00E72326 /* DOMURLMediaStream.h in Headers */,
</span><span class="lines">@@ -25497,6 +25518,7 @@
</span><span class="cx">                                 8F67561B1288B17B0047ACA3 /* EventQueue.h in Headers */,
</span><span class="cx">                                 E0FEF372B17C53EAC1C1FBEE /* EventSource.h in Headers */,
</span><span class="cx">                                 E12EDB7B0B308A78002704B6 /* EventTarget.h in Headers */,
</span><ins>+                                7C77C3D51DEF178E00A50BFA /* JSBlobPropertyBag.h in Headers */,
</ins><span class="cx">                                 97AA3CA5145237CC003E1DA6 /* EventTargetHeaders.h in Headers */,
</span><span class="cx">                                 97AA3CA6145237CC003E1DA6 /* EventTargetInterfaces.h in Headers */,
</span><span class="cx">                                 262EC41A1D078FB900BA78FC /* EventTrackingRegions.h in Headers */,
</span><span class="lines">@@ -25895,6 +25917,7 @@
</span><span class="cx">                                 F55B3DC21251F12D003EF269 /* ImageInputType.h in Headers */,
</span><span class="cx">                                 089582560E857A7E00F82C83 /* ImageLoader.h in Headers */,
</span><span class="cx">                                 BC7F44A80B9E324E00A9D081 /* ImageObserver.h in Headers */,
</span><ins>+                                7C77C3D71DEF850A00A50BFA /* BlobLineEndings.h in Headers */,
</ins><span class="cx">                                 2D5A5931152525D00036EE51 /* ImageOrientation.h in Headers */,
</span><span class="cx">                                 B51A2F3F17D7D3AE0072517A /* ImageQualityController.h in Headers */,
</span><span class="cx">                                 49291E4B134172C800E753DE /* ImageRenderingMode.h in Headers */,
</span><span class="lines">@@ -28201,7 +28224,7 @@
</span><span class="cx">                                 A584FE301864CB8400843B10 /* WebInjectedScriptManager.h in Headers */,
</span><span class="cx">                                 31C0FF220E4CEB6E007D6FE5 /* WebKitAnimationEvent.h in Headers */,
</span><span class="cx">                                 5DFEBAB718592B6D00C75BEB /* WebKitAvailability.h in Headers */,
</span><del>-                                976D6C7C122B8A3D001FD1F7 /* WebKitBlobBuilder.h in Headers */,
</del><ins>+                                976D6C7C122B8A3D001FD1F7 /* BlobBuilder.h in Headers */,
</ins><span class="cx">                                 498391590F1E776900C23782 /* WebKitCSSMatrix.h in Headers */,
</span><span class="cx">                                 8AA61D00144D595B00F37350 /* WebKitCSSRegionRule.h in Headers */,
</span><span class="cx">                                 BC9ADD230CC4032600098C4C /* WebKitCSSTransformValue.h in Headers */,
</span><span class="lines">@@ -29890,7 +29913,6 @@
</span><span class="cx">                                 7E4C96DC1AD4483500365A50 /* JSFetchRequest.cpp in Sources */,
</span><span class="cx">                                 8E4C96DC1AD4483500365A50 /* JSFetchResponse.cpp in Sources */,
</span><span class="cx">                                 BC00F0140E0A189500FD04E3 /* JSFile.cpp in Sources */,
</span><del>-                                516E54FA1CCB2EA80040D954 /* JSFileCustom.cpp in Sources */,
</del><span class="cx">                                 2E3BC0CA117D3E0800B9409A /* JSFileError.cpp in Sources */,
</span><span class="cx">                                 898785F0122E1E87003AABDA /* JSFileException.cpp in Sources */,
</span><span class="cx">                                 BC00F0160E0A189500FD04E3 /* JSFileList.cpp in Sources */,
</span><span class="lines">@@ -31657,6 +31679,7 @@
</span><span class="cx">                                 934D9BA50B8C116B007B42A9 /* WebCoreNSStringExtras.mm in Sources */,
</span><span class="cx">                                 C5B4C24E1509236C00A6EF37 /* WebCoreNSURLExtras.mm in Sources */,
</span><span class="cx">                                 CD225C0B1C46FBF400140761 /* WebCoreNSURLSession.mm in Sources */,
</span><ins>+                                7C77C3D41DEF178E00A50BFA /* JSBlobPropertyBag.cpp in Sources */,
</ins><span class="cx">                                 B50F5B810E96CD9900AD71A6 /* WebCoreObjCExtras.mm in Sources */,
</span><span class="cx">                                 E180810E16FCECDF00B80D07 /* WebCoreResourceHandleAsDelegate.mm in Sources */,
</span><span class="cx">                                 E152551616FD2350003D7ADB /* WebCoreResourceHandleAsOperationQueueDelegate.mm in Sources */,
</span><span class="lines">@@ -31713,7 +31736,7 @@
</span><span class="cx">                                 A584FE2F1864CB8400843B10 /* WebInjectedScriptManager.cpp in Sources */,
</span><span class="cx">                                 1A7E19461C5863BE00CCDDF3 /* WebKitAdditions.mm in Sources */,
</span><span class="cx">                                 31C0FF210E4CEB6E007D6FE5 /* WebKitAnimationEvent.cpp in Sources */,
</span><del>-                                976D6C7B122B8A3D001FD1F7 /* WebKitBlobBuilder.cpp in Sources */,
</del><ins>+                                976D6C7B122B8A3D001FD1F7 /* BlobBuilder.cpp in Sources */,
</ins><span class="cx">                                 498391580F1E776900C23782 /* WebKitCSSMatrix.cpp in Sources */,
</span><span class="cx">                                 8AA61CFF144D595B00F37350 /* WebKitCSSRegionRule.cpp in Sources */,
</span><span class="cx">                                 BC9ADD800CC4092200098C4C /* WebKitCSSTransformValue.cpp in Sources */,
</span><span class="lines">@@ -31728,6 +31751,7 @@
</span><span class="cx">                                 A5DEBDA316FB908700836FE0 /* WebKitPlaybackTargetAvailabilityEvent.cpp in Sources */,
</span><span class="cx">                                 5709E8CD1D413D47003244AC /* WebKitSubtleCrypto.cpp in Sources */,
</span><span class="cx">                                 31C0FF240E4CEB6E007D6FE5 /* WebKitTransitionEvent.cpp in Sources */,
</span><ins>+                                7C77C3DB1DEF86D700A50BFA /* JSBlobLineEndings.cpp in Sources */,
</ins><span class="cx">                                 0FCF332E0F2B9A25004B6795 /* WebLayer.mm in Sources */,
</span><span class="cx">                                 0709D78E1AE55554004E42F8 /* WebMediaSessionManager.cpp in Sources */,
</span><span class="cx">                                 0709D7921AE5557E004E42F8 /* WebMediaSessionManagerMac.cpp in Sources */,
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsjsJSBlobCustomcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/js/JSBlobCustom.cpp (209183 => 209184)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/js/JSBlobCustom.cpp        2016-12-01 17:48:28 UTC (rev 209183)
+++ trunk/Source/WebCore/bindings/js/JSBlobCustom.cpp        2016-12-01 18:04:58 UTC (rev 209184)
</span><span class="lines">@@ -32,18 +32,8 @@
</span><span class="cx"> #include &quot;config.h&quot;
</span><span class="cx"> #include &quot;JSBlob.h&quot;
</span><span class="cx"> 
</span><del>-#include &quot;Blob.h&quot;
-#include &quot;ExceptionCode.h&quot;
</del><span class="cx"> #include &quot;JSDOMBinding.h&quot;
</span><del>-#include &quot;JSDictionary.h&quot;
</del><span class="cx"> #include &quot;JSFile.h&quot;
</span><del>-#include &quot;ScriptExecutionContext.h&quot;
-#include &quot;WebKitBlobBuilder.h&quot;
-#include &lt;runtime/Error.h&gt;
-#include &lt;runtime/JSArray.h&gt;
-#include &lt;runtime/JSArrayBuffer.h&gt;
-#include &lt;runtime/JSArrayBufferView.h&gt;
-#include &lt;wtf/Assertions.h&gt;
</del><span class="cx"> 
</span><span class="cx"> using namespace JSC;
</span><span class="cx"> 
</span><span class="lines">@@ -61,79 +51,4 @@
</span><span class="cx">     return wrap(state, globalObject, blob);
</span><span class="cx"> }
</span><span class="cx"> 
</span><del>-EncodedJSValue JSC_HOST_CALL constructJSBlob(ExecState&amp; exec)
-{
-    VM&amp; vm = exec.vm();
-    auto scope = DECLARE_THROW_SCOPE(vm);
-
-    DOMConstructorObject* jsConstructor = jsCast&lt;DOMConstructorObject*&gt;(exec.callee());
-    ASSERT(jsConstructor);
-
-    ScriptExecutionContext* context = jsConstructor-&gt;scriptExecutionContext();
-    if (!context)
-        return throwConstructorScriptExecutionContextUnavailableError(exec, scope, &quot;Blob&quot;);
-
-    if (!exec.argumentCount()) {
-        return JSValue::encode(createWrapper&lt;Blob&gt;(jsConstructor-&gt;globalObject(), Blob::create()));
-    }
-
-    unsigned blobPartsLength = 0;
-    JSObject* blobParts = toJSSequence(exec, exec.uncheckedArgument(0), blobPartsLength);
-    RETURN_IF_EXCEPTION(scope, encodedJSValue());
-    ASSERT(blobParts);
-
-    String type;
-    String endings = ASCIILiteral(&quot;transparent&quot;);
-
-    if (exec.argumentCount() &gt; 1) {
-        JSValue blobPropertyBagValue = exec.uncheckedArgument(1);
-
-        if (!blobPropertyBagValue.isObject())
-            return throwVMTypeError(&amp;exec, scope, &quot;Second argument of the constructor is not of type Object&quot;);
-
-        // Given the above test, this will always yield an object.
-        JSObject* blobPropertyBagObject = blobPropertyBagValue.toObject(&amp;exec);
-
-        // Create the dictionary wrapper from the initializer object.
-        JSDictionary dictionary(&amp;exec, blobPropertyBagObject);
-
-        // Attempt to get the endings property and validate it.
-        bool containsEndings = dictionary.get(&quot;endings&quot;, endings);
-        RETURN_IF_EXCEPTION(scope, encodedJSValue());
-
-        if (containsEndings) {
-            if (endings != &quot;transparent&quot; &amp;&amp; endings != &quot;native&quot;)
-                return throwVMTypeError(&amp;exec, scope, &quot;The endings property must be either \&quot;transparent\&quot; or \&quot;native\&quot;&quot;);
-        }
-
-        // Attempt to get the type property.
-        dictionary.get(&quot;type&quot;, type);
-        RETURN_IF_EXCEPTION(scope, encodedJSValue());
-    }
-
-    ASSERT(endings == &quot;transparent&quot; || endings == &quot;native&quot;);
-
-    BlobBuilder blobBuilder;
-
-    for (unsigned i = 0; i &lt; blobPartsLength; ++i) {
-        JSValue item = blobParts-&gt;get(&amp;exec, i);
-        RETURN_IF_EXCEPTION(scope, encodedJSValue());
-
-        if (ArrayBuffer* arrayBuffer = toUnsharedArrayBuffer(item))
-            blobBuilder.append(arrayBuffer);
-        else if (auto arrayBufferView = toUnsharedArrayBufferView(item))
-            blobBuilder.append(WTFMove(arrayBufferView));
-        else if (Blob* blob = JSBlob::toWrapped(item))
-            blobBuilder.append(blob);
-        else {
-            String string = item.toWTFString(&amp;exec);
-            RETURN_IF_EXCEPTION(scope, encodedJSValue());
-            blobBuilder.append(string, endings);
-        }
-    }
-
-    auto blob = Blob::create(blobBuilder.finalize(), Blob::normalizedContentType(type));
-    return JSValue::encode(createWrapper&lt;Blob&gt;(jsConstructor-&gt;globalObject(), WTFMove(blob)));
-}
-
</del><span class="cx"> } // namespace WebCore
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsjsJSFileCustomcpp"></a>
<div class="delfile"><h4>Deleted: trunk/Source/WebCore/bindings/js/JSFileCustom.cpp (209183 => 209184)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/js/JSFileCustom.cpp        2016-12-01 17:48:28 UTC (rev 209183)
+++ trunk/Source/WebCore/bindings/js/JSFileCustom.cpp        2016-12-01 18:04:58 UTC (rev 209184)
</span><span class="lines">@@ -1,126 +0,0 @@
</span><del>-/*
- * Copyright (C) 2016 Apple Inc. All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- * 1. Redistributions of source code must retain the above copyright
- *    notice, this list of conditions and the following disclaimer.
- * 2. Redistributions in binary form must reproduce the above copyright
- *    notice, this list of conditions and the following disclaimer in the
- *    documentation and/or other materials provided with the distribution.
- *
- * THIS SOFTWARE IS PROVIDED BY APPLE INC. AND ITS CONTRIBUTORS ``AS IS''
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR ITS CONTRIBUTORS
- * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
- * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
- * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
- * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
- * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
- * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
- * THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-#include &quot;config.h&quot;
-#include &quot;JSFile.h&quot;
-
-#include &quot;JSDOMBinding.h&quot;
-#include &quot;JSDictionary.h&quot;
-#include &quot;ScriptExecutionContext.h&quot;
-#include &quot;WebKitBlobBuilder.h&quot;
-#include &lt;runtime/Error.h&gt;
-#include &lt;runtime/JSArray.h&gt;
-#include &lt;runtime/JSArrayBuffer.h&gt;
-#include &lt;runtime/JSArrayBufferView.h&gt;
-#include &lt;wtf/Assertions.h&gt;
-#include &lt;wtf/CurrentTime.h&gt;
-
-using namespace JSC;
-
-namespace WebCore {
-
-EncodedJSValue JSC_HOST_CALL constructJSFile(ExecState&amp; exec)
-{
-    VM&amp; vm = exec.vm();
-    auto scope = DECLARE_THROW_SCOPE(vm);
-
-    auto* constructor = jsCast&lt;DOMConstructorObject*&gt;(exec.callee());
-    ASSERT(constructor);
-
-    ScriptExecutionContext* context = constructor-&gt;scriptExecutionContext();
-    if (!context)
-        return throwConstructorScriptExecutionContextUnavailableError(exec, scope, &quot;File&quot;);
-    ASSERT(context-&gt;isDocument());
-
-    JSValue arg = exec.argument(0);
-    if (arg.isUndefinedOrNull())
-        return throwArgumentTypeError(exec, scope, 0, &quot;fileBits&quot;, &quot;File&quot;, nullptr, &quot;sequence&quot;);
-
-    unsigned blobPartsLength = 0;
-    JSObject* blobParts = toJSSequence(exec, arg, blobPartsLength);
-    RETURN_IF_EXCEPTION(scope, encodedJSValue());
-    ASSERT(blobParts);
-
-    arg = exec.argument(1);
-    if (arg.isUndefined())
-        return throwArgumentTypeError(exec, scope, 1, &quot;filename&quot;, &quot;File&quot;, nullptr, &quot;DOMString&quot;);
-
-    String filename = arg.toWTFString(&amp;exec).replace('/', ':');
-    RETURN_IF_EXCEPTION(scope, encodedJSValue());
-
-    String normalizedType;
-    std::optional&lt;int64_t&gt; lastModified;
-
-    arg = exec.argument(2);
-    if (!arg.isUndefinedOrNull()) {
-        JSObject* filePropertyBagObject = arg.getObject();
-        if (!filePropertyBagObject)
-            return throwArgumentTypeError(exec, scope, 2, &quot;options&quot;, &quot;File&quot;, nullptr, &quot;FilePropertyBag&quot;);
-
-        // Create the dictionary wrapper from the initializer object.
-        JSDictionary dictionary(&amp;exec, filePropertyBagObject);
-
-        // Attempt to get the type property.
-        String type;
-        dictionary.get(&quot;type&quot;, type);
-        RETURN_IF_EXCEPTION(scope, encodedJSValue());
-
-        normalizedType = Blob::normalizedContentType(type);
-
-        // Only try to parse the lastModified date if there was not an invalid type argument.
-        if (type.isEmpty() ||  !normalizedType.isEmpty()) {
-            dictionary.get(&quot;lastModified&quot;, lastModified);
-            RETURN_IF_EXCEPTION(scope, encodedJSValue());
-        }
-    }
-
-    if (!lastModified)
-        lastModified = currentTimeMS();
-
-    BlobBuilder blobBuilder;
-
-    for (unsigned i = 0; i &lt; blobPartsLength; ++i) {
-        JSValue item = blobParts-&gt;get(&amp;exec, i);
-        RETURN_IF_EXCEPTION(scope, encodedJSValue());
-
-        if (ArrayBuffer* arrayBuffer = toUnsharedArrayBuffer(item))
-            blobBuilder.append(arrayBuffer);
-        else if (RefPtr&lt;ArrayBufferView&gt; arrayBufferView = toUnsharedArrayBufferView(item))
-            blobBuilder.append(WTFMove(arrayBufferView));
-        else if (Blob* blob = JSBlob::toWrapped(item))
-            blobBuilder.append(blob);
-        else {
-            String string = item.toWTFString(&amp;exec);
-            RETURN_IF_EXCEPTION(scope, encodedJSValue());
-            blobBuilder.append(string, ASCIILiteral(&quot;transparent&quot;));
-        }
-    }
-
-    auto file = File::create(blobBuilder.finalize(), filename, normalizedType, lastModified.value());
-    return JSValue::encode(createWrapper&lt;File&gt;(constructor-&gt;globalObject(), WTFMove(file)));
-}
-
-} // namespace WebCore
-
</del></span></pre></div>
<a id="trunkSourceWebCorebindingsscriptsCodeGeneratorJSpm"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/scripts/CodeGeneratorJS.pm (209183 => 209184)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/scripts/CodeGeneratorJS.pm        2016-12-01 17:48:28 UTC (rev 209183)
+++ trunk/Source/WebCore/bindings/scripts/CodeGeneratorJS.pm        2016-12-01 18:04:58 UTC (rev 209184)
</span><span class="lines">@@ -1149,8 +1149,19 @@
</span><span class="cx"> 
</span><span class="cx"> sub GenerateDefaultValue
</span><span class="cx"> {
</span><del>-    my ($interface, $type, $defaultValue) = @_;
</del><ins>+    my ($interface, $context, $type, $defaultValue) = @_;
</ins><span class="cx"> 
</span><ins>+    if ($codeGenerator-&gt;IsStringType($type)) {
+        my $useAtomicString = $context-&gt;extendedAttributes-&gt;{AtomicString};
+        if ($defaultValue eq &quot;null&quot;) {
+            return $useAtomicString ? &quot;nullAtom&quot; : &quot;String()&quot;;
+        } elsif ($defaultValue eq &quot;\&quot;\&quot;&quot;) {
+            return $useAtomicString ? &quot;emptyAtom&quot; : &quot;emptyString()&quot;;
+        } else {
+            return $useAtomicString ? &quot;AtomicString(${defaultValue}, AtomicString::ConstructFromLiteral)&quot; : &quot;ASCIILiteral(${defaultValue})&quot;;
+        }
+    }
+
</ins><span class="cx">     if ($codeGenerator-&gt;IsEnumType($type)) {
</span><span class="cx">         # FIXME: Would be nice to report an error if the value does not have quote marks around it.
</span><span class="cx">         # FIXME: Would be nice to report an error if the value is not one of the enumeration values.
</span><span class="lines">@@ -1165,12 +1176,17 @@
</span><span class="cx">             my $IDLType = GetIDLType($interface, $type);
</span><span class="cx">             return &quot;convert&lt;${IDLType}&gt;(state, jsNull());&quot;;
</span><span class="cx">         }
</span><ins>+
</ins><span class="cx">         return &quot;jsNull()&quot; if $type-&gt;name eq &quot;any&quot;;
</span><span class="cx">         return &quot;nullptr&quot; if $codeGenerator-&gt;IsWrapperType($type) || $codeGenerator-&gt;IsTypedArrayType($type);
</span><span class="cx">         return &quot;String()&quot; if $codeGenerator-&gt;IsStringType($type);
</span><span class="cx">         return &quot;std::nullopt&quot;;
</span><span class="cx">     }
</span><ins>+
</ins><span class="cx">     if ($defaultValue eq &quot;[]&quot;) {
</span><ins>+        my $IDLType = GetIDLType($interface, $type);
+        return &quot;Converter&lt;${IDLType}&gt;::ReturnType{ }&quot; if $codeGenerator-&gt;IsSequenceOrFrozenArrayType($type);
+
</ins><span class="cx">         my $nativeType = GetNativeType($interface, $type);
</span><span class="cx">         return &quot;$nativeType()&quot;
</span><span class="cx">     }
</span><span class="lines">@@ -1288,7 +1304,7 @@
</span><span class="cx">             # 5.4. Otherwise, if value is undefined but the dictionary member has a default value, then:
</span><span class="cx">             if (!$member-&gt;isRequired &amp;&amp; defined $member-&gt;default) {
</span><span class="cx">                 $result .= &quot;    } else\n&quot;;
</span><del>-                $result .= &quot;        result.$key = &quot; . GenerateDefaultValue($interface, $member-&gt;type, $member-&gt;default) . &quot;;\n&quot;;
</del><ins>+                $result .= &quot;        result.$key = &quot; . GenerateDefaultValue($interface, $member, $member-&gt;type, $member-&gt;default) . &quot;;\n&quot;;
</ins><span class="cx">             } elsif ($member-&gt;isRequired) {
</span><span class="cx">                 # 5.5. Otherwise, if value is undefined and the dictionary member is a required dictionary member, then throw a TypeError.
</span><span class="cx">                 $result .= &quot;    } else {\n&quot;;
</span><span class="lines">@@ -4382,6 +4398,9 @@
</span><span class="cx">             # As per Web IDL, optional dictionary arguments are always considered to have a default value of an empty dictionary, unless otherwise specified.
</span><span class="cx">             $argument-&gt;default(&quot;[]&quot;) if $type-&gt;name eq &quot;Dictionary&quot; or $codeGenerator-&gt;IsDictionaryType($type);
</span><span class="cx"> 
</span><ins>+            # Treat undefined the same as an empty sequence Or frozen array.
+            $argument-&gt;default(&quot;[]&quot;) if $codeGenerator-&gt;IsSequenceOrFrozenArrayType($type);
+
</ins><span class="cx">             # We use undefined as default value for optional arguments of type 'any' unless specified otherwise.
</span><span class="cx">             $argument-&gt;default(&quot;undefined&quot;) if $type-&gt;name eq &quot;any&quot;;
</span><span class="cx"> 
</span><span class="lines">@@ -4436,7 +4455,7 @@
</span><span class="cx">                     push(@$outputArray, &quot;    if (!${name}Value.isUndefined()) {\n&quot;);
</span><span class="cx">                 } else {
</span><span class="cx">                     push(@$outputArray, &quot;    if (${name}Value.isUndefined())\n&quot;);
</span><del>-                    push(@$outputArray, &quot;        $name = &quot; . GenerateDefaultValue($interface, $argument-&gt;type, $argument-&gt;default) . &quot;;\n&quot;);
</del><ins>+                    push(@$outputArray, &quot;        $name = &quot; . GenerateDefaultValue($interface, $argument, $argument-&gt;type, $argument-&gt;default) . &quot;;\n&quot;);
</ins><span class="cx">                     push(@$outputArray, &quot;    else {\n&quot;);
</span><span class="cx">                 }
</span><span class="cx">                 $indent = &quot;    &quot;;
</span><span class="lines">@@ -4461,19 +4480,7 @@
</span><span class="cx">             if ($argument-&gt;isOptional &amp;&amp; defined($argument-&gt;default) &amp;&amp; !WillConvertUndefinedToDefaultParameterValue($type, $argument-&gt;default)) {
</span><span class="cx">                 my $defaultValue = $argument-&gt;default;
</span><span class="cx"> 
</span><del>-                # String-related optimizations.
-                if ($codeGenerator-&gt;IsStringType($type)) {
-                    my $useAtomicString = $argument-&gt;extendedAttributes-&gt;{AtomicString};
-                    if ($defaultValue eq &quot;null&quot;) {
-                        $defaultValue = $useAtomicString ? &quot;nullAtom&quot; : &quot;String()&quot;;
-                    } elsif ($defaultValue eq &quot;\&quot;\&quot;&quot;) {
-                        $defaultValue = $useAtomicString ? &quot;emptyAtom&quot; : &quot;emptyString()&quot;;
-                    } else {
-                        $defaultValue = $useAtomicString ? &quot;AtomicString($defaultValue, AtomicString::ConstructFromLiteral)&quot; : &quot;ASCIILiteral($defaultValue)&quot;;
-                    }
-                } else {
-                    $defaultValue = GenerateDefaultValue($interface, $argument-&gt;type, $argument-&gt;default);
-                }
</del><ins>+                $defaultValue = GenerateDefaultValue($interface, $argument, $argument-&gt;type, $argument-&gt;default);
</ins><span class="cx"> 
</span><span class="cx">                 $outer = &quot;state-&gt;$argumentLookupMethod($argumentIndex).isUndefined() ? $defaultValue : &quot;;
</span><span class="cx">                 $inner = &quot;state-&gt;uncheckedArgument($argumentIndex)&quot;;
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsscriptstestJSJSTestEventConstructorcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/scripts/test/JS/JSTestEventConstructor.cpp (209183 => 209184)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/scripts/test/JS/JSTestEventConstructor.cpp        2016-12-01 17:48:28 UTC (rev 209183)
+++ trunk/Source/WebCore/bindings/scripts/test/JS/JSTestEventConstructor.cpp        2016-12-01 18:04:58 UTC (rev 209184)
</span><span class="lines">@@ -68,13 +68,13 @@
</span><span class="cx">         result.attr2 = convert&lt;IDLDOMString&gt;(state, attr2Value);
</span><span class="cx">         RETURN_IF_EXCEPTION(throwScope, { });
</span><span class="cx">     } else
</span><del>-        result.attr2 = &quot;&quot;;
</del><ins>+        result.attr2 = emptyString();
</ins><span class="cx">     JSValue attr3Value = isNullOrUndefined ? jsUndefined() : object-&gt;get(&amp;state, Identifier::fromString(&amp;state, &quot;attr3&quot;));
</span><span class="cx">     if (!attr3Value.isUndefined()) {
</span><span class="cx">         result.attr3 = convert&lt;IDLDOMString&gt;(state, attr3Value);
</span><span class="cx">         RETURN_IF_EXCEPTION(throwScope, { });
</span><span class="cx">     } else
</span><del>-        result.attr3 = &quot;&quot;;
</del><ins>+        result.attr3 = emptyString();
</ins><span class="cx">     return result;
</span><span class="cx"> }
</span><span class="cx"> 
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsscriptstestJSJSTestObjcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/scripts/test/JS/JSTestObj.cpp (209183 => 209184)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/scripts/test/JS/JSTestObj.cpp        2016-12-01 17:48:28 UTC (rev 209183)
+++ trunk/Source/WebCore/bindings/scripts/test/JS/JSTestObj.cpp        2016-12-01 18:04:58 UTC (rev 209184)
</span><span class="lines">@@ -624,7 +624,7 @@
</span><span class="cx">         result.stringWithDefault = convert&lt;IDLDOMString&gt;(state, stringWithDefaultValue);
</span><span class="cx">         RETURN_IF_EXCEPTION(throwScope, { });
</span><span class="cx">     } else
</span><del>-        result.stringWithDefault = &quot;defaultString&quot;;
</del><ins>+        result.stringWithDefault = ASCIILiteral(&quot;defaultString&quot;);
</ins><span class="cx">     JSValue stringWithoutDefaultValue = isNullOrUndefined ? jsUndefined() : object-&gt;get(&amp;state, Identifier::fromString(&amp;state, &quot;stringWithoutDefault&quot;));
</span><span class="cx">     if (!stringWithoutDefaultValue.isUndefined()) {
</span><span class="cx">         result.stringWithoutDefault = convert&lt;IDLDOMString&gt;(state, stringWithoutDefaultValue);
</span><span class="lines">@@ -6355,7 +6355,7 @@
</span><span class="cx">     UNUSED_PARAM(state);
</span><span class="cx">     UNUSED_PARAM(throwScope);
</span><span class="cx">     auto&amp; impl = castedThis-&gt;wrapped();
</span><del>-    auto array = state-&gt;argument(0).isUndefined() ? std::optional&lt;Vector&lt;String&gt;&gt;() : convert&lt;IDLSequence&lt;IDLDOMString&gt;&gt;(*state, state-&gt;uncheckedArgument(0));
</del><ins>+    auto array = state-&gt;argument(0).isUndefined() ? Converter&lt;IDLSequence&lt;IDLDOMString&gt;&gt;::ReturnType{ } : convert&lt;IDLSequence&lt;IDLDOMString&gt;&gt;(*state, state-&gt;uncheckedArgument(0));
</ins><span class="cx">     RETURN_IF_EXCEPTION(throwScope, encodedJSValue());
</span><span class="cx">     impl.methodWithOptionalSequence(WTFMove(array));
</span><span class="cx">     return JSValue::encode(jsUndefined());
</span><span class="lines">@@ -6373,7 +6373,7 @@
</span><span class="cx">     UNUSED_PARAM(state);
</span><span class="cx">     UNUSED_PARAM(throwScope);
</span><span class="cx">     auto&amp; impl = castedThis-&gt;wrapped();
</span><del>-    auto array = state-&gt;argument(0).isUndefined() ? Vector&lt;String&gt;() : convert&lt;IDLSequence&lt;IDLDOMString&gt;&gt;(*state, state-&gt;uncheckedArgument(0));
</del><ins>+    auto array = state-&gt;argument(0).isUndefined() ? Converter&lt;IDLSequence&lt;IDLDOMString&gt;&gt;::ReturnType{ } : convert&lt;IDLSequence&lt;IDLDOMString&gt;&gt;(*state, state-&gt;uncheckedArgument(0));
</ins><span class="cx">     RETURN_IF_EXCEPTION(throwScope, encodedJSValue());
</span><span class="cx">     impl.methodWithOptionalSequenceIsEmpty(WTFMove(array));
</span><span class="cx">     return JSValue::encode(jsUndefined());
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsscriptstestJSJSTestOverloadedConstructorsWithSequencecpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/scripts/test/JS/JSTestOverloadedConstructorsWithSequence.cpp (209183 => 209184)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/scripts/test/JS/JSTestOverloadedConstructorsWithSequence.cpp        2016-12-01 17:48:28 UTC (rev 209183)
+++ trunk/Source/WebCore/bindings/scripts/test/JS/JSTestOverloadedConstructorsWithSequence.cpp        2016-12-01 18:04:58 UTC (rev 209184)
</span><span class="lines">@@ -72,7 +72,7 @@
</span><span class="cx">     UNUSED_PARAM(throwScope);
</span><span class="cx">     auto* castedThis = jsCast&lt;JSTestOverloadedConstructorsWithSequenceConstructor*&gt;(state-&gt;callee());
</span><span class="cx">     ASSERT(castedThis);
</span><del>-    auto sequenceOfStrings = state-&gt;argument(0).isUndefined() ? Vector&lt;String&gt;() : convert&lt;IDLSequence&lt;IDLDOMString&gt;&gt;(*state, state-&gt;uncheckedArgument(0));
</del><ins>+    auto sequenceOfStrings = state-&gt;argument(0).isUndefined() ? Converter&lt;IDLSequence&lt;IDLDOMString&gt;&gt;::ReturnType{ } : convert&lt;IDLSequence&lt;IDLDOMString&gt;&gt;(*state, state-&gt;uncheckedArgument(0));
</ins><span class="cx">     RETURN_IF_EXCEPTION(throwScope, encodedJSValue());
</span><span class="cx">     auto object = TestOverloadedConstructorsWithSequence::create(WTFMove(sequenceOfStrings));
</span><span class="cx">     return JSValue::encode(toJSNewlyCreated(state, castedThis-&gt;globalObject(), WTFMove(object)));
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsscriptstestJSJSTestTypedefscpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/scripts/test/JS/JSTestTypedefs.cpp (209183 => 209184)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/scripts/test/JS/JSTestTypedefs.cpp        2016-12-01 17:48:28 UTC (rev 209183)
+++ trunk/Source/WebCore/bindings/scripts/test/JS/JSTestTypedefs.cpp        2016-12-01 18:04:58 UTC (rev 209184)
</span><span class="lines">@@ -498,7 +498,7 @@
</span><span class="cx">     UNUSED_PARAM(state);
</span><span class="cx">     UNUSED_PARAM(throwScope);
</span><span class="cx">     auto&amp; impl = castedThis-&gt;wrapped();
</span><del>-    auto x = state-&gt;argument(0).isUndefined() ? Vector&lt;int32_t&gt;() : convert&lt;IDLSequence&lt;IDLLong&gt;&gt;(*state, state-&gt;uncheckedArgument(0));
</del><ins>+    auto x = state-&gt;argument(0).isUndefined() ? Converter&lt;IDLSequence&lt;IDLLong&gt;&gt;::ReturnType{ } : convert&lt;IDLSequence&lt;IDLLong&gt;&gt;(*state, state-&gt;uncheckedArgument(0));
</ins><span class="cx">     RETURN_IF_EXCEPTION(throwScope, encodedJSValue());
</span><span class="cx">     impl.func(WTFMove(x));
</span><span class="cx">     return JSValue::encode(jsUndefined());
</span></span></pre></div>
<a id="trunkSourceWebCorefileapiBlobcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/fileapi/Blob.cpp (209183 => 209184)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/fileapi/Blob.cpp        2016-12-01 17:48:28 UTC (rev 209183)
+++ trunk/Source/WebCore/fileapi/Blob.cpp        2016-12-01 18:04:58 UTC (rev 209184)
</span><span class="lines">@@ -31,6 +31,8 @@
</span><span class="cx"> #include &quot;config.h&quot;
</span><span class="cx"> #include &quot;Blob.h&quot;
</span><span class="cx"> 
</span><ins>+#include &quot;BlobBuilder.h&quot;
+#include &quot;BlobPart.h&quot;
</ins><span class="cx"> #include &quot;BlobURL.h&quot;
</span><span class="cx"> #include &quot;File.h&quot;
</span><span class="cx"> #include &quot;ScriptExecutionContext.h&quot;
</span><span class="lines">@@ -74,9 +76,26 @@
</span><span class="cx">     : m_size(0)
</span><span class="cx"> {
</span><span class="cx">     m_internalURL = BlobURL::createInternalURL();
</span><del>-    ThreadableBlobRegistry::registerBlobURL(m_internalURL, Vector&lt;BlobPart&gt;(), String());
</del><ins>+    ThreadableBlobRegistry::registerBlobURL(m_internalURL, { },  { });
</ins><span class="cx"> }
</span><span class="cx"> 
</span><ins>+Blob::Blob(Vector&lt;BlobPartVariant&gt;&amp;&amp; blobPartVariants, const BlobPropertyBag&amp; propertyBag)
+    : m_internalURL(BlobURL::createInternalURL())
+    , m_type(normalizedContentType(propertyBag.type))
+    , m_size(-1)
+{
+    BlobBuilder builder(propertyBag.endings);
+    for (auto&amp; blobPartVariant : blobPartVariants) {
+        WTF::switchOn(blobPartVariant,
+            [&amp;] (auto&amp; part) {
+                builder.append(WTFMove(part));
+            }
+        );
+    }
+
+    ThreadableBlobRegistry::registerBlobURL(m_internalURL, builder.finalize(), m_type);
+}
+
</ins><span class="cx"> Blob::Blob(Vector&lt;uint8_t&gt;&amp;&amp; data, const String&amp; contentType)
</span><span class="cx">     : m_type(contentType)
</span><span class="cx">     , m_size(data.size())
</span><span class="lines">@@ -87,14 +106,6 @@
</span><span class="cx">     ThreadableBlobRegistry::registerBlobURL(m_internalURL, WTFMove(blobParts), contentType);
</span><span class="cx"> }
</span><span class="cx"> 
</span><del>-Blob::Blob(Vector&lt;BlobPart&gt;&amp;&amp; blobParts, const String&amp; contentType)
-    : m_type(contentType)
-    , m_size(-1)
-{
-    m_internalURL = BlobURL::createInternalURL();
-    ThreadableBlobRegistry::registerBlobURL(m_internalURL, WTFMove(blobParts), contentType);
-}
-
</del><span class="cx"> Blob::Blob(DeserializationContructor, const URL&amp; srcURL, const String&amp; type, long long size, const String&amp; fileBackedPath)
</span><span class="cx">     : m_type(normalizedContentType(type))
</span><span class="cx">     , m_size(size)
</span></span></pre></div>
<a id="trunkSourceWebCorefileapiBlobh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/fileapi/Blob.h (209183 => 209184)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/fileapi/Blob.h        2016-12-01 17:48:28 UTC (rev 209183)
+++ trunk/Source/WebCore/fileapi/Blob.h        2016-12-01 18:04:58 UTC (rev 209184)
</span><span class="lines">@@ -30,16 +30,24 @@
</span><span class="cx"> 
</span><span class="cx"> #pragma once
</span><span class="cx"> 
</span><del>-#include &quot;BlobPart.h&quot;
</del><ins>+#include &quot;BlobPropertyBag.h&quot;
</ins><span class="cx"> #include &quot;ScriptWrappable.h&quot;
</span><ins>+#include &quot;URL.h&quot;
</ins><span class="cx"> #include &quot;URLRegistry.h&quot;
</span><del>-#include &lt;wtf/RefCounted.h&gt;
-#include &lt;wtf/text/WTFString.h&gt;
</del><ins>+#include &lt;wtf/Variant.h&gt;
</ins><span class="cx"> 
</span><ins>+namespace JSC {
+class ArrayBufferView;
+class ArrayBuffer;
+}
+
</ins><span class="cx"> namespace WebCore {
</span><span class="cx"> 
</span><ins>+class Blob;
</ins><span class="cx"> class ScriptExecutionContext;
</span><span class="cx"> 
</span><ins>+using BlobPartVariant = Variant&lt;RefPtr&lt;JSC::ArrayBufferView&gt;, RefPtr&lt;JSC::ArrayBuffer&gt;, RefPtr&lt;Blob&gt;, String&gt;;
+
</ins><span class="cx"> class Blob : public ScriptWrappable, public URLRegistrable, public RefCounted&lt;Blob&gt; {
</span><span class="cx"> public:
</span><span class="cx">     static Ref&lt;Blob&gt; create()
</span><span class="lines">@@ -47,14 +55,14 @@
</span><span class="cx">         return adoptRef(*new Blob);
</span><span class="cx">     }
</span><span class="cx"> 
</span><del>-    static Ref&lt;Blob&gt; create(Vector&lt;uint8_t&gt;&amp;&amp; data, const String&amp; contentType)
</del><ins>+    static Ref&lt;Blob&gt; create(Vector&lt;BlobPartVariant&gt;&amp;&amp; blobPartVariants, const BlobPropertyBag&amp; propertyBag)
</ins><span class="cx">     {
</span><del>-        return adoptRef(*new Blob(WTFMove(data), contentType));
</del><ins>+        return adoptRef(*new Blob(WTFMove(blobPartVariants), propertyBag));
</ins><span class="cx">     }
</span><span class="cx"> 
</span><del>-    static Ref&lt;Blob&gt; create(Vector&lt;BlobPart&gt;&amp;&amp; blobParts, const String&amp; contentType)
</del><ins>+    static Ref&lt;Blob&gt; create(Vector&lt;uint8_t&gt;&amp;&amp; data, const String&amp; contentType)
</ins><span class="cx">     {
</span><del>-        return adoptRef(*new Blob(WTFMove(blobParts), contentType));
</del><ins>+        return adoptRef(*new Blob(WTFMove(data), contentType));
</ins><span class="cx">     }
</span><span class="cx"> 
</span><span class="cx">     static Ref&lt;Blob&gt; deserialize(const URL&amp; srcURL, const String&amp; type, long long size, const String&amp; fileBackedPath)
</span><span class="lines">@@ -90,8 +98,8 @@
</span><span class="cx"> 
</span><span class="cx"> protected:
</span><span class="cx">     Blob();
</span><ins>+    Blob(Vector&lt;BlobPartVariant&gt;&amp;&amp;, const BlobPropertyBag&amp;);
</ins><span class="cx">     Blob(Vector&lt;uint8_t&gt;&amp;&amp;, const String&amp; contentType);
</span><del>-    Blob(Vector&lt;BlobPart&gt;&amp;&amp;, const String&amp; contentType);
</del><span class="cx"> 
</span><span class="cx">     enum UninitializedContructor { uninitializedContructor };
</span><span class="cx">     Blob(UninitializedContructor);
</span></span></pre></div>
<a id="trunkSourceWebCorefileapiBlobidl"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/fileapi/Blob.idl (209183 => 209184)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/fileapi/Blob.idl        2016-12-01 17:48:28 UTC (rev 209183)
+++ trunk/Source/WebCore/fileapi/Blob.idl        2016-12-01 18:04:58 UTC (rev 209184)
</span><span class="lines">@@ -28,16 +28,23 @@
</span><span class="cx">  * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
</span><span class="cx">  */
</span><span class="cx"> 
</span><ins>+typedef (ArrayBufferView or ArrayBuffer) BufferSource;
+typedef (BufferSource or Blob or USVString) BlobPart;
+
</ins><span class="cx"> [
</span><span class="cx">     Exposed=(Window,Worker),
</span><span class="cx">     GenerateIsReachable=Impl,
</span><span class="cx">     CustomToJSObject,
</span><del>-    CustomConstructor,
-    CustomConstructor(sequence&lt;any&gt; blobParts, optional BlobPropertyBag options),
</del><ins>+    Constructor(optional sequence&lt;BlobPart&gt; blobParts, optional BlobPropertyBag options),
</ins><span class="cx"> ] interface Blob {
</span><span class="cx">     readonly attribute unsigned long long size;
</span><span class="cx">     readonly attribute DOMString type;
</span><span class="cx"> 
</span><ins>+    // slice Blob into byte-ranged chunks
</ins><span class="cx">     Blob slice(optional long long start = 0, optional long long end = 0x7FFFFFFFFFFFFFFF, optional DOMString? contentType = null);
</span><ins>+
+    // FIXME: Implement:
+    // readonly attribute boolean isClosed;
+    // void close();
+
</ins><span class="cx"> };
</span><del>-
</del></span></pre></div>
<a id="trunkSourceWebCorefileapiBlobBuildercppfromrev209152trunkSourceWebCorefileapiWebKitBlobBuildercpp"></a>
<div class="copfile"><h4>Copied: trunk/Source/WebCore/fileapi/BlobBuilder.cpp (from rev 209152, trunk/Source/WebCore/fileapi/WebKitBlobBuilder.cpp) (0 => 209184)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/fileapi/BlobBuilder.cpp                                (rev 0)
+++ trunk/Source/WebCore/fileapi/BlobBuilder.cpp        2016-12-01 18:04:58 UTC (rev 209184)
</span><span class="lines">@@ -0,0 +1,90 @@
</span><ins>+/*
+ * Copyright (C) 2010 Google Inc. All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions are
+ * met:
+ *
+ *     * Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ *     * Redistributions in binary form must reproduce the above
+ * copyright notice, this list of conditions and the following disclaimer
+ * in the documentation and/or other materials provided with the
+ * distribution.
+ *     * Neither the name of Google Inc. nor the names of its
+ * contributors may be used to endorse or promote products derived from
+ * this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+ * &quot;AS IS&quot; AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+ * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+ * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+ * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+ * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+ * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+ * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+ * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+ * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+#include &quot;config.h&quot;
+#include &quot;BlobBuilder.h&quot;
+
+#include &quot;Blob.h&quot;
+#include &quot;LineEnding.h&quot;
+#include &quot;TextEncoding.h&quot;
+#include &lt;runtime/ArrayBuffer.h&gt;
+#include &lt;runtime/ArrayBufferView.h&gt;
+#include &lt;wtf/text/CString.h&gt;
+
+namespace WebCore {
+
+BlobBuilder::BlobBuilder(BlobLineEndings endings)
+    : m_endings(endings)
+{
+}
+
+void BlobBuilder::append(RefPtr&lt;ArrayBuffer&gt;&amp;&amp; arrayBuffer)
+{
+    if (!arrayBuffer)
+        return;
+    m_appendableData.append(static_cast&lt;const char*&gt;(arrayBuffer-&gt;data()), arrayBuffer-&gt;byteLength());
+}
+
+void BlobBuilder::append(RefPtr&lt;ArrayBufferView&gt;&amp;&amp; arrayBufferView)
+{
+    if (!arrayBufferView)
+        return;
+    m_appendableData.append(static_cast&lt;const char*&gt;(arrayBufferView-&gt;baseAddress()), arrayBufferView-&gt;byteLength());
+}
+
+void BlobBuilder::append(RefPtr&lt;Blob&gt;&amp;&amp; blob)
+{
+    if (!blob)
+        return;
+    if (!m_appendableData.isEmpty())
+        m_items.append(BlobPart(WTFMove(m_appendableData)));
+    m_items.append(BlobPart(blob-&gt;url()));
+}
+
+void BlobBuilder::append(const String&amp; text)
+{
+    CString utf8Text = UTF8Encoding().encode(text, EntitiesForUnencodables);
+
+    if (m_endings == BlobLineEndings::Native)
+        normalizeLineEndingsToNative(utf8Text, m_appendableData);
+    else {
+        ASSERT(m_endings == BlobLineEndings::Transparent);
+        m_appendableData.append(utf8Text.data(), utf8Text.length());
+    }
+}
+
+Vector&lt;BlobPart&gt; BlobBuilder::finalize()
+{
+    if (!m_appendableData.isEmpty())
+        m_items.append(BlobPart(WTFMove(m_appendableData)));
+    return WTFMove(m_items);
+}
+
+} // namespace WebCore
</ins></span></pre></div>
<a id="trunkSourceWebCorefileapiBlobBuilderhfromrev209152trunkSourceWebCorefileapiWebKitBlobBuilderh"></a>
<div class="copfile"><h4>Copied: trunk/Source/WebCore/fileapi/BlobBuilder.h (from rev 209152, trunk/Source/WebCore/fileapi/WebKitBlobBuilder.h) (0 => 209184)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/fileapi/BlobBuilder.h                                (rev 0)
+++ trunk/Source/WebCore/fileapi/BlobBuilder.h        2016-12-01 18:04:58 UTC (rev 209184)
</span><span class="lines">@@ -0,0 +1,62 @@
</span><ins>+/*
+ * Copyright (C) 2010 Google Inc. All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions are
+ * met:
+ *
+ *     * Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ *     * Redistributions in binary form must reproduce the above
+ * copyright notice, this list of conditions and the following disclaimer
+ * in the documentation and/or other materials provided with the
+ * distribution.
+ *     * Neither the name of Google Inc. nor the names of its
+ * contributors may be used to endorse or promote products derived from
+ * this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+ * &quot;AS IS&quot; AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+ * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+ * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+ * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+ * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+ * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+ * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+ * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+ * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+#pragma once
+
+#include &quot;BlobPart.h&quot;
+#include &quot;BlobPropertyBag.h&quot;
+
+namespace JSC {
+class ArrayBuffer;
+class ArrayBufferView;
+}
+
+namespace WebCore {
+
+class Blob;
+
+class BlobBuilder {
+public:
+    BlobBuilder(BlobLineEndings);
+
+    void append(RefPtr&lt;JSC::ArrayBuffer&gt;&amp;&amp;);
+    void append(RefPtr&lt;JSC::ArrayBufferView&gt;&amp;&amp;);
+    void append(RefPtr&lt;Blob&gt;&amp;&amp;);
+    void append(const String&amp; text);
+
+    Vector&lt;BlobPart&gt; finalize();
+
+private:
+    BlobLineEndings m_endings;
+    Vector&lt;BlobPart&gt; m_items;
+    Vector&lt;uint8_t&gt; m_appendableData;
+};
+
+} // namespace WebCore
</ins></span></pre></div>
<a id="trunkSourceWebCorefileapiBlobLineEndingsh"></a>
<div class="addfile"><h4>Added: trunk/Source/WebCore/fileapi/BlobLineEndings.h (0 => 209184)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/fileapi/BlobLineEndings.h                                (rev 0)
+++ trunk/Source/WebCore/fileapi/BlobLineEndings.h        2016-12-01 18:04:58 UTC (rev 209184)
</span><span class="lines">@@ -0,0 +1,35 @@
</span><ins>+/*
+ * Copyright (C) 2016 Apple Inc. All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ * 1. Redistributions of source code must retain the above copyright
+ *    notice, this list of conditions and the following disclaimer.
+ * 2. Redistributions in binary form must reproduce the above copyright
+ *    notice, this list of conditions and the following disclaimer in the
+ *    documentation and/or other materials provided with the distribution.
+ *
+ * THIS SOFTWARE IS PROVIDED BY APPLE INC. AND ITS CONTRIBUTORS ``AS IS''
+ * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
+ * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
+ * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR ITS CONTRIBUTORS
+ * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
+ * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
+ * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
+ * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
+ * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
+ * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
+ * THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+#pragma once
+
+namespace WebCore {
+
+enum class BlobLineEndings {
+    Transparent,
+    Native
+};
+
+}
</ins></span></pre></div>
<a id="trunkSourceWebCorefileapiBlobLineEndingsidl"></a>
<div class="addfile"><h4>Added: trunk/Source/WebCore/fileapi/BlobLineEndings.idl (0 => 209184)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/fileapi/BlobLineEndings.idl                                (rev 0)
+++ trunk/Source/WebCore/fileapi/BlobLineEndings.idl        2016-12-01 18:04:58 UTC (rev 209184)
</span><span class="lines">@@ -0,0 +1,27 @@
</span><ins>+/*
+ * Copyright (C) 2016 Apple Inc. All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ * 1. Redistributions of source code must retain the above copyright
+ *    notice, this list of conditions and the following disclaimer.
+ * 2. Redistributions in binary form must reproduce the above copyright
+ *    notice, this list of conditions and the following disclaimer in the
+ *    documentation and/or other materials provided with the distribution.
+ *
+ * THIS SOFTWARE IS PROVIDED BY APPLE INC. AND ITS CONTRIBUTORS ``AS IS''
+ * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
+ * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
+ * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR ITS CONTRIBUTORS
+ * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
+ * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
+ * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
+ * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
+ * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
+ * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
+ * THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+// FIXME: This is no longer in the FileAPI spec.
+enum BlobLineEndings { &quot;transparent&quot;, &quot;native&quot; };
</ins></span></pre></div>
<a id="trunkSourceWebCorefileapiBlobPropertyBagh"></a>
<div class="addfile"><h4>Added: trunk/Source/WebCore/fileapi/BlobPropertyBag.h (0 => 209184)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/fileapi/BlobPropertyBag.h                                (rev 0)
+++ trunk/Source/WebCore/fileapi/BlobPropertyBag.h        2016-12-01 18:04:58 UTC (rev 209184)
</span><span class="lines">@@ -0,0 +1,38 @@
</span><ins>+/*
+ * Copyright (C) 2016 Apple Inc. All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ * 1. Redistributions of source code must retain the above copyright
+ *    notice, this list of conditions and the following disclaimer.
+ * 2. Redistributions in binary form must reproduce the above copyright
+ *    notice, this list of conditions and the following disclaimer in the
+ *    documentation and/or other materials provided with the distribution.
+ *
+ * THIS SOFTWARE IS PROVIDED BY APPLE INC. AND ITS CONTRIBUTORS ``AS IS''
+ * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
+ * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
+ * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR ITS CONTRIBUTORS
+ * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
+ * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
+ * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
+ * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
+ * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
+ * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
+ * THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+#pragma once
+
+#include &quot;BlobLineEndings.h&quot;
+#include &lt;wtf/text/WTFString.h&gt;
+
+namespace WebCore {
+
+struct BlobPropertyBag {
+    String type;
+    BlobLineEndings endings = BlobLineEndings::Transparent;
+};
+
+}
</ins></span></pre></div>
<a id="trunkSourceWebCorefileapiBlobPropertyBagidl"></a>
<div class="addfile"><h4>Added: trunk/Source/WebCore/fileapi/BlobPropertyBag.idl (0 => 209184)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/fileapi/BlobPropertyBag.idl                                (rev 0)
+++ trunk/Source/WebCore/fileapi/BlobPropertyBag.idl        2016-12-01 18:04:58 UTC (rev 209184)
</span><span class="lines">@@ -0,0 +1,31 @@
</span><ins>+/*
+ * Copyright (C) 2016 Apple Inc. All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ * 1. Redistributions of source code must retain the above copyright
+ *    notice, this list of conditions and the following disclaimer.
+ * 2. Redistributions in binary form must reproduce the above copyright
+ *    notice, this list of conditions and the following disclaimer in the
+ *    documentation and/or other materials provided with the distribution.
+ *
+ * THIS SOFTWARE IS PROVIDED BY APPLE INC. AND ITS CONTRIBUTORS ``AS IS''
+ * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
+ * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
+ * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR ITS CONTRIBUTORS
+ * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
+ * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
+ * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
+ * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
+ * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
+ * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
+ * THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+dictionary BlobPropertyBag {
+    DOMString type = &quot;&quot;;
+
+    // FIXME: This is no longer in the FileAPI spec.
+    BlobLineEndings endings = &quot;transparent&quot;;
+};
</ins></span></pre></div>
<a id="trunkSourceWebCorefileapiFilecpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/fileapi/File.cpp (209183 => 209184)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/fileapi/File.cpp        2016-12-01 17:48:28 UTC (rev 209183)
+++ trunk/Source/WebCore/fileapi/File.cpp        2016-12-01 18:04:58 UTC (rev 209184)
</span><span class="lines">@@ -64,10 +64,17 @@
</span><span class="cx"> {
</span><span class="cx"> }
</span><span class="cx"> 
</span><del>-File::File(Vector&lt;BlobPart&gt;&amp;&amp; blobParts, const String&amp; filename, const String&amp; contentType, int64_t lastModified)
-    : Blob(WTFMove(blobParts), contentType)
</del><ins>+static BlobPropertyBag convertPropertyBag(const File::PropertyBag&amp; initialBag)
+{
+    BlobPropertyBag bag;
+    bag.type = initialBag.type;
+    return bag;
+}
+
+File::File(Vector&lt;BlobPartVariant&gt;&amp;&amp; blobPartVariants, const String&amp; filename, const PropertyBag&amp; propertyBag)
+    : Blob(WTFMove(blobPartVariants), convertPropertyBag(propertyBag))
</ins><span class="cx">     , m_name(filename)
</span><del>-    , m_overrideLastModifiedDate(lastModified)
</del><ins>+    , m_overrideLastModifiedDate(propertyBag.lastModified.value_or(currentTimeMS()))
</ins><span class="cx"> {
</span><span class="cx"> }
</span><span class="cx"> 
</span></span></pre></div>
<a id="trunkSourceWebCorefileapiFileh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/fileapi/File.h (209183 => 209184)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/fileapi/File.h        2016-12-01 17:48:28 UTC (rev 209183)
+++ trunk/Source/WebCore/fileapi/File.h        2016-12-01 18:04:58 UTC (rev 209184)
</span><span class="lines">@@ -37,6 +37,10 @@
</span><span class="cx"> 
</span><span class="cx"> class File final : public Blob {
</span><span class="cx"> public:
</span><ins>+    struct PropertyBag : BlobPropertyBag {
+        std::optional&lt;long long&gt; lastModified;
+    };
+
</ins><span class="cx">     static Ref&lt;File&gt; create(const String&amp; path)
</span><span class="cx">     {
</span><span class="cx">         return adoptRef(*new File(path));
</span><span class="lines">@@ -43,9 +47,9 @@
</span><span class="cx">     }
</span><span class="cx"> 
</span><span class="cx">     // Create a File using the 'new File' constructor.
</span><del>-    static Ref&lt;File&gt; create(Vector&lt;BlobPart&gt; blobParts, const String&amp; filename, const String&amp; contentType, int64_t lastModified)
</del><ins>+    static Ref&lt;File&gt; create(Vector&lt;BlobPartVariant&gt;&amp;&amp; blobPartVariants, const String&amp; filename, const PropertyBag&amp; propertyBag)
</ins><span class="cx">     {
</span><del>-        return adoptRef(*new File(WTFMove(blobParts), filename, contentType, lastModified));
</del><ins>+        return adoptRef(*new File(WTFMove(blobPartVariants), filename, propertyBag));
</ins><span class="cx">     }
</span><span class="cx"> 
</span><span class="cx">     static Ref&lt;File&gt; deserialize(const String&amp; path, const URL&amp; srcURL, const String&amp; type, const String&amp; name)
</span><span class="lines">@@ -76,7 +80,7 @@
</span><span class="cx"> private:
</span><span class="cx">     WEBCORE_EXPORT explicit File(const String&amp; path);
</span><span class="cx">     File(const String&amp; path, const String&amp; nameOverride);
</span><del>-    File(Vector&lt;BlobPart&gt;&amp;&amp; blobParts, const String&amp; filename, const String&amp; contentType, int64_t lastModified);
</del><ins>+    File(Vector&lt;BlobPartVariant&gt;&amp;&amp; blobPartVariants, const String&amp; filename, const PropertyBag&amp;);
</ins><span class="cx"> 
</span><span class="cx">     File(DeserializationContructor, const String&amp; path, const URL&amp; srcURL, const String&amp; type, const String&amp; name);
</span><span class="cx"> 
</span></span></pre></div>
<a id="trunkSourceWebCorefileapiFileidl"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/fileapi/File.idl (209183 => 209184)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/fileapi/File.idl        2016-12-01 17:48:28 UTC (rev 209183)
+++ trunk/Source/WebCore/fileapi/File.idl        2016-12-01 18:04:58 UTC (rev 209184)
</span><span class="lines">@@ -23,14 +23,21 @@
</span><span class="cx">  * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 
</span><span class="cx">  */
</span><span class="cx"> 
</span><ins>+typedef (ArrayBufferView or ArrayBuffer) BufferSource;
+typedef (BufferSource or Blob or USVString) BlobPart;
+
+// FIXME: This should be exposed on Workers as well.
</ins><span class="cx"> [
</span><ins>+    Constructor(sequence&lt;BlobPart&gt; fileBits, USVString fileName, optional FilePropertyBag options),
+    ExportMacro=WEBCORE_EXPORT,
</ins><span class="cx">     Exposed=(Window),
</span><ins>+    JSGenerateToJSObject,
</ins><span class="cx">     JSGenerateToNativeObject,
</span><del>-    JSGenerateToJSObject,
-    ExportMacro=WEBCORE_EXPORT,
-    CustomConstructor(sequence&lt;any&gt; fileBits, DOMString fileName, optional FilePropertyBag options),
</del><span class="cx"> ] interface File : Blob {
</span><span class="cx">     readonly attribute DOMString name;
</span><span class="cx">     readonly attribute long long lastModified;
</span><span class="cx"> };
</span><span class="cx"> 
</span><ins>+dictionary FilePropertyBag : BlobPropertyBag {
+    long long lastModified;
+};
</ins></span></pre></div>
<a id="trunkSourceWebCorefileapiThreadableBlobRegistrycpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/fileapi/ThreadableBlobRegistry.cpp (209183 => 209184)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/fileapi/ThreadableBlobRegistry.cpp        2016-12-01 17:48:28 UTC (rev 209183)
+++ trunk/Source/WebCore/fileapi/ThreadableBlobRegistry.cpp        2016-12-01 18:04:58 UTC (rev 209184)
</span><span class="lines">@@ -92,7 +92,7 @@
</span><span class="cx">     }
</span><span class="cx"> }
</span><span class="cx"> 
</span><del>-void ThreadableBlobRegistry::registerBlobURL(const URL&amp; url, Vector&lt;BlobPart&gt; blobParts, const String&amp; contentType)
</del><ins>+void ThreadableBlobRegistry::registerBlobURL(const URL&amp; url, Vector&lt;BlobPart&gt;&amp;&amp; blobParts, const String&amp; contentType)
</ins><span class="cx"> {
</span><span class="cx">     if (isMainThread())
</span><span class="cx">         blobRegistry().registerBlobURL(url, WTFMove(blobParts), contentType);
</span></span></pre></div>
<a id="trunkSourceWebCorefileapiThreadableBlobRegistryh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/fileapi/ThreadableBlobRegistry.h (209183 => 209184)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/fileapi/ThreadableBlobRegistry.h        2016-12-01 17:48:28 UTC (rev 209183)
+++ trunk/Source/WebCore/fileapi/ThreadableBlobRegistry.h        2016-12-01 18:04:58 UTC (rev 209184)
</span><span class="lines">@@ -43,7 +43,7 @@
</span><span class="cx"> class ThreadableBlobRegistry {
</span><span class="cx"> public:
</span><span class="cx">     static void registerFileBlobURL(const URL&amp;, const String&amp; path, const String&amp; contentType);
</span><del>-    static void registerBlobURL(const URL&amp;, Vector&lt;BlobPart&gt; blobParts, const String&amp; contentType);
</del><ins>+    static void registerBlobURL(const URL&amp;, Vector&lt;BlobPart&gt;&amp;&amp; blobParts, const String&amp; contentType);
</ins><span class="cx">     static void registerBlobURL(SecurityOrigin*, const URL&amp;, const URL&amp; srcURL);
</span><span class="cx">     static void registerBlobURLOptionallyFileBacked(const URL&amp;, const URL&amp; srcURL, const String&amp; fileBackedPath, const String&amp; contentType);
</span><span class="cx">     static void registerBlobURLForSlice(const URL&amp; newURL, const URL&amp; srcURL, long long start, long long end);
</span></span></pre></div>
<a id="trunkSourceWebCorefileapiWebKitBlobBuildercpp"></a>
<div class="delfile"><h4>Deleted: trunk/Source/WebCore/fileapi/WebKitBlobBuilder.cpp (209183 => 209184)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/fileapi/WebKitBlobBuilder.cpp        2016-12-01 17:48:28 UTC (rev 209183)
+++ trunk/Source/WebCore/fileapi/WebKitBlobBuilder.cpp        2016-12-01 18:04:58 UTC (rev 209184)
</span><span class="lines">@@ -1,102 +0,0 @@
</span><del>-/*
- * Copyright (C) 2010 Google Inc. All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are
- * met:
- *
- *     * Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *     * Redistributions in binary form must reproduce the above
- * copyright notice, this list of conditions and the following disclaimer
- * in the documentation and/or other materials provided with the
- * distribution.
- *     * Neither the name of Google Inc. nor the names of its
- * contributors may be used to endorse or promote products derived from
- * this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
- * &quot;AS IS&quot; AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
- * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
- * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
- * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
- * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
- * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
- * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-#include &quot;config.h&quot;
-#include &quot;WebKitBlobBuilder.h&quot;
-
-#include &quot;Blob.h&quot;
-#include &quot;Document.h&quot;
-#include &quot;File.h&quot;
-#include &quot;LineEnding.h&quot;
-#include &quot;TextEncoding.h&quot;
-#include &lt;runtime/ArrayBuffer.h&gt;
-#include &lt;runtime/ArrayBufferView.h&gt;
-#include &lt;wtf/Vector.h&gt;
-#include &lt;wtf/text/AtomicString.h&gt;
-#include &lt;wtf/text/CString.h&gt;
-#include &lt;wtf/text/StringView.h&gt;
-
-namespace WebCore {
-
-enum BlobConstructorArrayBufferOrView {
-    BlobConstructorArrayBuffer,
-    BlobConstructorArrayBufferView,
-    BlobConstructorArrayBufferOrViewMax,
-};
-
-BlobBuilder::BlobBuilder()
-{
-}
-
-void BlobBuilder::append(const String&amp; text, const String&amp; endingType)
-{
-    CString utf8Text = UTF8Encoding().encode(text, EntitiesForUnencodables);
-
-    if (endingType == &quot;native&quot;)
-        normalizeLineEndingsToNative(utf8Text, m_appendableData);
-    else {
-        ASSERT(endingType == &quot;transparent&quot;);
-        m_appendableData.append(utf8Text.data(), utf8Text.length());
-    }
-}
-
-void BlobBuilder::append(ArrayBuffer* arrayBuffer)
-{
-    if (!arrayBuffer)
-        return;
-
-    m_appendableData.append(static_cast&lt;const char*&gt;(arrayBuffer-&gt;data()), arrayBuffer-&gt;byteLength());
-}
-
-void BlobBuilder::append(RefPtr&lt;ArrayBufferView&gt;&amp;&amp; arrayBufferView)
-{
-    if (!arrayBufferView)
-        return;
-
-    m_appendableData.append(static_cast&lt;const char*&gt;(arrayBufferView-&gt;baseAddress()), arrayBufferView-&gt;byteLength());
-}
-
-void BlobBuilder::append(Blob* blob)
-{
-    if (!blob)
-        return;
-    if (!m_appendableData.isEmpty())
-        m_items.append(BlobPart(WTFMove(m_appendableData)));
-    m_items.append(BlobPart(blob-&gt;url()));
-}
-
-Vector&lt;BlobPart&gt; BlobBuilder::finalize()
-{
-    if (!m_appendableData.isEmpty())
-        m_items.append(BlobPart(WTFMove(m_appendableData)));
-    return WTFMove(m_items);
-}
-
-} // namespace WebCore
</del></span></pre></div>
<a id="trunkSourceWebCorefileapiWebKitBlobBuilderh"></a>
<div class="delfile"><h4>Deleted: trunk/Source/WebCore/fileapi/WebKitBlobBuilder.h (209183 => 209184)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/fileapi/WebKitBlobBuilder.h        2016-12-01 17:48:28 UTC (rev 209183)
+++ trunk/Source/WebCore/fileapi/WebKitBlobBuilder.h        2016-12-01 18:04:58 UTC (rev 209184)
</span><span class="lines">@@ -1,60 +0,0 @@
</span><del>-/*
- * Copyright (C) 2010 Google Inc. All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are
- * met:
- *
- *     * Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *     * Redistributions in binary form must reproduce the above
- * copyright notice, this list of conditions and the following disclaimer
- * in the documentation and/or other materials provided with the
- * distribution.
- *     * Neither the name of Google Inc. nor the names of its
- * contributors may be used to endorse or promote products derived from
- * this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
- * &quot;AS IS&quot; AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
- * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
- * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
- * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
- * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
- * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
- * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-#pragma once
-
-#include &quot;BlobPart.h&quot;
-
-namespace JSC {
-class ArrayBuffer;
-class ArrayBufferView;
-}
-
-namespace WebCore {
-
-class Blob;
-
-class BlobBuilder {
-public:
-    BlobBuilder();
-
-    void append(Blob*);
-    void append(const String&amp; text, const String&amp; ending);
-    void append(JSC::ArrayBuffer*);
-    void append(RefPtr&lt;JSC::ArrayBufferView&gt;&amp;&amp;);
-
-    Vector&lt;BlobPart&gt; finalize();
-
-private:
-    Vector&lt;BlobPart&gt; m_items;
-    Vector&lt;uint8_t&gt; m_appendableData;
-};
-
-} // namespace WebCore
</del></span></pre></div>
<a id="trunkSourceWebCoreplatformnetworkBlobParth"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/platform/network/BlobPart.h (209183 => 209184)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/platform/network/BlobPart.h        2016-12-01 17:48:28 UTC (rev 209183)
+++ trunk/Source/WebCore/platform/network/BlobPart.h        2016-12-01 18:04:58 UTC (rev 209184)
</span><span class="lines">@@ -23,8 +23,7 @@
</span><span class="cx">  * THE POSSIBILITY OF SUCH DAMAGE.
</span><span class="cx">  */
</span><span class="cx"> 
</span><del>-#ifndef BlobPart_h
-#define BlobPart_h
</del><ins>+#pragma once
</ins><span class="cx"> 
</span><span class="cx"> #include &quot;URL.h&quot;
</span><span class="cx"> 
</span><span class="lines">@@ -86,5 +85,3 @@
</span><span class="cx"> };
</span><span class="cx"> 
</span><span class="cx"> }
</span><del>-
-#endif // BlobPart_h
</del></span></pre></div>
<a id="trunkSourceWebCoreplatformnetworkBlobRegistryh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/platform/network/BlobRegistry.h (209183 => 209184)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/platform/network/BlobRegistry.h        2016-12-01 17:48:28 UTC (rev 209183)
+++ trunk/Source/WebCore/platform/network/BlobRegistry.h        2016-12-01 18:04:58 UTC (rev 209184)
</span><span class="lines">@@ -53,7 +53,7 @@
</span><span class="cx">     virtual void registerFileBlobURL(const URL&amp;, Ref&lt;BlobDataFileReference&gt;&amp;&amp;, const String&amp; contentType) = 0;
</span><span class="cx"> 
</span><span class="cx">     // Registers a blob URL referring to the specified blob data.
</span><del>-    virtual void registerBlobURL(const URL&amp;, Vector&lt;BlobPart&gt;, const String&amp; contentType) = 0;
</del><ins>+    virtual void registerBlobURL(const URL&amp;, Vector&lt;BlobPart&gt;&amp;&amp;, const String&amp; contentType) = 0;
</ins><span class="cx">     
</span><span class="cx">     // Registers a new blob URL referring to the blob data identified by the specified srcURL.
</span><span class="cx">     virtual void registerBlobURL(const URL&amp;, const URL&amp; srcURL) = 0;
</span></span></pre></div>
<a id="trunkSourceWebCoreplatformnetworkBlobRegistryImplcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/platform/network/BlobRegistryImpl.cpp (209183 => 209184)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/platform/network/BlobRegistryImpl.cpp        2016-12-01 17:48:28 UTC (rev 209183)
+++ trunk/Source/WebCore/platform/network/BlobRegistryImpl.cpp        2016-12-01 18:04:58 UTC (rev 209184)
</span><span class="lines">@@ -120,7 +120,7 @@
</span><span class="cx">     m_blobs.set(url.string(), WTFMove(blobData));
</span><span class="cx"> }
</span><span class="cx"> 
</span><del>-void BlobRegistryImpl::registerBlobURL(const URL&amp; url, Vector&lt;BlobPart&gt; blobParts, const String&amp; contentType)
</del><ins>+void BlobRegistryImpl::registerBlobURL(const URL&amp; url, Vector&lt;BlobPart&gt;&amp;&amp; blobParts, const String&amp; contentType)
</ins><span class="cx"> {
</span><span class="cx">     ASSERT(isMainThread());
</span><span class="cx">     registerBlobResourceHandleConstructor();
</span></span></pre></div>
<a id="trunkSourceWebCoreplatformnetworkBlobRegistryImplh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/platform/network/BlobRegistryImpl.h (209183 => 209184)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/platform/network/BlobRegistryImpl.h        2016-12-01 17:48:28 UTC (rev 209183)
+++ trunk/Source/WebCore/platform/network/BlobRegistryImpl.h        2016-12-01 18:04:58 UTC (rev 209184)
</span><span class="lines">@@ -59,7 +59,7 @@
</span><span class="cx">     void appendStorageItems(BlobData*, const BlobDataItemList&amp;, long long offset, long long length);
</span><span class="cx"> 
</span><span class="cx">     void registerFileBlobURL(const URL&amp;, Ref&lt;BlobDataFileReference&gt;&amp;&amp;, const String&amp; contentType) override;
</span><del>-    void registerBlobURL(const URL&amp;, Vector&lt;BlobPart&gt;, const String&amp; contentType) override;
</del><ins>+    void registerBlobURL(const URL&amp;, Vector&lt;BlobPart&gt;&amp;&amp;, const String&amp; contentType) override;
</ins><span class="cx">     void registerBlobURL(const URL&amp;, const URL&amp; srcURL) override;
</span><span class="cx">     void registerBlobURLOptionallyFileBacked(const URL&amp;, const URL&amp; srcURL, RefPtr&lt;BlobDataFileReference&gt;&amp;&amp;, const String&amp; contentType) override;
</span><span class="cx">     void registerBlobURLForSlice(const URL&amp;, const URL&amp; srcURL, long long start, long long end) override;
</span></span></pre></div>
<a id="trunkSourceWebKit2ChangeLog"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebKit2/ChangeLog (209183 => 209184)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit2/ChangeLog        2016-12-01 17:48:28 UTC (rev 209183)
+++ trunk/Source/WebKit2/ChangeLog        2016-12-01 18:04:58 UTC (rev 209184)
</span><span class="lines">@@ -1,3 +1,21 @@
</span><ins>+2016-11-30  Sam Weinig  &lt;sam@webkit.org&gt;
+
+        [WebIDL] Remove custom bindings for File and Blob constructors
+        https://bugs.webkit.org/show_bug.cgi?id=165218
+
+        Reviewed by Darin Adler.
+
+        * NetworkProcess/FileAPI/NetworkBlobRegistry.cpp:
+        (WebKit::NetworkBlobRegistry::registerBlobURL):
+        * NetworkProcess/FileAPI/NetworkBlobRegistry.h:
+        * NetworkProcess/NetworkConnectionToWebProcess.cpp:
+        (WebKit::NetworkConnectionToWebProcess::registerBlobURL):
+        * NetworkProcess/NetworkConnectionToWebProcess.h:
+        * WebProcess/FileAPI/BlobRegistryProxy.cpp:
+        (WebKit::BlobRegistryProxy::registerBlobURL):
+        * WebProcess/FileAPI/BlobRegistryProxy.h:
+        Avoid copies of the BlobPart Vector.
+
</ins><span class="cx"> 2016-11-30  Carlos Garcia Campos  &lt;cgarcia@igalia.com&gt;
</span><span class="cx"> 
</span><span class="cx">         [GTK] UI process crash in WebKit::WaylandCompositor::Surface::prepareTextureForPainting
</span></span></pre></div>
<a id="trunkSourceWebKit2NetworkProcessFileAPINetworkBlobRegistrycpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebKit2/NetworkProcess/FileAPI/NetworkBlobRegistry.cpp (209183 => 209184)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit2/NetworkProcess/FileAPI/NetworkBlobRegistry.cpp        2016-12-01 17:48:28 UTC (rev 209183)
+++ trunk/Source/WebKit2/NetworkProcess/FileAPI/NetworkBlobRegistry.cpp        2016-12-01 18:04:58 UTC (rev 209184)
</span><span class="lines">@@ -60,7 +60,7 @@
</span><span class="cx">     mapIterator-&gt;value.add(url);
</span><span class="cx"> }
</span><span class="cx"> 
</span><del>-void NetworkBlobRegistry::registerBlobURL(NetworkConnectionToWebProcess* connection, const URL&amp; url, Vector&lt;WebCore::BlobPart&gt; blobParts, const String&amp; contentType)
</del><ins>+void NetworkBlobRegistry::registerBlobURL(NetworkConnectionToWebProcess* connection, const URL&amp; url, Vector&lt;WebCore::BlobPart&gt;&amp;&amp; blobParts, const String&amp; contentType)
</ins><span class="cx"> {
</span><span class="cx">     blobRegistry().registerBlobURL(url, WTFMove(blobParts), contentType);
</span><span class="cx"> 
</span></span></pre></div>
<a id="trunkSourceWebKit2NetworkProcessFileAPINetworkBlobRegistryh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebKit2/NetworkProcess/FileAPI/NetworkBlobRegistry.h (209183 => 209184)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit2/NetworkProcess/FileAPI/NetworkBlobRegistry.h        2016-12-01 17:48:28 UTC (rev 209183)
+++ trunk/Source/WebKit2/NetworkProcess/FileAPI/NetworkBlobRegistry.h        2016-12-01 18:04:58 UTC (rev 209184)
</span><span class="lines">@@ -47,7 +47,7 @@
</span><span class="cx">     static NetworkBlobRegistry&amp; singleton();
</span><span class="cx"> 
</span><span class="cx">     void registerFileBlobURL(NetworkConnectionToWebProcess*, const WebCore::URL&amp;, const String&amp; path, RefPtr&lt;SandboxExtension&gt;&amp;&amp;, const String&amp; contentType);
</span><del>-    void registerBlobURL(NetworkConnectionToWebProcess*, const WebCore::URL&amp;, Vector&lt;WebCore::BlobPart&gt;, const String&amp; contentType);
</del><ins>+    void registerBlobURL(NetworkConnectionToWebProcess*, const WebCore::URL&amp;, Vector&lt;WebCore::BlobPart&gt;&amp;&amp;, const String&amp; contentType);
</ins><span class="cx">     void registerBlobURL(NetworkConnectionToWebProcess*, const WebCore::URL&amp;, const WebCore::URL&amp; srcURL);
</span><span class="cx">     void registerBlobURLOptionallyFileBacked(NetworkConnectionToWebProcess*, const WebCore::URL&amp;, const WebCore::URL&amp; srcURL, const String&amp; fileBackedPath, const String&amp; contentType);
</span><span class="cx">     void registerBlobURLForSlice(NetworkConnectionToWebProcess*, const WebCore::URL&amp;, const WebCore::URL&amp; srcURL, int64_t start, int64_t end);
</span></span></pre></div>
<a id="trunkSourceWebKit2NetworkProcessNetworkConnectionToWebProcesscpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebKit2/NetworkProcess/NetworkConnectionToWebProcess.cpp (209183 => 209184)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit2/NetworkProcess/NetworkConnectionToWebProcess.cpp        2016-12-01 17:48:28 UTC (rev 209183)
+++ trunk/Source/WebKit2/NetworkProcess/NetworkConnectionToWebProcess.cpp        2016-12-01 18:04:58 UTC (rev 209184)
</span><span class="lines">@@ -251,7 +251,7 @@
</span><span class="cx">     NetworkBlobRegistry::singleton().registerFileBlobURL(this, url, path, WTFMove(extension), contentType);
</span><span class="cx"> }
</span><span class="cx"> 
</span><del>-void NetworkConnectionToWebProcess::registerBlobURL(const URL&amp; url, Vector&lt;BlobPart&gt; blobParts, const String&amp; contentType)
</del><ins>+void NetworkConnectionToWebProcess::registerBlobURL(const URL&amp; url, Vector&lt;BlobPart&gt;&amp;&amp; blobParts, const String&amp; contentType)
</ins><span class="cx"> {
</span><span class="cx">     NetworkBlobRegistry::singleton().registerBlobURL(this, url, WTFMove(blobParts), contentType);
</span><span class="cx"> }
</span></span></pre></div>
<a id="trunkSourceWebKit2NetworkProcessNetworkConnectionToWebProcessh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebKit2/NetworkProcess/NetworkConnectionToWebProcess.h (209183 => 209184)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit2/NetworkProcess/NetworkConnectionToWebProcess.h        2016-12-01 17:48:28 UTC (rev 209183)
+++ trunk/Source/WebKit2/NetworkProcess/NetworkConnectionToWebProcess.h        2016-12-01 18:04:58 UTC (rev 209184)
</span><span class="lines">@@ -88,7 +88,7 @@
</span><span class="cx">     void addCookie(WebCore::SessionID, const WebCore::URL&amp;, const WebCore::Cookie&amp;);
</span><span class="cx"> 
</span><span class="cx">     void registerFileBlobURL(const WebCore::URL&amp;, const String&amp; path, const SandboxExtension::Handle&amp;, const String&amp; contentType);
</span><del>-    void registerBlobURL(const WebCore::URL&amp;, Vector&lt;WebCore::BlobPart&gt;, const String&amp; contentType);
</del><ins>+    void registerBlobURL(const WebCore::URL&amp;, Vector&lt;WebCore::BlobPart&gt;&amp;&amp;, const String&amp; contentType);
</ins><span class="cx">     void registerBlobURLFromURL(const WebCore::URL&amp;, const WebCore::URL&amp; srcURL);
</span><span class="cx">     void preregisterSandboxExtensionsForOptionallyFileBackedBlob(const Vector&lt;String&gt;&amp; fileBackedPath, const SandboxExtension::HandleArray&amp;);
</span><span class="cx">     void registerBlobURLOptionallyFileBacked(const WebCore::URL&amp;, const WebCore::URL&amp; srcURL, const String&amp; fileBackedPath, const String&amp; contentType);
</span></span></pre></div>
<a id="trunkSourceWebKit2WebProcessFileAPIBlobRegistryProxycpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebKit2/WebProcess/FileAPI/BlobRegistryProxy.cpp (209183 => 209184)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit2/WebProcess/FileAPI/BlobRegistryProxy.cpp        2016-12-01 17:48:28 UTC (rev 209183)
+++ trunk/Source/WebKit2/WebProcess/FileAPI/BlobRegistryProxy.cpp        2016-12-01 18:04:58 UTC (rev 209184)
</span><span class="lines">@@ -47,7 +47,7 @@
</span><span class="cx">     WebProcess::singleton().networkConnection().connection().send(Messages::NetworkConnectionToWebProcess::RegisterFileBlobURL(url, file-&gt;path(), extensionHandle, contentType), 0);
</span><span class="cx"> }
</span><span class="cx"> 
</span><del>-void BlobRegistryProxy::registerBlobURL(const URL&amp; url, Vector&lt;BlobPart&gt; blobParts, const String&amp; contentType)
</del><ins>+void BlobRegistryProxy::registerBlobURL(const URL&amp; url, Vector&lt;BlobPart&gt;&amp;&amp; blobParts, const String&amp; contentType)
</ins><span class="cx"> {
</span><span class="cx">     WebProcess::singleton().networkConnection().connection().send(Messages::NetworkConnectionToWebProcess::RegisterBlobURL(url, blobParts, contentType), 0);
</span><span class="cx"> }
</span></span></pre></div>
<a id="trunkSourceWebKit2WebProcessFileAPIBlobRegistryProxyh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebKit2/WebProcess/FileAPI/BlobRegistryProxy.h (209183 => 209184)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit2/WebProcess/FileAPI/BlobRegistryProxy.h        2016-12-01 17:48:28 UTC (rev 209183)
+++ trunk/Source/WebKit2/WebProcess/FileAPI/BlobRegistryProxy.h        2016-12-01 18:04:58 UTC (rev 209184)
</span><span class="lines">@@ -32,7 +32,7 @@
</span><span class="cx"> class BlobRegistryProxy final : public WebCore::BlobRegistry {
</span><span class="cx"> public:
</span><span class="cx">     void registerFileBlobURL(const WebCore::URL&amp;, Ref&lt;WebCore::BlobDataFileReference&gt;&amp;&amp;, const String&amp; contentType) override;
</span><del>-    void registerBlobURL(const WebCore::URL&amp;, Vector&lt;WebCore::BlobPart&gt;, const String&amp; contentType) override;
</del><ins>+    void registerBlobURL(const WebCore::URL&amp;, Vector&lt;WebCore::BlobPart&gt;&amp;&amp;, const String&amp; contentType) override;
</ins><span class="cx">     void registerBlobURL(const WebCore::URL&amp;, const WebCore::URL&amp; srcURL) override;
</span><span class="cx">     void registerBlobURLOptionallyFileBacked(const WebCore::URL&amp;, const WebCore::URL&amp; srcURL, RefPtr&lt;WebCore::BlobDataFileReference&gt;&amp;&amp;, const String&amp; contentType) override;
</span><span class="cx">     void unregisterBlobURL(const WebCore::URL&amp;) override;
</span></span></pre>
</div>
</div>

</body>
</html>