Op 02-05-18 om 02:20 schreef Chet Ramey:
You complained that `typeset +x' didn't `unexport' a variable. The reason > is
that the variable assignment preceding the special builtin caused a
variable to be created at the global scope, and the `typeset' resulted in
a local variable being created.
On Wed, May 02, 2018 at 03:07:42PM +0100, Martijn Dekker wrote:
> Let's see if I'm getting it right this time. In the following:
> set -o posix
> f() { foo=bar : ; }
> f
> the command 'foo=bar :'
> 1. makes the assignment 'foo=bar' survive the ':' command;
> 2. gives 'foo' a globa
On Wed, May 02, 2018 at 10:32:52AM -0400, Greg Wooledge wrote:
> wooledg:~$ bash
> wooledg:~$ set -o posix
> wooledg:~$ f() { foo=bar; foo=baz : ; }; f
> wooledg:~$ declare -p foo
> declare -x foo="baz"
>
> What did you see that led you to conclude there is a local variable
> involved? (Not count
Op 02-05-18 om 15:38 schreef Greg Wooledge:
*NOW* there's evidence of a local variable, because unset removes it
and exposes the global.
Right. That's what triggered my initial report, in which I confused that
phenomenon for a failure of the 'unset' command to unset the variable.
But it's
On 5/2/18 10:07 AM, Martijn Dekker wrote:
> Op 02-05-18 om 02:20 schreef Chet Ramey:
>> You complained that `typeset +x' didn't `unexport' a variable. The
>> reason > is that the variable assignment preceding the special builtin
>> caused a
>> variable to be created at the global scope, and the `t
I'd like to report the minor issue that the 'help builtin' command has
an extra '.' at the end of the 'exit status' section.
bash --version
GNU bash, version 4.2.25(1)-release (x86_64-pc-linux-gnu)
builtin: builtin [shell-builtin [arg ...]]
Execute shell builtins.
Execute SHEL