github.com/Ilhicas/nomad@v1.0.4-0.20210304152020-e86851182bc3/jobspec/helper_test.go (about) 1 package jobspec 2 3 // These functions are copied from helper/funcs.go 4 // added here to avoid jobspec depending on any other package 5 6 // intToPtr returns the pointer to an int 7 func intToPtr(i int) *int { 8 return &i 9 } 10 11 // int8ToPtr returns the pointer to an int8 12 func int8ToPtr(i int8) *int8 { 13 return &i 14 } 15 16 // int64ToPtr returns the pointer to an int 17 func int64ToPtr(i int64) *int64 { 18 return &i 19 } 20 21 // Uint64ToPtr returns the pointer to an uint64 22 func uint64ToPtr(u uint64) *uint64 { 23 return &u 24 }