Auto merge of #12765 - yusufraji:while-float, r=llogiq

Add new lint `while_float`

This PR adds a nursery lint that checks for while loops comparing floating point values.

changelog:
```
changelog: [`while_float`]: Checks for while loops comparing floating point values.
```

Fixes #758
This commit is contained in:
bors 2024-05-21 11:36:31 +00:00
commit 2efebd2f0c
6 changed files with 92 additions and 0 deletions

View file

@ -293,6 +293,7 @@ pub(crate) static LINTS: &[&crate::LintInfo] = &[
crate::loops::SAME_ITEM_PUSH_INFO,
crate::loops::SINGLE_ELEMENT_LOOP_INFO,
crate::loops::UNUSED_ENUMERATE_INDEX_INFO,
crate::loops::WHILE_FLOAT_INFO,
crate::loops::WHILE_IMMUTABLE_CONDITION_INFO,
crate::loops::WHILE_LET_LOOP_INFO,
crate::loops::WHILE_LET_ON_ITERATOR_INFO,