mirror of
https://github.com/koalaman/shellcheck
synced 2025-07-10 15:22:58 -07:00
Fix issue #1724
(bash: missing support for 'builtin' keyword) Now shellcheck looks for the arguments to 'builtin' to determine read/written variables. A change in the parser makes sure that assignments are parsed correctly in commands that start with 'builtin'.
This commit is contained in:
parent
60f75e5b8a
commit
0e0de94045
4 changed files with 14 additions and 2 deletions
|
@ -2168,6 +2168,7 @@ prop_checkUnassignedReferences35= verifyNotTree checkUnassignedReferences "echo
|
|||
prop_checkUnassignedReferences36= verifyNotTree checkUnassignedReferences "read -a foo -r <<<\"foo bar\"; echo \"$foo\""
|
||||
prop_checkUnassignedReferences37= verifyNotTree checkUnassignedReferences "var=howdy; printf -v 'array[0]' %s \"$var\"; printf %s \"${array[0]}\";"
|
||||
prop_checkUnassignedReferences38= verifyTree (checkUnassignedReferences' True) "echo $VAR"
|
||||
prop_checkUnassignedReferences39= verifyNotTree checkUnassignedReferences "builtin export var=4; echo $var"
|
||||
|
||||
checkUnassignedReferences = checkUnassignedReferences' False
|
||||
checkUnassignedReferences' includeGlobals params t = warnings
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue