We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
Issue created from fantomas-online
let select px = match px with | Shared.Foo _ -> "foo" | Shared.LongerFoobarFoo -> "lf" | Shared.Barry -> "barry" |> List.singleton |> instr "ziggy"
let select px = (match px with | Shared.Foo _ -> "foo" | Shared.LongerFoobarFoo -> "lf" | Shared.Barry -> "barry") |> List.singleton |> instr "ziggy"
In this scenario the parenthesis are not necessary. They would be in case the last clause was multiline.
Like
let select px = match px with | Shared.Foo _ -> "foo" | Shared.LongerFoobarFoo -> "lf" | Shared.Barry -> // foo "barry" |> List.singleton |> instr "ziggy" // would lead to let select px = match px with | Shared.Foo _ -> "foo" | Shared.LongerFoobarFoo -> "lf" | Shared.Barry -> // foo "barry" |> List.singleton |> instr "ziggy"
Not sure, what the best way would be to deal with this. This is hard to detect from the SynExpr.App point of view.
SynExpr.App
So that is why the parenthesis are added in the first place.
Fantomas Master at 05/01/2021 14:37:19 - d8e76d4
{ config with IndentSize = 2 }
Did you know that you can ignore files when formatting from fantomas-tool or the FAKE targets by using a .fantomasignore file?
The text was updated successfully, but these errors were encountered:
Don't add parenthesis if last clause is single line. Fixes fsprojects…
0237e8f
…#1698
4309f90
6e12759
Don't add parenthesis if last clause is single line. (#1699)
0bb9165
* Don't add parenthesis if last clause is single line. Fixes #1698 * Verify last clause was multiline via writer events.
Successfully merging a pull request may close this issue.
Issue created from fantomas-online
Code
Result
Problem description
In this scenario the parenthesis are not necessary.
They would be in case the last clause was multiline.
Like
Not sure, what the best way would be to deal with this.
This is hard to detect from the
SynExpr.App
point of view.So that is why the parenthesis are added in the first place.
Extra information
Options
Fantomas Master at 05/01/2021 14:37:19 - d8e76d4
Did you know that you can ignore files when formatting from fantomas-tool or the FAKE targets by using a .fantomasignore file?
The text was updated successfully, but these errors were encountered: