Recognize local -x similarly to export (fixes #2069)

This commit is contained in:
Vidar Holen 2020-10-18 15:15:31 -07:00
parent 218deb6d01
commit 8d99926554
2 changed files with 4 additions and 0 deletions

View file

@ -547,6 +547,9 @@ getReferencedVariableCommand base@(T_SimpleCommand _ _ (T_NormalWord _ (T_Litera
(not $ any (`elem` flags) ["f", "F"])
then concatMap getReference rest
else []
"local" -> if "x" `elem` flags
then concatMap getReference rest
else []
"trap" ->
case rest of
head:_ -> map (\x -> (base, head, x)) $ getVariablesFromLiteralToken head