Re: Arrays declared global in function and initialised in same line are not visible outside of function

2012-06-18 Thread Pierre Gaston
On Mon, Jun 18, 2012 at 9:35 PM, Greg Wooledge wrote: > On Mon, Jun 18, 2012 at 02:19:41PM +0100, Jacobo de Vera wrote: > >> Subject: Re: Arrays declared global in function and initialised in same line >> are not visible outside of function > > I can't reproduce that problem: Probably because yo

Re: Arrays declared global in function and initialised in same line are not visible outside of function

2012-06-18 Thread Greg Wooledge
On Mon, Jun 18, 2012 at 02:19:41PM +0100, Jacobo de Vera wrote: > Subject: Re: Arrays declared global in function and initialised in same line > are not visible outside of function I can't reproduce that problem: imadev:~$ unset a; f() { declare -ga a=(1 2); }; f; declare -p a declare -a a='([0

Arrays declared global in function and initialised in same line are not visible outside of function

2012-06-18 Thread Jacobo de Vera
Configuration Information [Automatically generated, do not change]: Machine: x86_64 OS: linux-gnu Compiler: gcc Compilation CFLAGS: -DPROGRAM='bash' -DCONF_HOSTTYPE='x86_64' -DCONF_OSTYPE='linux-gnu' -DCONF_MACHTYPE='x86_64-pc-linux-gnu' -DCONF_VENDOR='pc' -DLOCALEDIR='/usr/share/locale' -DPACKAGE