commit | d515b24adc211842433ce9018178372b9bc6f146 | [log] [tgz] |
---|---|---|
author | Jay Conrod <jayconrod@google.com> | Fri Feb 26 16:21:27 2021 -0500 |
committer | Dmitri Shuralyov <dmitshur@golang.org> | Tue Mar 02 22:50:53 2021 +0000 |
tree | ae949034564029b75fabc52bceabdbc61381ea7e | |
parent | 2823f815b3c909fe0ef26d6e1b6145cf200ae16e [diff] |
[internal-branch.go1.16-vendor] module: allow leading dots in import path elements These were always disallowed, but the restriction wasn't enforced in most cases until Go 1.16. That's broken more projects than we hoped. This change allows leading dots in import path elements. Leading dots are still not allowed in module path elements. Leading dots were always allowed in file path elements. Trailing dots are still forbidden in all cases. For golang/go#44647 Change-Id: Id9cf728a341931565ab9e81f600b2341aa178683 Reviewed-on: https://go-review.googlesource.com/c/mod/+/297089 Trust: Jay Conrod <jayconrod@google.com> Run-TryBot: Jay Conrod <jayconrod@google.com> TryBot-Result: Go Bot <gobot@golang.org> Reviewed-by: Bryan C. Mills <bcmills@google.com> (cherry picked from commit c8bb1bd8a2aaa5c50fa106c8116850d503792d16) Reviewed-on: https://go-review.googlesource.com/c/mod/+/298009 Reviewed-by: Dmitri Shuralyov <dmitshur@golang.org>
This repository holds packages for writing tools that work directly with Go module mechanics. That is, it is for direct manipulation of Go modules themselves.
It is NOT about supporting general development tools that need to do things like load packages in module mode. That use case, where modules are incidental rather than the focus, should remain in x/tools, specifically x/tools/go/packages.
The specific case of loading packages should still be done by invoking the go command, which remains the single point of truth for package loading algorithms.