]> Cypherpunks repositories - gostls13.git/commitdiff
testing: remove redundant type conversion
authorAlexander Melentyev <alexander@melentyev.org>
Sun, 31 Oct 2021 17:50:38 +0000 (17:50 +0000)
committerEmmanuel Odeke <emmanuel@orijtech.com>
Sun, 31 Oct 2021 18:13:09 +0000 (18:13 +0000)
Change-Id: Ib6415bb09af02e9ebc0099f50bf0fd7b572f2516
GitHub-Last-Rev: ebaa849d66efa45bd8ca50a8306652d823a41678
GitHub-Pull-Request: golang/go#49244
Reviewed-on: https://go-review.googlesource.com/c/go/+/360214
Trust: Tobias Klauser <tobias.klauser@gmail.com>
Run-TryBot: Tobias Klauser <tobias.klauser@gmail.com>
TryBot-Result: Go Bot <gobot@golang.org>
Reviewed-by: Emmanuel Odeke <emmanuel@orijtech.com>
src/testing/benchmark.go

index 1ce637e137860da09c7a6f44defa7b4f45111705..d8ec217f66c628e0950a6223dd0a67e12625f8a0 100644 (file)
@@ -45,7 +45,7 @@ func (f *durationOrCountFlag) String() string {
        if f.n > 0 {
                return fmt.Sprintf("%dx", f.n)
        }
-       return time.Duration(f.d).String()
+       return f.d.String()
 }
 
 func (f *durationOrCountFlag) Set(s string) error {