golang/go

cmd/go: a /.. after a ... in an importpath pattern is confusing

Open

#37,552 opened on Feb 28, 2020

View on GitHub
 (11 comments) (0 reactions) (0 assignees)Go (19,008 forks)batch import
GoCommandNeedsFixhelp wanted

Repository metrics

Stars
 (133,883 stars)
PR merge metrics
 (No merged PRs in 30d)

Description

What version of Go are you using (go version)?

Does this issue reproduce with the latest release?

Yes. It also reproduces with all versions of go (tested up to go1.5).

What operating system and processor architecture are you using (go env)?

What did you do?

From inside the root directory of a module:

$ mkdir build
$ cd build
$ go list .../../
can't load package: package .: no Go files in /home/manlio/src/go/src/github.com/perillo/atexit/build

$ go list .../../../                                                                                                                                    [0]
github.com/perillo/atexit

How are /.. interpreted when after a ... in a pattern?

Contributor guide