blob: d0269fb6bf78d94a887be175c8e3e6843a97aa31 [file] [log] [blame]
f()
{
local str=F
g str
}
g()
{
local -n ref=$1
printf "%s " "$ref"
ref=G
}
str=OUTSIDE;
f
printf "%s\n" "$str"
unset -f f g
unset str
f() { local -a arr=(F); g arr; };
g() { local -n ref=$1; printf "%s " "${ref[0]}"; ref=(G); };
arr=(OUTSIDE);
f;
printf "%s\n" "${arr[0]}"