This commit is contained in:
2019-01-31 23:43:33 -06:00
parent 60a25fb3d3
commit 6591db3d5b

14
test.sh
View File

@@ -20,15 +20,15 @@ fi
function myfunc()
{
local -n myresult="$1" || return 1
myresult[0]="a"
myresult[1]="b"
local -n __resultvar="$1" || return 1
__resultvar[0]="a"
__resultvar[1]="b"
echo 'yes';
if [ -f /etc/debian_version ] ; then
myresult[2]="c"
myresult[3]="d"
myresult[4]="e"
fi
__resultvar[2]="c"
__resultvar[3]="d"
__resultvar[4]="e"
fi
echo "ok"
}