1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30
# couple of errors here func() { local qux=7 local qux=(one two) local what=(zero one two) } readonly qux=42 func func2() { declare -gA foo=([zero]=zero [one]=one) declare -ga bar=(zero one) } foo=help bar=me func2 declare -p foo bar unset foo bar func2 declare -p foo bar readonly a=7 a=(1 2 3)