이 페이지는 아직 영어로 제공되지 않습니다. 번역 작업 중입니다.
현재 번역 프로젝트에 대한 질문이나 피드백이 있으신 경우 언제든지 연락주시기 바랍니다.

Metadata

ID: go-best-practices/time-parse-format

Language: Go

Severity: Info

Category: Best Practices

Description

Make sure your code use a valid time format. See the official Go documentation for the valid time format.

Non-Compliant Code Examples

func main() {
    time.Parse("foobar", something)
    time.Parse("00", something_else);
}

Compliant Code Examples

func main() {
    time.Parse(time.ANSIC, something)
    time.Parse("2006-01-02", something_else)

    mytime := time.ANSIC
    time.Parse(mytime, another_thing)
}
PREVIEWING: aliciascott/DOCS-9725-Cloudcraft