cmd/go: populate module info even if an error occurs in loading package
The existing implementation ignores module info if there is any error loading the package.
Fixes #44287
Change-Id: I24142e4c7256517292fc654e29d759871b80bc09
GitHub-Last-Rev:
28e9bf85e8c119f3b805c38c79aef60322fcc551
GitHub-Pull-Request: golang/go#45777
Reviewed-on: https://go-review.googlesource.com/c/go/+/313549
Reviewed-by: Bryan C. Mills <bcmills@google.com>
Reviewed-by: Michael Matloob <matloob@golang.org>
Run-TryBot: Bryan C. Mills <bcmills@google.com>
TryBot-Result: Go Bot <gobot@golang.org>
Trust: Michael Matloob <matloob@golang.org>