Skip to content

Commit

Permalink
Merge pull request #540 from lucab/ups/avoid-float-cast
Browse files Browse the repository at this point in the history
core: avoid spurious f64 cast and comparison
  • Loading branch information
mgeisler committed Jun 28, 2024
2 parents b7b0965 + 51c425f commit 73241aa
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/core.rs
Original file line number Diff line number Diff line change
Expand Up @@ -357,7 +357,7 @@ where
{
let mut shortened_words = Vec::new();
for word in words {
if word.width() > line_width as f64 {
if word.width > line_width {
shortened_words.extend(word.break_apart(line_width));
} else {
shortened_words.push(word);
Expand Down

0 comments on commit 73241aa

Please sign in to comment.