[html5] r4138 - [gow] (2) Drop support for anything but UTF-8 from Workers.
whatwg at whatwg.org
whatwg at whatwg.org
Wed Oct 14 03:55:23 PDT 2009
Author: ianh
Date: 2009-10-14 03:55:22 -0700 (Wed, 14 Oct 2009)
New Revision: 4138
Modified:
complete.html
source
Log:
[gow] (2) Drop support for anything but UTF-8 from Workers.
Modified: complete.html
===================================================================
--- complete.html 2009-10-14 10:41:57 UTC (rev 4137)
+++ complete.html 2009-10-14 10:55:22 UTC (rev 4138)
@@ -916,16 +916,15 @@
<li><a href=#dedicated-workers-and-the-dedicatedworkerglobalscope-interface><span class=secno>9.2.1.2 </span>Dedicated workers and the <code>DedicatedWorkerGlobalScope</code> interface</a></li>
<li><a href=#shared-workers-and-the-sharedworkerglobalscope-inteface><span class=secno>9.2.1.3 </span>Shared workers and the <code>SharedWorkerGlobalScope</code> inteface</a></ol></li>
<li><a href=#origins-of-workers><span class=secno>9.2.2 </span>Origins of workers</a></li>
- <li><a href=#decoding-scripts><span class=secno>9.2.3 </span>Decoding scripts</a></li>
- <li><a href=#the-event-loop><span class=secno>9.2.4 </span>The event loop</a></li>
- <li><a href="#the-worker's-lifetime"><span class=secno>9.2.5 </span>The worker's lifetime</a></li>
- <li><a href=#processing-model-4><span class=secno>9.2.6 </span>Processing model</a></li>
- <li><a href=#runtime-script-errors-0><span class=secno>9.2.7 </span>Runtime script errors</a></li>
- <li><a href=#creating-workers><span class=secno>9.2.8 </span>Creating workers</a>
+ <li><a href=#the-event-loop><span class=secno>9.2.3 </span>The event loop</a></li>
+ <li><a href="#the-worker's-lifetime"><span class=secno>9.2.4 </span>The worker's lifetime</a></li>
+ <li><a href=#processing-model-4><span class=secno>9.2.5 </span>Processing model</a></li>
+ <li><a href=#runtime-script-errors-0><span class=secno>9.2.6 </span>Runtime script errors</a></li>
+ <li><a href=#creating-workers><span class=secno>9.2.7 </span>Creating workers</a>
<ol>
- <li><a href=#the-abstractworker-abstract-interface><span class=secno>9.2.8.1 </span>The <code>AbstractWorker</code> abstract interface</a></li>
- <li><a href=#dedicated-workers-and-the-worker-interface><span class=secno>9.2.8.2 </span>Dedicated workers and the <code>Worker</code> interface</a></li>
- <li><a href=#shared-workers-and-the-sharedworker-interface><span class=secno>9.2.8.3 </span>Shared workers and the <code>SharedWorker</code> interface</a></ol></ol></li>
+ <li><a href=#the-abstractworker-abstract-interface><span class=secno>9.2.7.1 </span>The <code>AbstractWorker</code> abstract interface</a></li>
+ <li><a href=#dedicated-workers-and-the-worker-interface><span class=secno>9.2.7.2 </span>Dedicated workers and the <code>Worker</code> interface</a></li>
+ <li><a href=#shared-workers-and-the-sharedworker-interface><span class=secno>9.2.7.3 </span>Shared workers and the <code>SharedWorker</code> interface</a></ol></ol></li>
<li><a href=#apis-available-to-workers><span class=secno>9.3 </span>APIs available to workers</a>
<ol>
<li><a href=#importing-scripts-and-libraries><span class=secno>9.3.1 </span>Importing scripts and libraries</a></li>
@@ -63744,79 +63743,9 @@
represents.</p>
- <h4 id=decoding-scripts><span class=secno>9.2.3 </span>Decoding scripts</h4>
- <p>When a user agent is to <dfn id=decode-a-script-resource>decode a script resource</dfn> to
- obtain its source in Unicode, it must run the following steps:</p>
+ <h4 id=the-event-loop><span class=secno>9.2.3 </span>The event loop</h4>
- <ol><li>
-
- <p>Let <var title="">character encoding</var> be <i title="">unknown</i>.</p>
-
- </li>
-
- <li>
-
- <p>For each of the rows in the following table, starting with the
- first one and going down, if the resource has as many or more
- bytes available than the number of bytes in the first column, and
- the first bytes of the resource match the bytes given in the first
- column, then let <var title="">character encoding</var> be the
- encoding given in the cell in the second column of that row:</p>
-
- <!-- this table is present in several forms in this file; keep them in sync -->
- <table><thead><tr><th>Bytes in Hexadecimal
- <th>Encoding
- <tbody><!-- nobody uses this
- <tr>
- <td>00 00 FE FF
- <td>UTF-32BE
- <tr>
- <td>FF FE 00 00
- <td>UTF-32LE
---><tr><td>FE FF
- <td>UTF-16BE
- <tr><td>FF FE
- <td>UTF-16LE
- <tr><td>EF BB BF
- <td>UTF-8
-<!-- nobody uses this
- <tr>
- <td>DD 73 66 73
- <td>UTF-EBCDIC
--->
- </table><p class=note>This step looks for Unicode Byte Order Marks
- (BOMs).</p>
-
- </li>
-
- <li>
-
- <p>If <var title="">character encoding</var> is still <i title="">unknown</i>, apply the <a href=#algorithm-for-extracting-an-encoding-from-a-content-type>algorithm for extracting an
- encoding from a Content-Type</a> to the resource's <a href=#content-type title=Content-Type>Content Type metadata</a>; if this returns
- an encoding, and the user agent supports that encoding, then let
- <var title="">character encoding</var> be that encoding.</p>
-
- </li>
-
- <li>
-
- <p>If <var title="">character encoding</var> is still <i title="">unknown</i>, then let <var title="">character
- encoding</var> be UTF-8.</p>
-
- </li>
-
- <li>
-
- <p>Convert the resource to Unicode using the character encoding
- given by <var title="">character encoding</var>.</p>
-
- <p>Return the text that is so obtained.</p>
-
- </li>
-
- </ol><h4 id=the-event-loop><span class=secno>9.2.4 </span>The event loop</h4>
-
<p>Each <code><a href=#workerglobalscope>WorkerGlobalScope</a></code> object has an <a href=#event-loop>event
loop</a> distinct from those defined for <a href=#unit-of-related-similar-origin-browsing-contexts title="unit of
related similar-origin browsing contexts">units of related
@@ -63841,7 +63770,7 @@
- <h4 id="the-worker's-lifetime"><span class=secno>9.2.5 </span>The worker's lifetime</h4>
+ <h4 id="the-worker's-lifetime"><span class=secno>9.2.4 </span>The worker's lifetime</h4>
<p>Workers communicate with other workers and with <a href=#browsing-context title="browsing context">browsing contexts</a> through <a href=#channel-messaging title="channel messaging">message channels</a> and their
<code><a href=#messageport>MessagePort</a></code> objects.</p>
@@ -63913,7 +63842,7 @@
<a href=#permissible-worker>permissible worker</a>.</p>
- <h4 id=processing-model-4><span class=secno>9.2.6 </span>Processing model</h4>
+ <h4 id=processing-model-4><span class=secno>9.2.5 </span>Processing model</h4>
<p>When a user agent is to <dfn id=run-a-worker>run a worker</dfn> for a script with
<a href=#url>URL</a> <var title="">url</var>, a browsing context <var title="">owner browsing context</var>, an origin <var title="">owner
@@ -63951,8 +63880,8 @@
named <code title=event-error>error</code> at that
object. Abort these steps.</p>
- <p>If the attempt succeeds, then <a href=#decode-a-script-resource title="decode a script
- resource">decode the script resource</a> to obtain its <var title="">source</var>.</p>
+ <p>If the attempt succeeds, then convert the script resource to
+ Unicode by assuming it was encoded as UTF-8, to obtain its <var title="">source</var>.</p>
<p>Let <var title="">language</var> be JavaScript.</p>
@@ -64180,7 +64109,7 @@
<a href=#dom-manipulation-task-source>DOM manipulation task source</a>.</p>
- <h4 id=runtime-script-errors-0><span class=secno>9.2.7 </span>Runtime script errors</h4>
+ <h4 id=runtime-script-errors-0><span class=secno>9.2.6 </span>Runtime script errors</h4>
<p>Whenever an uncaught runtime script error occurs in one of the
worker's scripts, if the error did not occur while handling a
@@ -64239,9 +64168,9 @@
- <h4 id=creating-workers><span class=secno>9.2.8 </span>Creating workers</h4>
+ <h4 id=creating-workers><span class=secno>9.2.7 </span>Creating workers</h4>
- <h5 id=the-abstractworker-abstract-interface><span class=secno>9.2.8.1 </span>The <code><a href=#abstractworker>AbstractWorker</a></code> abstract interface</h5>
+ <h5 id=the-abstractworker-abstract-interface><span class=secno>9.2.7.1 </span>The <code><a href=#abstractworker>AbstractWorker</a></code> abstract interface</h5>
<pre class=idl>interface <dfn id=abstractworker>AbstractWorker</dfn> {
attribute <a href=#function>Function</a> <a href=#handler-abstractworker-onerror title=handler-AbstractWorker-onerror>onerror</a>;
@@ -64257,7 +64186,7 @@
<table><thead><tr><th><a href=#event-handlers title="event handlers">Event handler</a> <th><a href=#event-handler-event-type>Event handler event type</a>
<tbody><tr><td><dfn id=handler-abstractworker-onerror title=handler-AbstractWorker-onerror><code>onerror</code></dfn> <td> <code title=event-error>error</code>
<!-- v2-onclose <tr><td><dfn title="handler-AbstractWorker-onclose"><code>onclose</code></dfn> <td> <code title="event-close">close</code> -->
- </table><h5 id=dedicated-workers-and-the-worker-interface><span class=secno>9.2.8.2 </span>Dedicated workers and the <code><a href=#worker>Worker</a></code> interface</h5>
+ </table><h5 id=dedicated-workers-and-the-worker-interface><span class=secno>9.2.7.2 </span>Dedicated workers and the <code><a href=#worker>Worker</a></code> interface</h5>
<pre class=idl>[<a href=#dom-worker title=dom-Worker>Constructor</a>(in DOMString scriptURL)]
interface <dfn id=worker>Worker</dfn> : <a href=#abstractworker>AbstractWorker</a> {
@@ -64398,7 +64327,7 @@
implementing the <code><a href=#workerutils>WorkerUtils</a></code> interface.</p>
- <h5 id=shared-workers-and-the-sharedworker-interface><span class=secno>9.2.8.3 </span>Shared workers and the <code><a href=#sharedworker>SharedWorker</a></code> interface</h5>
+ <h5 id=shared-workers-and-the-sharedworker-interface><span class=secno>9.2.7.3 </span>Shared workers and the <code><a href=#sharedworker>SharedWorker</a></code> interface</h5>
<pre class=idl>[<a href=#dom-sharedworker title=dom-SharedWorker>Constructor</a>(in DOMString scriptURL, in optional DOMString name)]
interface <dfn id=sharedworker>SharedWorker</dfn> : <a href=#abstractworker>AbstractWorker</a> {
@@ -64668,8 +64597,8 @@
<code><a href=#network_err>NETWORK_ERR</a></code> exception and abort all these
steps.</p>
- <p>If the attempt succeeds, then <a href=#decode-a-script-resource title="decode a script
- resource">decode the script resource</a> to obtain its <var title="">source</var>.</p>
+ <p>If the attempt succeeds, then convert the script resource to
+ Unicode by assuming it was encoded as UTF-8, to obtain its <var title="">source</var>.</p>
<p>Let <var title="">language</var> be JavaScript.</p>
Modified: source
===================================================================
--- source 2009-10-14 10:41:57 UTC (rev 4137)
+++ source 2009-10-14 10:55:22 UTC (rev 4138)
@@ -71548,96 +71548,7 @@
represents.</p>
- <h4>Decoding scripts</h4>
- <p>When a user agent is to <dfn>decode a script resource</dfn> to
- obtain its source in Unicode, it must run the following steps:</p>
-
- <ol>
-
- <li>
-
- <p>Let <var title="">character encoding</var> be <i
- title="">unknown</i>.</p>
-
- </li>
-
- <li>
-
- <p>For each of the rows in the following table, starting with the
- first one and going down, if the resource has as many or more
- bytes available than the number of bytes in the first column, and
- the first bytes of the resource match the bytes given in the first
- column, then let <var title="">character encoding</var> be the
- encoding given in the cell in the second column of that row:</p>
-
- <!-- this table is present in several forms in this file; keep them in sync -->
- <table>
- <thead>
- <tr>
- <th>Bytes in Hexadecimal
- <th>Encoding
- <tbody>
-<!-- nobody uses this
- <tr>
- <td>00 00 FE FF
- <td>UTF-32BE
- <tr>
- <td>FF FE 00 00
- <td>UTF-32LE
--->
- <tr>
- <td>FE FF
- <td>UTF-16BE
- <tr>
- <td>FF FE
- <td>UTF-16LE
- <tr>
- <td>EF BB BF
- <td>UTF-8
-<!-- nobody uses this
- <tr>
- <td>DD 73 66 73
- <td>UTF-EBCDIC
--->
- </table>
-
- <p class="note">This step looks for Unicode Byte Order Marks
- (BOMs).</p>
-
- </li>
-
- <li>
-
- <p>If <var title="">character encoding</var> is still <i
- title="">unknown</i>, apply the <span>algorithm for extracting an
- encoding from a Content-Type</span> to the resource's <span
- title="Content-Type">Content Type metadata</span>; if this returns
- an encoding, and the user agent supports that encoding, then let
- <var title="">character encoding</var> be that encoding.</p>
-
- </li>
-
- <li>
-
- <p>If <var title="">character encoding</var> is still <i
- title="">unknown</i>, then let <var title="">character
- encoding</var> be UTF-8.</p>
-
- </li>
-
- <li>
-
- <p>Convert the resource to Unicode using the character encoding
- given by <var title="">character encoding</var>.</p>
-
- <p>Return the text that is so obtained.</p>
-
- </li>
-
- </ol>
-
-
<h4>The event loop</h4>
<p>Each <code>WorkerGlobalScope</code> object has an <span>event
@@ -71795,8 +71706,8 @@
named <code title="event-error">error</code> at that
object. Abort these steps.</p>
- <p>If the attempt succeeds, then <span title="decode a script
- resource">decode the script resource</span> to obtain its <var
+ <p>If the attempt succeeds, then convert the script resource to
+ Unicode by assuming it was encoded as UTF-8, to obtain its <var
title="">source</var>.</p>
<p>Let <var title="">language</var> be JavaScript.</p>
@@ -72636,8 +72547,8 @@
<code>NETWORK_ERR</code> exception and abort all these
steps.</p>
- <p>If the attempt succeeds, then <span title="decode a script
- resource">decode the script resource</span> to obtain its <var
+ <p>If the attempt succeeds, then convert the script resource to
+ Unicode by assuming it was encoded as UTF-8, to obtain its <var
title="">source</var>.</p>
<p>Let <var title="">language</var> be JavaScript.</p>
More information about the Commit-Watchers
mailing list