Skip to content

Commit

Permalink
cmd/go: update x/mod to fix "//indirect" comment editing
Browse files Browse the repository at this point in the history
Fixes #45932

Change-Id: I043aecb6224348faf54c1d41fdbc00aa566089c2
Reviewed-on: https://go-review.googlesource.com/c/go/+/316751
Trust: Bryan C. Mills <bcmills@google.com>
Run-TryBot: Bryan C. Mills <bcmills@google.com>
Reviewed-by: Jay Conrod <jayconrod@google.com>
TryBot-Result: Go Bot <gobot@golang.org>
  • Loading branch information
Bryan C. Mills committed May 4, 2021
1 parent f62739b commit 10a082a
Show file tree
Hide file tree
Showing 6 changed files with 39 additions and 5 deletions.
2 changes: 1 addition & 1 deletion src/cmd/go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ require (
github.com/ianlancetaylor/demangle v0.0.0-20200824232613-28f6c0f3b639 // indirect
golang.org/x/arch v0.0.0-20210502124803-cbf565b21d1e
golang.org/x/crypto v0.0.0-20210503195802-e9a32991a82e // indirect
golang.org/x/mod v0.4.3-0.20210503183026-4435ecfe4815
golang.org/x/mod v0.4.3-0.20210504181020-67f1c1edc27a
golang.org/x/sys v0.0.0-20210423082822-04245dca01da // indirect
golang.org/x/term v0.0.0-20210503060354-a79de5458b56
golang.org/x/tools v0.1.1-0.20210503200558-19b1717ea5eb
Expand Down
2 changes: 2 additions & 0 deletions src/cmd/go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,8 @@ golang.org/x/crypto v0.0.0-20210503195802-e9a32991a82e h1:8foAy0aoO5GkqCvAEJ4VC4
golang.org/x/crypto v0.0.0-20210503195802-e9a32991a82e/go.mod h1:P+XmwS30IXTQdn5tA2iutPOUgjI07+tq3H3K9MVA1s8=
golang.org/x/mod v0.4.3-0.20210503183026-4435ecfe4815 h1:9nyskUepGPcX93addfTsdRqsQ7rSWIdQOdWVcsWAYv0=
golang.org/x/mod v0.4.3-0.20210503183026-4435ecfe4815/go.mod h1:5OXOZSfqPIIbmVBIIKWRFfZjPR0E5r58TLhUjH0a2Ro=
golang.org/x/mod v0.4.3-0.20210504181020-67f1c1edc27a h1:wbpC/7Wbo5WFVox32n+KjhRRLmTLq8YW/wRlL2iVAhk=
golang.org/x/mod v0.4.3-0.20210504181020-67f1c1edc27a/go.mod h1:5OXOZSfqPIIbmVBIIKWRFfZjPR0E5r58TLhUjH0a2Ro=
golang.org/x/sys v0.0.0-20191204072324-ce4227a45e2e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20210423082822-04245dca01da h1:b3NXsE2LusjYGGjL5bxEVZZORm/YEFFrWFjR8eFrw/c=
golang.org/x/sys v0.0.0-20210423082822-04245dca01da/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
Expand Down
32 changes: 32 additions & 0 deletions src/cmd/go/testdata/script/mod_indirect_nospace.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
# https://golang.org/issue/45932: "indirect" comments missing spaces
# should not be corrupted when the comment is removed.

go mod tidy
cmp go.mod go.mod.direct

-- go.mod --
module example.net/m

go 1.16

require example.net/x v0.1.0 //indirect

replace example.net/x v0.1.0 => ./x
-- go.mod.direct --
module example.net/m

go 1.16

require example.net/x v0.1.0

replace example.net/x v0.1.0 => ./x
-- m.go --
package m
import _ "example.net/x"

-- x/go.mod --
module example.net/x

go 1.16
-- x/x.go --
package x
4 changes: 2 additions & 2 deletions src/cmd/vendor/golang.org/x/mod/modfile/rule.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion src/cmd/vendor/golang.org/x/mod/module/module.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion src/cmd/vendor/modules.txt
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ golang.org/x/arch/x86/x86asm
## explicit; go 1.17
golang.org/x/crypto/ed25519
golang.org/x/crypto/ed25519/internal/edwards25519
# golang.org/x/mod v0.4.3-0.20210503183026-4435ecfe4815
# golang.org/x/mod v0.4.3-0.20210504181020-67f1c1edc27a
## explicit; go 1.17
golang.org/x/mod/internal/lazyregexp
golang.org/x/mod/modfile
Expand Down

0 comments on commit 10a082a

Please sign in to comment.