chore: interface{} -> any

This commit is contained in:
Alec Thomas
2024-12-29 08:10:34 +09:00
parent 36257680f1
commit a32b94b705
16 changed files with 63 additions and 63 deletions
+1 -1
View File
@@ -69,7 +69,7 @@ func (n *Node) Leaf() bool {
// Find a command/argument/flag by pointer to its field.
//
// Returns nil if not found. Panics if ptr is not a pointer.
func (n *Node) Find(ptr interface{}) *Node {
func (n *Node) Find(ptr any) *Node {
key := reflect.ValueOf(ptr)
if key.Kind() != reflect.Ptr {
panic("expected a pointer")