Skip to content

Commit

Permalink
fix parse_clause_num function
Browse files Browse the repository at this point in the history
  • Loading branch information
bormilan committed Oct 5, 2024
1 parent 89e87ed commit 6ad6086
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
1 change: 1 addition & 0 deletions Untitled
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
tyl
3 changes: 2 additions & 1 deletion src/elvis_style.erl
Original file line number Diff line number Diff line change
Expand Up @@ -1004,7 +1004,8 @@ max_function_clause_length(Config, Target, RuleConfig) ->
% AccNum;
% clause_num(_, _, _) ->
% 1.

parse_clause_num(Num) when Num rem 100 >= 11, Num rem 100 =< 13 ->
integer_to_list(Num) ++ "th";
parse_clause_num(Num) when Num rem 10 == 1 ->
integer_to_list(Num) ++ "st";
parse_clause_num(Num) when Num rem 10 == 2 ->
Expand Down

0 comments on commit 6ad6086

Please sign in to comment.