]> Cypherpunks repositories - gostls13.git/commitdiff
spec: ignore BOMS outside of string and rune literals.
authorRob Pike <r@golang.org>
Thu, 6 Sep 2012 17:37:13 +0000 (10:37 -0700)
committerRob Pike <r@golang.org>
Thu, 6 Sep 2012 17:37:13 +0000 (10:37 -0700)
Happy Birthday UTF-8.

R=golang-dev, rsc, 0xjnml
CC=golang-dev
https://golang.org/cl/6506083

doc/go_spec.html

index 2350fdbad802453954d17f16b59e3562aba529d2..195f7a3c2443f0407176b75e9537cf4c9ca79cb1 100644 (file)
@@ -1,6 +1,6 @@
 <!--{
        "Title": "The Go Programming Language Specification",
-       "Subtitle": "Version of September 4, 2012",
+       "Subtitle": "Version of September 6, 2012",
        "Path": "/ref/spec"
 }-->
 
@@ -99,6 +99,12 @@ are different characters.
 Implementation restriction: For compatibility with other tools, a
 compiler may disallow the NUL character (U+0000) in the source text.
 </p>
+<p>
+Implementation restriction: For compatibility with other tools, a
+compiler may ignore any UTF-8-encoded Unicode byte order mark
+(U+FEFF) in the source text outside of <a href="#String_literals">string</a>
+and <a href="#Rune_literals">rune</a> literals.
+</p>
 
 <h3 id="Characters">Characters</h3>