From 7bc2cba77286be1bd322ee31eee3e1df3d8761f1 Mon Sep 17 00:00:00 2001 From: qiulaidongfeng <2645477756@qq.com> Date: Wed, 2 Aug 2023 08:31:42 +0800 Subject: [PATCH] reflect: update Type.FieldByNameFunc documentation Change-Id: I8de130962e17ca4e76f6e822116dcd4d29a8bea6 --- src/reflect/type.go | 1 + 1 file changed, 1 insertion(+) diff --git a/src/reflect/type.go b/src/reflect/type.go index 0a72ba6754..fb456cdd9a 100644 --- a/src/reflect/type.go +++ b/src/reflect/type.go @@ -189,6 +189,7 @@ type Type interface { // and FieldByNameFunc returns no match. // This behavior mirrors Go's handling of name lookup in // structs containing embedded fields. + // // If the returned field is promoted from an embedded struct, // then Offset in the returned StructField is the offset in // the embedded struct.