mirror of
https://github.com/koalaman/shellcheck.git
synced 2025-08-21 13:53:11 +08:00
Split SC2165 messages into separate codes (2167).
This commit is contained in:
@@ -3486,7 +3486,7 @@ checkLoopVariableReassignment params token =
|
|||||||
next <- listToMaybe $ filter (\x -> loopVariable x == Just str) path
|
next <- listToMaybe $ filter (\x -> loopVariable x == Just str) path
|
||||||
return $ do
|
return $ do
|
||||||
warn (getId token) 2165 "This nested loop overrides the index variable of its parent."
|
warn (getId token) 2165 "This nested loop overrides the index variable of its parent."
|
||||||
warn (getId next) 2165 "This parent loop has its index variable overridden."
|
warn (getId next) 2167 "This parent loop has its index variable overridden."
|
||||||
path = drop 1 $ getPath (parentMap params) token
|
path = drop 1 $ getPath (parentMap params) token
|
||||||
loopVariable :: Token -> Maybe String
|
loopVariable :: Token -> Maybe String
|
||||||
loopVariable t =
|
loopVariable t =
|
||||||
|
Reference in New Issue
Block a user