1
0
mirror of https://github.com/golang/go synced 2024-09-28 19:24:29 -06:00

Revert "cmd/compile: enable printing of error URLs by default"

This reverts commit e7a9ca0a53.

Reason for revert: Decided to delay to Go 1.22.

Change-Id: I4635cb4c1372b54cac573041be8a43e294de5183
Reviewed-on: https://go-review.googlesource.com/c/go/+/497975
TryBot-Result: Gopher Robot <gobot@golang.org>
Run-TryBot: Robert Griesemer <gri@google.com>
Reviewed-by: Russ Cox <rsc@golang.org>
Auto-Submit: Robert Griesemer <gri@google.com>
Reviewed-by: Robert Griesemer <gri@google.com>
This commit is contained in:
Robert Griesemer 2023-05-24 16:30:49 +00:00 committed by Gopher Robot
parent 0adcc5ace8
commit 42f387aae1
2 changed files with 3 additions and 4 deletions

View File

@ -164,7 +164,6 @@ func ParseFlags() {
Flag.LinkShared = &Ctxt.Flag_linkshared
Flag.Shared = &Ctxt.Flag_shared
Flag.WB = true
Flag.ErrorURL = true
Debug.ConcurrentOk = true
Debug.InlFuncsWithClosures = 1

View File

@ -184,7 +184,7 @@ func compileInDir(runcmd runCmd, dir string, flags []string, importcfg string, p
if importcfg == "" {
importcfg = stdlibImportcfgFile()
}
cmd := []string{goTool, "tool", "compile", "-e", "-D", "test", "-errorurl=false", "-importcfg=" + importcfg}
cmd := []string{goTool, "tool", "compile", "-e", "-D", "test", "-importcfg=" + importcfg}
if pkgname == "main" {
cmd = append(cmd, "-p=main")
} else {
@ -201,7 +201,7 @@ func compileInDir(runcmd runCmd, dir string, flags []string, importcfg string, p
return runcmd(cmd...)
}
var stdlibImportcfgStringOnce sync.Once // TODO(#56102): Use sync.OnceValue once available. Also below.
var stdlibImportcfgStringOnce sync.Once // TODO(#56102): Use sync.OnceValue once availabe. Also below.
var stdlibImportcfgString string
func stdlibImportcfg() string {
@ -745,7 +745,7 @@ func (t test) run() error {
// Fail if wantError is true and compilation was successful and vice versa.
// Match errors produced by gc against errors in comments.
// TODO(gri) remove need for -C (disable printing of columns in error messages)
cmdline := []string{goTool, "tool", "compile", "-p=p", "-d=panic", "-C", "-e", "-errorurl=false", "-importcfg=" + stdlibImportcfgFile(), "-o", "a.o"}
cmdline := []string{goTool, "tool", "compile", "-p=p", "-d=panic", "-C", "-e", "-importcfg=" + stdlibImportcfgFile(), "-o", "a.o"}
// No need to add -dynlink even if linkshared if we're just checking for errors...
cmdline = append(cmdline, flags...)
cmdline = append(cmdline, long)