mirror of
https://github.com/protocolbuffers/protobuf-go.git
synced 2025-01-17 01:12:51 +00:00
internal/impl: correct reflect.ValueError use
The composites x/tools/analysis pass errors on this use of reflect.ValueError with: ``` internal/impl/message_reflect_field.go:541:10: reflect.ValueError struct literal uses unkeyed fields (composites) ``` This patch adds the missing field names. Change-Id: I1a175aad6e9724c27f2469adc1f3a9b1e8c61e85 Reviewed-on: https://go-review.googlesource.com/c/protobuf/+/553915 Reviewed-by: Christian Höppner <hoeppi@google.com> Reviewed-by: Michael Stapelberg <stapelberg@google.com> Auto-Submit: Michael Stapelberg <stapelberg@google.com> LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com>
This commit is contained in:
parent
56dad288dc
commit
7b7814916b
@ -538,6 +538,6 @@ func isZero(v reflect.Value) bool {
|
||||
}
|
||||
return true
|
||||
default:
|
||||
panic(&reflect.ValueError{"reflect.Value.IsZero", v.Kind()})
|
||||
panic(&reflect.ValueError{Method: "reflect.Value.IsZero", Kind: v.Kind()})
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user