Skip to content

Commit

Permalink
Use min/max builtins
Browse files Browse the repository at this point in the history
  • Loading branch information
mpolden committed Aug 5, 2024
1 parent 27458e9 commit 4865d45
Showing 1 changed file with 0 additions and 16 deletions.
16 changes: 0 additions & 16 deletions client/go/internal/vespa/document/document.go
Original file line number Diff line number Diff line change
Expand Up @@ -401,19 +401,3 @@ func (g *Generator) Read(p []byte) (int, error) {
}
return g.buf.Read(p)
}

type number interface{ float64 | int64 | int }

func min[T number](x, y T) T {
if x < y {
return x
}
return y
}

func max[T number](x, y T) T {
if x > y {
return x
}
return y
}

0 comments on commit 4865d45

Please sign in to comment.