Skip to content

Commit

Permalink
Slightly reduce allocations in Find
Browse files Browse the repository at this point in the history
  • Loading branch information
dustin committed Aug 12, 2016
1 parent 6812e30 commit db4d127
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion bytes.go
Expand Up @@ -98,7 +98,7 @@ func Find(data []byte, path string) ([]byte, error) {

offset := 0
beganLiteral := 0
current := []string{}
current := make([]string, 0, 32)
for {
if offset >= len(data) {
break
Expand Down

0 comments on commit db4d127

Please sign in to comment.