Skip to content

Commit ece6872

Browse files
Juneezeeonsi
authored andcommittedNov 15, 2024··
Replace min/max helpers with built-in min/max
We can use the built-in `min` and `max` functions since Go 1.21. Reference: https://go.dev/ref/spec#Min_and_max Signed-off-by: Eng Zer Jun <engzerjun@gmail.com>
1 parent 8e924d7 commit ece6872

File tree

1 file changed

+0
-13
lines changed

1 file changed

+0
-13
lines changed
 

‎gmeasure/table/table.go

-13
Original file line numberDiff line numberDiff line change
@@ -355,16 +355,3 @@ func sum(s []int) int {
355355
return out
356356
}
357357

358-
func min(a int, b int) int {
359-
if a < b {
360-
return a
361-
}
362-
return b
363-
}
364-
365-
func max(a int, b int) int {
366-
if a > b {
367-
return a
368-
}
369-
return b
370-
}

0 commit comments

Comments
 (0)
Please sign in to comment.