Commit a619da9f authored by Mikio Hara's avatar Mikio Hara

xml: fix build

empty is already not a nil.

R=golang-dev, bradfitz
CC=golang-dev
https://golang.org/cl/5376098
parent 301701d8
...@@ -42,17 +42,17 @@ var rawTokens = []Token{ ...@@ -42,17 +42,17 @@ var rawTokens = []Token{
CharData([]byte("World <>'\" 白鵬翔")), CharData([]byte("World <>'\" 白鵬翔")),
EndElement{Name{"", "hello"}}, EndElement{Name{"", "hello"}},
CharData([]byte("\n ")), CharData([]byte("\n ")),
StartElement{Name{"", "goodbye"}, nil}, StartElement{Name{"", "goodbye"}, []Attr{}},
EndElement{Name{"", "goodbye"}}, EndElement{Name{"", "goodbye"}},
CharData([]byte("\n ")), CharData([]byte("\n ")),
StartElement{Name{"", "outer"}, []Attr{{Name{"foo", "attr"}, "value"}, {Name{"xmlns", "tag"}, "ns4"}}}, StartElement{Name{"", "outer"}, []Attr{{Name{"foo", "attr"}, "value"}, {Name{"xmlns", "tag"}, "ns4"}}},
CharData([]byte("\n ")), CharData([]byte("\n ")),
StartElement{Name{"", "inner"}, nil}, StartElement{Name{"", "inner"}, []Attr{}},
EndElement{Name{"", "inner"}}, EndElement{Name{"", "inner"}},
CharData([]byte("\n ")), CharData([]byte("\n ")),
EndElement{Name{"", "outer"}}, EndElement{Name{"", "outer"}},
CharData([]byte("\n ")), CharData([]byte("\n ")),
StartElement{Name{"tag", "name"}, nil}, StartElement{Name{"tag", "name"}, []Attr{}},
CharData([]byte("\n ")), CharData([]byte("\n ")),
CharData([]byte("Some text here.")), CharData([]byte("Some text here.")),
CharData([]byte("\n ")), CharData([]byte("\n ")),
...@@ -76,17 +76,17 @@ var cookedTokens = []Token{ ...@@ -76,17 +76,17 @@ var cookedTokens = []Token{
CharData([]byte("World <>'\" 白鵬翔")), CharData([]byte("World <>'\" 白鵬翔")),
EndElement{Name{"ns2", "hello"}}, EndElement{Name{"ns2", "hello"}},
CharData([]byte("\n ")), CharData([]byte("\n ")),
StartElement{Name{"ns2", "goodbye"}, nil}, StartElement{Name{"ns2", "goodbye"}, []Attr{}},
EndElement{Name{"ns2", "goodbye"}}, EndElement{Name{"ns2", "goodbye"}},
CharData([]byte("\n ")), CharData([]byte("\n ")),
StartElement{Name{"ns2", "outer"}, []Attr{{Name{"ns1", "attr"}, "value"}, {Name{"xmlns", "tag"}, "ns4"}}}, StartElement{Name{"ns2", "outer"}, []Attr{{Name{"ns1", "attr"}, "value"}, {Name{"xmlns", "tag"}, "ns4"}}},
CharData([]byte("\n ")), CharData([]byte("\n ")),
StartElement{Name{"ns2", "inner"}, nil}, StartElement{Name{"ns2", "inner"}, []Attr{}},
EndElement{Name{"ns2", "inner"}}, EndElement{Name{"ns2", "inner"}},
CharData([]byte("\n ")), CharData([]byte("\n ")),
EndElement{Name{"ns2", "outer"}}, EndElement{Name{"ns2", "outer"}},
CharData([]byte("\n ")), CharData([]byte("\n ")),
StartElement{Name{"ns3", "name"}, nil}, StartElement{Name{"ns3", "name"}, []Attr{}},
CharData([]byte("\n ")), CharData([]byte("\n ")),
CharData([]byte("Some text here.")), CharData([]byte("Some text here.")),
CharData([]byte("\n ")), CharData([]byte("\n ")),
...@@ -104,7 +104,7 @@ var rawTokensAltEncoding = []Token{ ...@@ -104,7 +104,7 @@ var rawTokensAltEncoding = []Token{
CharData([]byte("\n")), CharData([]byte("\n")),
ProcInst{"xml", []byte(`version="1.0" encoding="x-testing-uppercase"`)}, ProcInst{"xml", []byte(`version="1.0" encoding="x-testing-uppercase"`)},
CharData([]byte("\n")), CharData([]byte("\n")),
StartElement{Name{"", "tag"}, nil}, StartElement{Name{"", "tag"}, []Attr{}},
CharData([]byte("value")), CharData([]byte("value")),
EndElement{Name{"", "tag"}}, EndElement{Name{"", "tag"}},
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment