[Bug fix] Fix rule B909's panic when checking large loop blocks (#11772)

This commit is contained in:
Embers-of-the-Fire 2024-06-06 18:23:28 +08:00 committed by GitHub
parent 6c1fa1d440
commit f144edeefa
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 3 additions and 3 deletions

View File

@ -114,9 +114,9 @@ fn is_mutating_function(function_name: &str) -> bool {
struct LoopMutationsVisitor<'a> { struct LoopMutationsVisitor<'a> {
iter: &'a Expr, iter: &'a Expr,
target: &'a Expr, target: &'a Expr,
mutations: HashMap<u8, Vec<TextRange>>, mutations: HashMap<u32, Vec<TextRange>>,
branches: Vec<u8>, branches: Vec<u32>,
branch: u8, branch: u32,
} }
impl<'a> LoopMutationsVisitor<'a> { impl<'a> LoopMutationsVisitor<'a> {