mirror of
https://github.com/golang/go
synced 2024-11-18 18:14:43 -07:00
go/gcimporter15: adopt changes from golang.org/cl/22714
Fixes x/tools build. Change-Id: Ifd958ff1293ec2c4fd971813ae7b199b5d8244fe Reviewed-on: https://go-review.googlesource.com/22721 Reviewed-by: Alan Donovan <adonovan@google.com>
This commit is contained in:
parent
c9a2436076
commit
8dab6f1129
@ -490,8 +490,11 @@ func (p *exporter) paramList(params *types.Tuple, variadic bool) {
|
||||
}
|
||||
p.typ(t)
|
||||
if n > 0 {
|
||||
p.string(q.Name())
|
||||
p.pkg(q.Pkg(), false)
|
||||
name := q.Name()
|
||||
p.string(name)
|
||||
if name != "_" {
|
||||
p.pkg(q.Pkg(), false)
|
||||
}
|
||||
}
|
||||
p.string("") // no compiler-specific info
|
||||
}
|
||||
|
@ -510,10 +510,12 @@ func (p *importer) param(named bool) (*types.Var, bool) {
|
||||
if name == "" {
|
||||
panic("expected named parameter")
|
||||
}
|
||||
if name != "_" {
|
||||
pkg = p.pkg()
|
||||
}
|
||||
if i := strings.Index(name, "·"); i > 0 {
|
||||
name = name[:i] // cut off gc-specific parameter numbering
|
||||
}
|
||||
pkg = p.pkg()
|
||||
}
|
||||
|
||||
// read and discard compiler-specific info
|
||||
|
Loading…
Reference in New Issue
Block a user