Skip to content

Commit

Permalink
Update empty_loop.rs
Browse files Browse the repository at this point in the history
  • Loading branch information
jamedzung committed Mar 26, 2024
1 parent 11367f5 commit 7b47b41
Showing 1 changed file with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
//! Detect potential overflow scenarios where the number of bits being shifted exceeds the bit width of
//! the variable being shifted, which could lead to unintended behavior or loss of data. If such a
//! potential overflow is detected, a warning is generated to alert the developer.
//! Detects empty loop expressions, including `while(true) {}` and `loop {}` without exit mechanisms, highlighting potential infinite loops.
//! Aims to identify and warn against loops that may lead to hangs or excessive resource consumption due to lack of content.
//! Encourages adding meaningful logic within loops or ensuring proper exit conditions to improve code reliability and maintainability.
use crate::{
diag,
diagnostics::{
Expand Down

0 comments on commit 7b47b41

Please sign in to comment.