It’s possible to use a different method name (“FormatNew”?) to avoid back compat issues. But yeah, it would be a bit ugly.
It might make sense to revisit this if Go ever grows i18n for datetimes. > On Oct 26, 2022, at 23:44, Rob Pike <r...@golang.org> wrote: > > Not without breaking compatibility. > > -rob > > > On Thu, Oct 27, 2022 at 5:15 PM Alex Besogonov <alex.besogo...@gmail.com > <mailto:alex.besogo...@gmail.com>> wrote: >> Can we perhaps get a bit more unambiguous reference date for it? >> >> On Wednesday, October 26, 2022 at 1:06:36 PM UTC-7 Rob 'Commander' Pike >> wrote: >>> I believe it's unique. I thought of it one day while walking home. It is >>> inspired by the way Cobol picture clauses represent number formats. (That >>> said, I've never programmed in Cobol.) >>> >>> -rob >>> >>> >>> On Thu, Oct 27, 2022 at 4:51 AM Ayan George <ay...@ayan.net <>> wrote: >>>> >>>> I'm really impressed by the simplicity of Go's time formatting and parsing >>>> mechanisms -- particularly when compared with strftim(). >>>> >>>> Does anyone know the origin or history of it? Is there a precedent for >>>> using reference layouts that include string like 2006, January, etc.? >>>> >>>> Do other languages provide something similar or is this completely unique >>>> to Go? >>>> >>>> Can someone point me to or describe the history of Go's time formatting >>>> method? >>>> >>>> -ayan >>>> >>> >>>> -- >>>> You received this message because you are subscribed to the Google Groups >>>> "golang-nuts" group. >>>> To unsubscribe from this group and stop receiving emails from it, send an >>>> email to golang-nuts...@googlegroups.com <>. >>>> To view this discussion on the web visit >>>> https://groups.google.com/d/msgid/golang-nuts/baa45515-cde6-4c7c-a34c-54ddf7da807en%40googlegroups.com >>>> >>>> <https://groups.google.com/d/msgid/golang-nuts/baa45515-cde6-4c7c-a34c-54ddf7da807en%40googlegroups.com?utm_medium=email&utm_source=footer>. >> >> >> -- >> You received this message because you are subscribed to the Google Groups >> "golang-nuts" group. >> To unsubscribe from this group and stop receiving emails from it, send an >> email to golang-nuts+unsubscr...@googlegroups.com >> <mailto:golang-nuts+unsubscr...@googlegroups.com>. >> To view this discussion on the web visit >> https://groups.google.com/d/msgid/golang-nuts/c8f3bc05-3b30-45ad-9e7a-4c12481494d8n%40googlegroups.com >> >> <https://groups.google.com/d/msgid/golang-nuts/c8f3bc05-3b30-45ad-9e7a-4c12481494d8n%40googlegroups.com?utm_medium=email&utm_source=footer>. -- You received this message because you are subscribed to the Google Groups "golang-nuts" group. To unsubscribe from this group and stop receiving emails from it, send an email to golang-nuts+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/golang-nuts/FD2CADB2-B8FF-4C76-A34F-0C71E2D51402%40gmail.com.