]> Cypherpunks.ru repositories - gostls13.git/commitdiff
reflect: clarify that Value.Comparable checks the value
authorIan Lance Taylor <iant@golang.org>
Tue, 27 Sep 2022 16:10:21 +0000 (09:10 -0700)
committerGopher Robot <gobot@golang.org>
Tue, 27 Sep 2022 16:24:53 +0000 (16:24 +0000)
For #46746

Change-Id: Ic7a31ddf7cd6bf6dd0db6b9eb3fee68fc180f72e
Reviewed-on: https://go-review.googlesource.com/c/go/+/435277
Reviewed-by: Ian Lance Taylor <iant@google.com>
Reviewed-by: Bryan Mills <bcmills@google.com>
Run-TryBot: Ian Lance Taylor <iant@google.com>
Auto-Submit: Ian Lance Taylor <iant@google.com>
Run-TryBot: Ian Lance Taylor <iant@golang.org>
TryBot-Result: Gopher Robot <gobot@golang.org>

src/reflect/value.go

index ae6c4daf587b4baad6219aa3be86bca5f54afbe2..89cc37f1db7b503048931829f6094283a0a6911b 100644 (file)
@@ -3261,7 +3261,7 @@ func (v Value) CanConvert(t Type) bool {
        return true
 }
 
-// Comparable reports whether the type of v is comparable.
+// Comparable reports whether the value v is comparable.
 // If the type of v is an interface, this checks the dynamic type.
 // If this reports true then v.Interface() == x will not panic for any x.
 func (v Value) Comparable() bool {