Skip to content

Commit

Permalink
Add Nil return type restriction to `String::Formatter#consume_subst…
Browse files Browse the repository at this point in the history
…itution` (#14430)
  • Loading branch information
straight-shoota authored Apr 5, 2024
1 parent 76ea339 commit 1675145
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/string/formatter.cr
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ struct String::Formatter(A)
end
end

private def consume_substitution
private def consume_substitution : Nil
key = consume_substitution_key '}'
# note: "`@io << (arg_at(key))` has no type" without this `arg` variable
arg = arg_at(key)
Expand Down

0 comments on commit 1675145

Please sign in to comment.