Switch use of strings.LastIndexByte to strings.LastIndex. It has almost zero impact on performance in practice, and permits this code to keep working with Go 1.4. Fixes #146.
diff --git a/protoc-gen-go/generator/generator.go b/protoc-gen-go/generator/generator.go index 2d431dc..2994cc9 100644 --- a/protoc-gen-go/generator/generator.go +++ b/protoc-gen-go/generator/generator.go
@@ -275,7 +275,7 @@ } ok = true // The presence of a slash implies there's an import path. - slash := strings.LastIndexByte(pkg, '/') + slash := strings.LastIndex(pkg, "/") if slash < 0 { return }