go/src/mime
Marvin Stenger f22ba1f247 all: prefer strings.IndexByte over strings.Index
strings.IndexByte was introduced in go1.2 and it can be used
effectively wherever the second argument to strings.Index is
exactly one byte long.

This avoids generating unnecessary string symbols and saves
a few calls to strings.Index.

Change-Id: I1ab5edb7c4ee9058084cfa57cbcc267c2597e793
Reviewed-on: https://go-review.googlesource.com/65930
Run-TryBot: Ian Lance Taylor <iant@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Ian Lance Taylor <iant@golang.org>
2017-09-25 17:35:41 +00:00
..
multipart mime/multipart: parse boundary with spaces properly 2017-05-23 22:56:44 +00:00
quotedprintable
testdata
encodedword.go all: prefer strings.IndexByte over strings.Index 2017-09-25 17:35:41 +00:00
encodedword_test.go mime: re-accept empty encoded-text 2017-04-29 04:14:36 +00:00
example_test.go
grammar.go
mediatype.go all: prefer strings.IndexByte over strings.Index 2017-09-25 17:35:41 +00:00
mediatype_test.go mime: ignore key on ParseMediaType when value don't pass RFC 2231 check 2017-08-29 21:10:56 +00:00
type.go mime: use sync.Map instead of RWMutex for type lookups 2017-04-28 20:49:29 +00:00
type_dragonfly.go
type_freebsd.go
type_openbsd.go
type_plan9.go
type_test.go mime: add benchmarks for TypeByExtension and ExtensionsByType 2017-02-14 23:02:07 +00:00
type_unix.go
type_windows.go