Commit e985d546 authored by Shenghou Ma's avatar Shenghou Ma

time: add note about Parse()'s choice of default year

R=rsc
CC=golang-dev
https://golang.org/cl/7101046
parent 0c026c45
......@@ -637,7 +637,8 @@ func skip(value, prefix string) (string, error) {
//
// Elements omitted from the value are assumed to be zero or, when
// zero is impossible, one, so parsing "3:04pm" returns the time
// corresponding to Jan 1, year 0, 15:04:00 UTC.
// corresponding to Jan 1, year 0, 15:04:00 UTC (note that because the year is
// 0, this time is before the zero Time).
// Years must be in the range 0000..9999. The day of the week is checked
// for syntax but it is otherwise ignored.
func Parse(layout, value string) (Time, error) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment