You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
We are backwards compatible with gofmt in terms of formatting, and in general we want to be a drop-in replacement.
However, some gofmt flags and features don't really belong in gofumpt. For example:
The rewrite flag, -r, isn't used by many people. Those who depend on it should just use gofmt -r.
The simplify flag, -s, is on by default in gofumpt. It makes little sense to allow disabling it. The only use case I can think of is the Go compiler itself, since it needs to bootstrap from a very old version of Go, which might break if -s removes some types which later Go versions made optional. But we could always fix that with the -lang flag.
The -cpuprofile flag is an internal performance tool, so it shouldn't really be exposed. The -e flag probably fits the same bill, but perhaps some users actually make use of it.
The text was updated successfully, but these errors were encountered:
The rewrite flag isn't particularly advanced or powerful.
If some users want it, gofmt will continue to have it.
The simplify flag is on by default in gofumpt,
and we don't really intend the user to turn it off.
Remove the flag entirely, to avoid confusion.
Note that this means we can remove most of rewrite.go,
except the bits needed by simplify.go.
Fixes#105.
Updates #115.
We are backwards compatible with gofmt in terms of formatting, and in general we want to be a drop-in replacement.
However, some gofmt flags and features don't really belong in gofumpt. For example:
-r
, isn't used by many people. Those who depend on it should just usegofmt -r
.-s
, is on by default in gofumpt. It makes little sense to allow disabling it. The only use case I can think of is the Go compiler itself, since it needs to bootstrap from a very old version of Go, which might break if-s
removes some types which later Go versions made optional. But we could always fix that with the-lang
flag.-cpuprofile
flag is an internal performance tool, so it shouldn't really be exposed. The-e
flag probably fits the same bill, but perhaps some users actually make use of it.The text was updated successfully, but these errors were encountered: