Skip to content
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

Inconsistencies in if formatting #135

Closed
ovatsus opened this issue Feb 6, 2014 · 1 comment
Closed

Inconsistencies in if formatting #135

ovatsus opened this issue Feb 6, 2014 · 1 comment

Comments

@ovatsus
Copy link

ovatsus commented Feb 6, 2014

In most of the places where if have something like:

if a then
    b
else 
    c

fantomas changes to

if a 
then b
else c

which is fine. But why did it then turned this:

            ||> Array.foldBack (fun line (currentLine, allLines) ->
                if line.StartsWith ("i," + DateTime.Today.ToString("MM/dd/yyyy"))
                then "", line + currentLine :: allLines
                else line + currentLine, allLines)

into this?

            ||> Array.foldBack (fun line (currentLine, allLines) -> 
                    if line.StartsWith("i," + DateTime.Today.ToString("MM/dd/yyyy")) then 
                        "", line + currentLine :: allLines
                    else line + currentLine, allLines)

I'd prefer to keep the then aligned with the else. What was the reason?

@nojaf
Copy link
Contributor

nojaf commented Jan 3, 2020

The formatting of SynExpr.IfThenElse was revisited in #557.
An attempt was made to align with the F# style guide.
Please create a new issue if necessary.

@nojaf nojaf closed this as completed Jan 3, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants