Commit efbecc7e authored by Robert Griesemer's avatar Robert Griesemer
Browse files

go/types, types2: explicitly check for non-nil type in LookupFieldOrMethod

Document and enforce API expectation. Add a test so we don't
inadvertently change the function behavior with respect to nil
type arguments.

Fixes #50620.

Change-Id: Ic000bff7504a03006bd248a319c7a2d49dcf09c8
Reviewed-on: https://go-review.googlesource.com/c/go/+/379374


Trust: Robert Griesemer <gri@golang.org>
Run-TryBot: Robert Griesemer <gri@golang.org>
Reviewed-by: default avatarRobert Findley <rfindley@google.com>
TryBot-Result: Gopher Robot <gobot@golang.org>
parent 985d97e6
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment