gitlab.com/evatix-go/core@v1.3.55/reqtype/RangesInBetween.go (about) 1 package reqtype 2 3 func RangesInBetween( 4 start, end Request, 5 ) []Request { 6 startVal := start.Value() 7 endVal := end.Value() 8 length := endVal - startVal + 1 9 10 slice := make( 11 []Request, 12 length) 13 14 index := 0 15 for i := startVal; i < endVal; i++ { 16 slice[index] = Request(i) 17 index++ 18 } 19 20 return slice 21 }