aboutsummaryrefslogtreecommitdiff
path: root/src/encoding/xml
diff options
context:
space:
mode:
Diffstat (limited to 'src/encoding/xml')
-rw-r--r--src/encoding/xml/typeinfo.go2
-rw-r--r--src/encoding/xml/xml.go2
2 files changed, 2 insertions, 2 deletions
diff --git a/src/encoding/xml/typeinfo.go b/src/encoding/xml/typeinfo.go
index b3346d304e..2e7ae935a8 100644
--- a/src/encoding/xml/typeinfo.go
+++ b/src/encoding/xml/typeinfo.go
@@ -115,7 +115,7 @@ func structFieldInfo(typ reflect.Type, f *reflect.StructField) (*fieldInfo, erro
// Split the tag from the xml namespace if necessary.
tag := f.Tag.Get("xml")
- if i := strings.IndexByte(tag, ' '); i >= 0 {
+ if i := strings.Index(tag, " "); i >= 0 {
finfo.xmlns, tag = tag[:i], tag[i+1:]
}
diff --git a/src/encoding/xml/xml.go b/src/encoding/xml/xml.go
index 27b871649b..be90b62c9a 100644
--- a/src/encoding/xml/xml.go
+++ b/src/encoding/xml/xml.go
@@ -1161,7 +1161,7 @@ func (d *Decoder) nsname() (name Name, ok bool) {
if !ok {
return
}
- i := strings.IndexByte(s, ':')
+ i := strings.Index(s, ":")
if i < 0 {
name.Local = s
} else {