well,
the answer
to dereferecing an array by a name passed as variable (partly resembles pointer)
is (example above re-used):
eval echo "\$$(eval echo "{$gral[@]}")"
with $gral holding the array name
Result:
milk cow budgie pla9ne
You may extend this solution now to iterate bash array (indexed AND associated) content using the index entries.
YEAH! took me much more than 10h net; this ISGlad I found the answer. Thank you all for your attemptshelp!
Accessing the contents of the contents of a variable.
There are hints leading to the result in abs-guide:
https://tldp.org/LDP/abs/html/abs-guide.html#IVR
Committed thanks to Mendel Cooper; so thankful we have this great gift named Advanced Bash-Scripting Guide.
OK,
eval is ugly due to security concerns.
Try to find a better one ...