aboutsummaryrefslogtreecommitdiff
path: root/src/time
diff options
context:
space:
mode:
authorcxbdasheng <cxbdasheng@gmail.com>2025-07-24 06:23:23 +0000
committerGopher Robot <gobot@golang.org>2025-07-24 20:30:20 -0700
commit0fa88dec1e23ceeef9f5719e0f9ccb94766e53e7 (patch)
tree8ea5134df07db067f3548e88df7eae30b3488c21 /src/time
parentada30b8248e535b6bc7939b339803bb87412e861 (diff)
downloadgo-0fa88dec1e23ceeef9f5719e0f9ccb94766e53e7.tar.xz
time: remove redundant uint32 conversion in split
cd is a uint32 converted again. Change-Id: Ia41e247e0644c17cd9e0593d79457db77512fc3e GitHub-Last-Rev: 1ba8596e2761be75cc35f79e8245a96d6bb81096 GitHub-Pull-Request: golang/go#74679 Reviewed-on: https://go-review.googlesource.com/c/go/+/689055 Auto-Submit: Jorropo <jorropo.pgm@gmail.com> Reviewed-by: Michael Knyszek <mknyszek@google.com> Reviewed-by: Keith Randall <khr@google.com> Reviewed-by: Jorropo <jorropo.pgm@gmail.com> LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com>
Diffstat (limited to 'src/time')
-rw-r--r--src/time/time.go2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/time/time.go b/src/time/time.go
index bcaeee407e..cf9abc7196 100644
--- a/src/time/time.go
+++ b/src/time/time.go
@@ -667,7 +667,7 @@ func (days absDays) split() (century absCentury, cyear absCyear, ayday absYday)
// so do that instead, saving a few cycles.
// See Neri and Schneider, section 8.3
// for more about this optimization.
- hi, lo := bits.Mul32(2939745, uint32(cd))
+ hi, lo := bits.Mul32(2939745, cd)
cyear = absCyear(hi)
ayday = absYday(lo / 2939745 / 4)
return