Skip to content

Commit

Permalink
Remove redundant elif
Browse files Browse the repository at this point in the history
  • Loading branch information
nojaf committed Feb 20, 2023
1 parent d69b7bf commit 437e223
Showing 1 changed file with 1 addition and 8 deletions.
9 changes: 1 addition & 8 deletions src/Fantomas.Core/MultipleDefineCombinations.fs
Original file line number Diff line number Diff line change
Expand Up @@ -69,11 +69,6 @@ type CodeFragment =
1
elif ownLineCount < otherLineCount then
-1
elif
String.IsNullOrWhiteSpace ownContent
&& not (String.IsNullOrWhiteSpace otherContent)
then
-1
elif hasOwnContent && not hasOtherContent then
1
elif not hasOwnContent && hasOtherContent then
Expand All @@ -90,9 +85,7 @@ type CodeFragment =
else 0
// This is an unexpected situation.
// You should never enter the case where you need to compare a hash line with something other than a hash line.
| x, other ->
// TODO: throw custom exception?
failwith $"Cannot compare %A{x} with %A{other}"
| x, other -> failwith $"Cannot compare %A{x} with %A{other}"

type FormatResultForDefines =
{ Result: FormatResult
Expand Down

0 comments on commit 437e223

Please sign in to comment.