You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: index.html
+8-5Lines changed: 8 additions & 5 deletions
Original file line number
Diff line number
Diff line change
@@ -144,8 +144,6 @@ <h2>Introduction</h2>
144
144
145
145
146
146
147
-
148
-
149
147
<sectionclass="appendix" id="ghChecklist">
150
148
<h3>Create a github checklist</h3>
151
149
@@ -1680,14 +1678,19 @@ <h4>Working with Byte-oriented Formats</h4>
1680
1678
<p><ahref="https://www.w3.org/TR/string-meta/#protocol-strings">Strings that are part of a legacy protocol or format</a>, in <cite>Strings on the Web: Language and Direction Metadata</cite> [[STRING-META]]</p>
1681
1679
</div>
1682
1680
1683
-
<p>Sometimes specifications need to deal with byte-oriented contexts. For example, the specification might be defining a binary format or working with a byte-oriented protocol.</p>
1681
+
<p>Sometimes specifications need to deal with the storage, interpretation, and manipulation of the byte values of various characters. Some (non-exhaustive) examples of this include:
1682
+
<ul>
1683
+
<li>Defining a binary format</li>
1684
+
<li>Parsing HTTP headers</li>
1685
+
<li>Describing the wire format of a protocol</li>
1686
+
</ul></p>
1684
1687
1685
1688
1686
1689
<divclass="req" id="char-string-dom-usv-bytes">
1687
-
<pclass="advisement">Specify fields in protocols that are 'string-like' as {{DOMString}} or, rarely, {{USVString}}, unless there is some reason to interact with specific bytes values or for which the UTF-8 [=character encoding=] cannot be assumed.</p>
1690
+
<pclass="advisement">Specify 'string-like' fields as {{DOMString}} or, rarely, {{USVString}}, unless there is some reason to interact with specific bytes values or for which the UTF-8 [=character encoding=] cannot be assumed.</p>
1688
1691
</div>
1689
1692
1690
-
<p>If the field in question is meant to be treated as a string, working with (Unicode) characters will be more reliable than trying to work with byte values. The data encoded into these fields will be deserialized from the wire format into your local in-memory string representation, such as the [[DOM]], JavaScript strings, or your platform's native Unicode string type and later it will need to be serialized into the wire format using some [=character encoding form=] (usually UTF-8).</p>
1693
+
<p>If the field in question is meant to be treated as a string, working with (Unicode) characters will be more reliable than trying to work with the byte values directly. The data encoded into these fields will be deserialized from the wire format into your local in-memory string representation, such as the [[DOM]], JavaScript strings, or your platform's native Unicode string type. Later it will need to be serialized into the wire format using some [=character encoding form=] (usually—and <em>preferably</em>— UTF-8).</p>
1691
1694
1692
1695
<divclass="req" id="char_string_byte">
1693
1696
<pclass="advisement">Specify {{ByteString}} only when working with protocols (such as HTTP) or formats that don't distinguish between bytes and strings. If you need to represent a sequence of bytes, use {{Uint8Array}}.</p>
0 commit comments