]> Cypherpunks repositories - gostls13.git/commit
cmd/go/internal/get: propagate parse errors in parseMetaGoImports
authorBryan C. Mills <bcmills@google.com>
Mon, 5 Aug 2019 18:39:48 +0000 (14:39 -0400)
committerBryan C. Mills <bcmills@google.com>
Wed, 11 Sep 2019 16:25:52 +0000 (16:25 +0000)
commit95e1ea4598175a3461f40d00ce47a51e5fa6e5ea
tree9402bcc90245b053cbae88c5dfda97745627cd2e
parent8fb9fa36f5b7cf161d0694fdb418af7c83b946d5
cmd/go/internal/get: propagate parse errors in parseMetaGoImports

The signature of parseMetaGoImports implies that it can return an error,
but it has not done so since CL 119675. Restore the missing error check,
and remove the named return-values to avoid reintroducing this bug in the
future.

Updates #30748
Updates #21291

Change-Id: Iab19ade5b1c23c282f3c385a55ed277465526515
Reviewed-on: https://go-review.googlesource.com/c/go/+/189778
Run-TryBot: Bryan C. Mills <bcmills@google.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Jay Conrod <jayconrod@google.com>
src/cmd/go/internal/get/discovery.go