Add support for Duration, add empty values

Signed-off-by: Knut Ahlers <knut@ahlers.me>
This commit is contained in:
Knut Ahlers 2021-07-25 13:43:19 +02:00
parent f59d4dc5b8
commit 465265da95
Signed by: luzifer
GPG key ID: 0066F03ED215AD7D

View file

@ -1,4 +1,12 @@
package main
func ptrInt64(v int64) *int64 { return &v }
func ptrString(v string) *string { return &v }
import "time"
var (
ptrInt64Zero = ptrInt64(0)
ptrStringEmpty = ptrString("")
)
func ptrDuration(v time.Duration) *time.Duration { return &v }
func ptrInt64(v int64) *int64 { return &v }
func ptrString(v string) *string { return &v }