Closed
Description
Issue created from fantomas-online
Fantomas is adding an extra set of parenthesis. DataAccess.getById returns a result type. Result.okValue extracts an option type. This is all wrapped in parenthesis, then we are extracting the value with .Value. When we run the formatter, it adds an extra set of parenthesis each time.
Code
let variable =
(DataAccess.getById moduleName.readData
{ Id = createObject.Id }
|> Result.okValue).Value
Result
let variable =
((DataAccess.getById moduleName.readData { Id = createObject.Id }
|> Result.okValue)).Value
Options
Fantomas Master at 06/13/2020 12:50:29 - f502c77
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 |
MaxValueBindingWidth |
40 |
MaxFunctionBindingWidth |
40 |
MultilineBlockBracketsOnSameColumn |
false |
NewlineBetweenTypeDefinitionAndMembers |
false |
KeepIfThenInSameLine |
false |
StrictMode |
false |
Metadata
Assignees
Labels
No labels
Activity
nojaf commentedon Jun 16, 2020
I think this bug is related to the changes of FCS 36.
Are you using Fantomas 4.0.0-alpha-009 by any chance?
andrew-russell-ps commentedon Jun 16, 2020
Yes
Added regression test for fsprojects#921.
Don't add extra parenthesis for DotGet(Paren(_)) (#991)