Skip to content

Commit e67c0f0

Browse files
timothy-kingGo LUCI
authored and
Go LUCI
committed
cmd/compile/internal/noder: replace recompile library error messages
Replaces 'recompile library' error messages with the more accurate 'recompile package' globally. Change-Id: I7247964c76f1fcb94feda37c78bdfb8a1b1a6492 Reviewed-on: https://go-review.googlesource.com/c/go/+/626696 Reviewed-by: Alan Donovan <adonovan@google.com> Commit-Queue: Tim King <taking@google.com> LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com>
1 parent 99253ea commit e67c0f0

File tree

3 files changed

+3
-4
lines changed

3 files changed

+3
-4
lines changed

src/cmd/compile/internal/importer/gcimporter.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -213,7 +213,7 @@ func Import(packages map[string]*types2.Package, path, srcDir string, lookup fun
213213

214214
switch hdr {
215215
case "$$\n":
216-
err = fmt.Errorf("import %q: old textual export format no longer supported (recompile library)", path)
216+
err = fmt.Errorf("import %q: old textual export format no longer supported (recompile package)", path)
217217

218218
case "$$B\n":
219219
// TODO(taking): minimize code delta with src/go/internal/gcimporter.Import.

src/cmd/compile/internal/noder/import.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -308,7 +308,7 @@ func findExportData(f *os.File) (r *bio.Reader, end int64, err error) {
308308

309309
// Expect $$B\n to signal binary import format.
310310
if line != "$$B\n" {
311-
err = errors.New("old export format no longer supported (recompile library)")
311+
err = errors.New("old export format no longer supported (recompile package)")
312312
return
313313
}
314314

src/go/internal/gcimporter/gcimporter.go

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -209,8 +209,7 @@ func Import(fset *token.FileSet, packages map[string]*types.Package, path, srcDi
209209

210210
switch hdr {
211211
case "$$\n":
212-
// TODO(taking): 's/(recompile library)/(recompile package)/g'.
213-
err = fmt.Errorf("import %q: old textual export format no longer supported (recompile library)", path)
212+
err = fmt.Errorf("import %q: old textual export format no longer supported (recompile package)", path)
214213

215214
case "$$B\n":
216215
var exportFormat byte

0 commit comments

Comments
 (0)