-
Notifications
You must be signed in to change notification settings - Fork 1.9k
Open
Description
For new checks and feature suggestions
- https://www.shellcheck.net/ (i.e. the latest commit) currently gives no useful warnings about this
- I searched through https://github.com/koalaman/shellcheck/issues and didn't find anything related
Here's a snippet or screenshot that shows the problem:
foo() {
while read -r -d $'\0' file; do
local -r someVar="..."
done
}Here's what shellcheck currently says:
nothing
Here's what I wanted or expected to see:
readonly variable within a loop is smelly as it will fail if the loop is executed more than once
Metadata
Metadata
Assignees
Labels
No labels