Environment
- Elixir & Erlang/OTP versions (elixir --version): 1.6.0
- Operating system: OSX 10.13.4
Current behavior
I've found functions with multi-clause style collapses awkwardly when a single clause is used. Given the following code block:
SomeModule.long_function_name_that_approaches_max_columns(argument, acc, fn
%SomeStruct{key: key}, acc -> more_code(key, acc)
end)
The formatter produces:
SomeModule.long_function_name_that_approaches_max_columns(argument, acc, fn %SomeStruct{
key: key
},
acc ->
more_code(key, acc)
end)
Expected behavior
The formatter does not change the original code. I realize using the multi-clause style could be "cheating" in this case, but if you add a second clause, the formatter does not change the code, and the formatted code in this case is very awkwardly styled. Thanks for taking a look!
Environment
Current behavior
I've found functions with multi-clause style collapses awkwardly when a single clause is used. Given the following code block:
The formatter produces:
Expected behavior
The formatter does not change the original code. I realize using the multi-clause style could be "cheating" in this case, but if you add a second clause, the formatter does not change the code, and the formatted code in this case is very awkwardly styled. Thanks for taking a look!