time: use values larger than 24 for day for time.Format examples
Currently, the time.Format docs use 7 Mar 2015 as the day/month/year. In numeric form, that is either 7/3/2015 or 3/7/2015 depending on which part of the world you're from. This is extremely confusing. In fact, the reference time being defined in a very US-centric way is quite confusing for the rest of the world, too [1]. We can't change that, but we can make the time.Format docs more comprehendable to the rest of the world without sacrificing by simply choosing a day that is not ambiguous (a value greater than 24 for day). This CL does makes the necessary change. Note: this CL moves some of the padding examples into their own example, since those examples do need a <10 day to demonstrate padding. 1: Additional context: a very old golang-nuts thread in which Rob expresses some regret about the format being the USA standard, rather than the alternative: https://groups.google.com/forum/m/#!msg/golang-nuts/0nQbfyNzk9E/LWbMgpRQNOgJ. Change-Id: If0a07c5e0dab86f8420cbf59543405eb857aa7f2 Reviewed-on: https://go-review.googlesource.com/c/go/+/221612 Run-TryBot: Jean de Klerk <deklerk@google.com> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by:Ian Lance Taylor <iant@golang.org> Reviewed-by:
Rob Pike <r@golang.org>
Loading
Please sign in to comment