Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

time: Date -1 day no support leap year #66087

Closed
kkbblzq opened this issue Mar 4, 2024 · 0 comments
Closed

time: Date -1 day no support leap year #66087

kkbblzq opened this issue Mar 4, 2024 · 0 comments

Comments

@kkbblzq
Copy link

kkbblzq commented Mar 4, 2024

Go version

go version go1.21.5 darwin/arm64

Output of go env in your module/workspace:

GO111MODULE='on'
GOARCH='arm64'
GOBIN=''
GOCACHE='/Users/kkbblzq/Library/Caches/go-build'
GOENV='/Users/kkbblzq/Library/Application Support/go/env'
GOEXE=''
GOEXPERIMENT=''
GOFLAGS=''
GOHOSTARCH='arm64'
GOHOSTOS='darwin'
GOINSECURE=''
GOMODCACHE='/Users/kkbblzq/go/pkg/mod'
GONOPROXY=''
GONOSUMDB=''
GOOS='darwin'
GOPATH='/Users/kkbblzq/go'
GOPRIVATE=''
GOPROXY=''
GOROOT='/usr/local/go'
GOSUMDB='sum.golang.google.cn'
GOTMPDIR=''
GOTOOLCHAIN='auto'
GOTOOLDIR='/usr/local/go/pkg/tool/darwin_arm64'
GOVCS=''
GOVERSION='go1.21.5'
GCCGO='gccgo'
AR='ar'
CC='clang'
CXX='clang++'
CGO_ENABLED='1'
GOMOD='/Users/kkbblzq/Project/fbi/go.mod'
GOWORK=''
CGO_CFLAGS='-O2 -g'
CGO_CPPFLAGS=''
CGO_CXXFLAGS='-O2 -g'
CGO_FFLAGS='-O2 -g'
CGO_LDFLAGS='-O2 -g'
PKG_CONFIG='pkg-config'
GOGCCFLAGS='-fPIC -arch arm64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -ffile-prefix-map=/var/folders/_j/w0czbxzx2fx32lthvq2414vj_7h1lx/T/go-build402564328=/tmp/go-build -gno-record-gcc-switches -fno-common'

What did you do?

time.Date(2024, 3, -1, 0, 0, 0, 0, time.Local)

What did you see happen?

got '2024-02-28 00:00:00 +0800 CST'

What did you expect to see?

got '2024-02-29 00:00:00 +0800 CST'

@kkbblzq kkbblzq closed this as not planned Won't fix, can't repro, duplicate, stale Mar 4, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant