-
-
Notifications
You must be signed in to change notification settings - Fork 112
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Unexpected splitting of function arguments #235
Comments
This rule was tested before the introduction of generics, so my best guess is that this is unintended :) Have you tried the latest master version as well, to see if the same problem occurs? cc @Oiyoo |
Yes, I've tested with the latest master (900c61a) and the same problem occurs. |
I can confirm that this is an issue on |
Here is a possible another case: package fact
func
Factorial(x int) int {
return x * Factorial(x - 1,
)
} converted to: package fact
func Factorial(x int,
) int {
return x * Factorial(x-1)
} |
Given the following code (
constraints
,slices
, andmaps
are thegolang.org/x/exp
packages of the same name):gofumpt@latest
(900c61a) reformats this to:which has this diff:
I did not expect the function arguments to be split over two lines. I'm only starting to learn generics, so this might however be idiomatic. Please do close this issue if it is invalid.
The text was updated successfully, but these errors were encountered: