libgo: better cmd/cgo handling for '.' in pkgpath

Updates cgo's gccgoPkgpathToSymbolNew() to bring it into
conformance with the way that gccgo now handles package
paths with embedded dots (see CL 200838). See also, a related bug. This CL is a
copy of CL 207957 in the main Go repo.

Updates golang/go#35623.

Change-Id: I125b2f051e3a93481ba4f55da51a243172359bfc
Reviewed-by: Ian Lance Taylor <>
1 file changed