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

Something like MultilineBlockBracketsOnSameColumn but for tuples #814

Closed
lydell opened this issue May 8, 2020 · 1 comment
Closed

Something like MultilineBlockBracketsOnSameColumn but for tuples #814

lydell opened this issue May 8, 2020 · 1 comment

Comments

@lydell
Copy link

lydell commented May 8, 2020

Issue created from fantomas-online

Thanks to #453 we can now have [/] and {/} on the same column for multi-line lists and records! 🎉

It would be great if we could do this for tuples as well!

(See also #815)

Motivation: It makes the code easier to edit.

Code

let expected =
    (Event.Author "john",
     [ Event.Revenue
         (Event.RevenueId "123",
          Event.Match
              { transactionId = 1337
                amounts =
                    { total = 2500000L
                      vat = 625000L } }) ])

Result

let expected =
    (Event.Author "john",
     [
         Event.Revenue
             (Event.RevenueId "123",
              Event.Match
                  {
                      transactionId = 1337
                      amounts = { total = 2500000L; vat = 625000L }
                  })
     ])

Suggestion

Something like this would be great.

let expected =
    (
        Event.Author "john",
        [
            Event.Revenue
                (
                    Event.RevenueId "123",
                    Event.Match
                        {
                            transactionId = 1337
                            amounts = { total = 2500000L; vat = 625000L }
                        }
                )
        ]
    )

Options

Fantomas Next - 4.0.0-alpha-001-1/1/1990

Name Value
IndentSpaceNum 4
PageWidth 120
SemicolonAtEndOfLine false
SpaceBeforeParameter true
SpaceBeforeLowercaseInvocation true
SpaceBeforeUppercaseInvocation false
SpaceBeforeClassConstructor false
SpaceBeforeMember false
SpaceBeforeColon false
SpaceAfterComma true
SpaceBeforeSemicolon false
SpaceAfterSemicolon true
IndentOnTryWith false
SpaceAroundDelimiter true
MaxIfThenElseShortWidth 40
MaxInfixOperatorExpression 50
MaxRecordWidth 40
MaxArrayOrListWidth 40
MaxLetBindingWidth 40
MultilineBlockBracketsOnSameColumn true
NewlineBetweenTypeDefinitionAndMembers false
StrictMode false
@lydell lydell changed the title <Insert meaningful title> Something like MultilineBlockBracketsOnSameColumn but for tuples May 8, 2020
@nojaf
Copy link
Contributor

nojaf commented Jun 5, 2021

I'm going to close this as it falls under What are we not looking for?.
There is no interest to pursue this.

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

2 participants