src/go/types/resolver.go | 2 +- diff --git a/src/go/types/resolver.go b/src/go/types/resolver.go index 114647a2fffecb937bd785c3d85e3467626499a4..4892218b75453cd8cc2f539a74e0269df4bc785c 100644 --- a/src/go/types/resolver.go +++ b/src/go/types/resolver.go @@ -276,7 +276,7 @@ } } if name == "init" { - check.errorf(d.spec.Name, _InvalidInitDecl, "cannot import package as init - init must be a func") + check.errorf(d.spec, _InvalidInitDecl, "cannot import package as init - init must be a func") return }