]> Cypherpunks repositories - gostls13.git/commit
cmd/link: make -w behavior consistent on Windows
authorCherry Mui <cherryyz@google.com>
Tue, 16 Sep 2025 02:50:51 +0000 (22:50 -0400)
committerCherry Mui <cherryyz@google.com>
Tue, 23 Sep 2025 14:58:08 +0000 (07:58 -0700)
commit22ac328856ae4c0dcd3d770f50aac5a2df498989
treedc1f66e53788181610585dfc24fefe4945f05845
parent9b2d39b75bcc8ced3eaab1c841d7d62e27867931
cmd/link: make -w behavior consistent on Windows

On UNIX-like platforms, the -w flag disables DWARF, and the -s
flag implies -w (so it disables both the symbol table and DWARF).
The implied -w can be negated with -w=0, i.e. -s -w=0 disables the
symbol table but keeps the DWARF. Currently, this negation doesn't
work on Windows. This CL makes it so, so it is consistent on all
platforms (that support DWARF).

Change-Id: I19764a15768433afe333b37061cea16f06cb901b
Reviewed-on: https://go-review.googlesource.com/c/go/+/703998
Reviewed-by: Than McIntosh <thanm@golang.org>
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com>
Reviewed-by: David Chase <drchase@google.com>
src/cmd/link/dwarf_test.go
src/cmd/link/internal/ld/pe.go