summaryrefslogtreecommitdiff
path: root/perf_test.go
diff options
context:
space:
mode:
authorAdam Scarr <adam@vektah.net>2017-08-13 16:56:12 +1000
committerAdam Scarr <adam@vektah.net>2017-08-13 16:56:12 +1000
commit0dc37ae5bc10cc0669f88ab9febbc039a28f23d1 (patch)
tree0395aac5ab5223a4390eb03b22455ed3c98b6c90 /perf_test.go
parentf633909141dc1e2c2e49b94e5e478e99be51a9cb (diff)
Remove a few allocs from Run
Diffstat (limited to 'perf_test.go')
-rw-r--r--perf_test.go1
1 files changed, 1 insertions, 0 deletions
diff --git a/perf_test.go b/perf_test.go
index d6a0092..7a2911e 100644
--- a/perf_test.go
+++ b/perf_test.go
@@ -5,6 +5,7 @@ import "testing"
func BenchmarkAny(b *testing.B) {
p := Any("hello", "goodbye", "help")
+ b.ResetTimer()
for i := 0; i < b.N; i++ {
_, _ = Run(p, "hello")
_, _ = Run(p, "hello world")