You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
letdraftToken=match lastToken with| Some { Kind = GenericTypeParameter | StaticallyResolvedTypeParameter as kind }when isIdentifier token ->
DraftToken.Create kind { token with LeftColumn = token.LeftColumn -1
FullMatchedLength = token.FullMatchedLength +1}| Some ({ Kind = SymbolKind.ActivePattern }as ap)when token.Tag = FSharpTokenTag.RPAREN ->
DraftToken.Create SymbolKind.Ident ap.Token
|_->letkind=if isOperator token then Operator
elif isIdentifier token then Ident
elif isKeyword token then Keyword
elif isPunctuation token then Dot
else Other
DraftToken.Create kind token
Error
Fantomas was able to format the code but the result appears to be invalid F# code.
Please openan issue.
Formatted result:letdraftToken=match lastToken with| Some { Kind = GenericTypeParameter
| StaticallyResolvedTypeParameter as kind }when isIdentifier token ->
DraftToken.Create
kind
{ token with
LeftColumn = token.LeftColumn -1
FullMatchedLength = token.FullMatchedLength +1}| Some ({ Kind = SymbolKind.ActivePattern }as ap)when token.Tag = FSharpTokenTag.RPAREN ->
DraftToken.Create SymbolKind.Ident ap.Token
|_->letkind=if isOperator token then Operator
elif isIdentifier token then Ident
elif isKeyword token then Keyword
elif isPunctuation token then Dot
else Other
DraftToken.Create kind token
Problem description
GenericTypeParameter | StaticallyResolvedTypeParameter cannot be splitted.
Extra information
The formatted result breaks by code.
The formatted result gives compiler warnings.
I or my company would be willing to help fix this.
Issue created from fantomas-online
Code
Error
Problem description
GenericTypeParameter | StaticallyResolvedTypeParameter
cannot be splitted.Extra information
Options
Fantomas Master at 11/12/2020 20:43:50 - 8f6de51
Default Fantomas configuration
The text was updated successfully, but these errors were encountered: