webdav/internal/xml: use the built-in min function

Starting from Go 1.21, the min functions are built-in.

Therefore, we can remove the custom functions with the same name.

Change-Id: Ia13e609358e19cf3863edc0f5a34e737cdcc291f
Reviewed-on: https://go-review.googlesource.com/c/net/+/707555
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com>
Reviewed-by: Carlos Amedee <carlos@golang.org>
Reviewed-by: Junyang Shao <shaojunyang@google.com>
Reviewed-by: Sean Liao <sean@liao.dev>
Auto-Submit: Sean Liao <sean@liao.dev>
This commit is contained in:
cuishuang
2025-09-29 11:53:08 +08:00
committed by Gopher Robot
parent f2e909b982
commit 51f657b16c

View File

@@ -258,13 +258,6 @@ func lookupXMLName(typ reflect.Type) (xmlname *fieldInfo) {
return nil
}
func min(a, b int) int {
if a <= b {
return a
}
return b
}
// addFieldInfo adds finfo to tinfo.fields if there are no
// conflicts, or if conflicts arise from previous fields that were
// obtained from deeper embedded structures than finfo. In the latter