1
0
mirror of https://github.com/golang/go synced 2024-11-18 20:24:41 -07:00
go/imports
Dmitri Shuralyov 1154a04eb0 go.tools/imports: fix case where output not gofmt-compatible
Fixes 7866. Adds a test case.

When trying to add newlines before certain imports via text manipulation,
a regex is used to iterate over all imports. The regex failed to match
dot imports because \w doesn't match a literal dot. This changes the regex
to accept a dot as well.

LGTM=bradfitz
R=bradfitz
CC=golang-codereviews
https://golang.org/cl/99400043
2014-05-20 14:02:16 -07:00
..
fix_test.go go.tools/imports: fix case where output not gofmt-compatible 2014-05-20 14:02:16 -07:00
fix.go go.tools: fix various typos 2014-05-02 14:38:08 -07:00
imports.go go.tools/imports: fix case where output not gofmt-compatible 2014-05-20 14:02:16 -07:00
mkindex.go go.tools/imports: move goimports from github to go.tools. 2013-12-17 21:21:03 -05:00
mkstdlib.go imports: bake in the standard library again 2014-01-26 09:47:31 -08:00
sortimports_compat.go go.tools/imports: move goimports from github to go.tools. 2013-12-17 21:21:03 -05:00
sortimports.go go.tools/imports: move goimports from github to go.tools. 2013-12-17 21:21:03 -05:00
zstdlib.go imports: bake in the standard library again 2014-01-26 09:47:31 -08:00