diff --git a/src/go/internal/gccgoimporter/parser.go b/src/go/internal/gccgoimporter/parser.go index 1b1d07d3f6e..267c9953e49 100644 --- a/src/go/internal/gccgoimporter/parser.go +++ b/src/go/internal/gccgoimporter/parser.go @@ -599,7 +599,7 @@ func (p *parser) parseNamedType(nlist []interface{}) types.Type { p.skipInlineBody() p.expectEOL() - sig := types.NewSignature(receiver, params, results, isVariadic) + sig := types.NewSignatureType(receiver, nil, nil, params, results, isVariadic) nt.AddMethod(types.NewFunc(token.NoPos, pkg, name, sig)) } } @@ -766,7 +766,7 @@ func (p *parser) parseFunctionType(pkg *types.Package, nlist []interface{}) *typ params, isVariadic := p.parseParamList(pkg) results := p.parseResultList(pkg) - *t = *types.NewSignature(nil, params, results, isVariadic) + *t = *types.NewSignatureType(nil, nil, nil, params, results, isVariadic) return t } diff --git a/src/go/types/universe.go b/src/go/types/universe.go index 6045c61c301..4d52242e613 100644 --- a/src/go/types/universe.go +++ b/src/go/types/universe.go @@ -87,7 +87,7 @@ func defPredeclaredTypes() { obj := NewTypeName(token.NoPos, nil, "error", nil) obj.setColor(black) res := NewVar(token.NoPos, nil, "", Typ[String]) - sig := NewSignature(nil, nil, NewTuple(res), false) + sig := NewSignatureType(nil, nil, nil, nil, NewTuple(res), false) err := NewFunc(token.NoPos, nil, "Error", sig) ityp := &Interface{nil, obj, []*Func{err}, nil, nil, true, nil} computeInterfaceTypeSet(nil, token.NoPos, ityp) // prevent races due to lazy computation of tset