Re: [go-nuts] Issues with parsing `time.String()` in Go 1.19

2022-11-09 Thread Erez Rokah
Thanks for the response, I somehow thought that was added in Go 1.19. Sorry for the confusion and thanks again for the help On Wednesday, 9 November 2022 at 21:54:18 UTC+2 Ian Lance Taylor wrote: > On Wed, Nov 9, 2022 at 9:00 AM Erez Rokah wrote: > > > > The string format used is `"2006-01-02

Re: [go-nuts] Issues with parsing `time.String()` in Go 1.19

2022-11-09 Thread Ian Lance Taylor
On Wed, Nov 9, 2022 at 9:00 AM Erez Rokah wrote: > > The string format used is `"2006-01-02 15:04:05.9 -0700 MST"` which > is `time.String()` internal format Thanks. You originally asked whether this is a bug or not. I don't think this is a bug. It's true that it's not easy to use tim

Re: [go-nuts] Issues with parsing `time.String()` in Go 1.19

2022-11-09 Thread Erez Rokah
The string format used is `"2006-01-02 15:04:05.9 -0700 MST"` which is `time.String()` internal format On Wednesday, 9 November 2022 at 18:48:09 UTC+2 Ian Lance Taylor wrote: > On Wed, Nov 9, 2022 at 8:33 AM Erez Rokah wrote: > > > > I'm not sure if this is a bug or not. The following t

Re: [go-nuts] Issues with parsing `time.String()` in Go 1.19

2022-11-09 Thread Ian Lance Taylor
On Wed, Nov 9, 2022 at 8:33 AM Erez Rokah wrote: > > I'm not sure if this is a bug or not. The following test will print both > error messages: > > ``` > func TestTimeStringParse(t *testing.T) { > for i := 0; i < 10; i++ { > timeString := time.Now().Add(time.Duration(rand.Int63())).Stri