mirror of https://github.com/golang/go.git
The span package is properly part of gopls, and we'd like to move it into that module. However, the packagestest package unfortunately depends on span.Span as an alternative notation for Ranges. This change decouples span.Span from packagestest.Range using a new (unexported for now) rangeSetter interface, which Span implements. Neither package depends on the other. Technically this is a breaking API change: all the Range methods have gone away, as have the Span, URI, and Point types and their methods, which were accessible via Range.Span(). However, clients would not be able to access these internal types, and I think it is highly unlikely that anyone depends on it. Nonethless this is a cautionary tale about the risks from one innocuous-looking type alias declaration. Change-Id: I8acb03f4acb1f798f304b03648445e37a44f9c45 Reviewed-on: https://go-review.googlesource.com/c/tools/+/439715 gopls-CI: kokoro <noreply+kokoro@google.com> Run-TryBot: Alan Donovan <adonovan@google.com> TryBot-Result: Gopher Robot <gobot@golang.org> Reviewed-by: Robert Findley <rfindley@google.com> |
||
|---|---|---|
| .. | ||
| parse.go | ||
| span.go | ||
| span_test.go | ||
| token.go | ||
| token_test.go | ||
| uri.go | ||
| uri_test.go | ||
| uri_windows_test.go | ||
| utf16.go | ||
| utf16_test.go | ||