mirror of
git://git.code.sf.net/p/zsh/code
synced 2024-05-31 20:36:03 +02:00
32091: WARN_CREATE_GLOBAL false positive.
In cases like () { foo=bar =true; }
This commit is contained in:
parent
c1a15fb152
commit
b28a6365f6
|
@ -1,3 +1,9 @@
|
|||
2013-12-06 Peter Stephenson <p.stephenson@samsung.com>
|
||||
|
||||
* Daniel Shahaf: 32091: Src/exec.c, Test/E01options.ztst:
|
||||
WARN_CREATE_GLOBAL false positive for assignment before
|
||||
commands.
|
||||
|
||||
2013-12-05 Peter Stephenson <p.w.stephenson@ntlworld.com>
|
||||
|
||||
* Daniel Shahaf: 32089:
|
||||
|
@ -39,7 +45,7 @@
|
|||
Src/Modules/example.c, Src/module.c: Rationalise character
|
||||
encodings: shell functions are strictly ASCII for maximum
|
||||
portability; other files needed for building and documentation
|
||||
are ASCII are UTF-8; test files may use ISO-8859-X (we don't
|
||||
are ASCII or UTF-8; test files may use ISO-8859-X (we don't
|
||||
require the Euro symbol) where needed to get single character
|
||||
input with the top bit set.
|
||||
|
||||
|
|
|
@ -3309,7 +3309,10 @@ execcmd(Estate state, int input, int output, int how, int last1)
|
|||
}
|
||||
if (type == WC_SIMPLE) {
|
||||
if (varspc) {
|
||||
addvars(state, varspc, ADDVAR_EXPORT|ADDVAR_RESTRICT);
|
||||
int addflags = ADDVAR_EXPORT|ADDVAR_RESTRICT;
|
||||
if (forked)
|
||||
addflags |= ADDVAR_RESTORE;
|
||||
addvars(state, varspc, addflags);
|
||||
if (errflag)
|
||||
_exit(1);
|
||||
}
|
||||
|
|
|
@ -83,12 +83,13 @@
|
|||
%prep
|
||||
mkdir options.tmp && cd options.tmp
|
||||
|
||||
mkdir tmpcd
|
||||
mkdir tmpcd homedir
|
||||
|
||||
touch tmpfile1 tmpfile2
|
||||
|
||||
mydir=$PWD
|
||||
mydirt=`print -P %~`
|
||||
mydirhome=`export HOME=$mydir/homedir; print -P %~`
|
||||
catpath=$(which cat)
|
||||
lspath==ls
|
||||
|
||||
|
@ -513,10 +514,10 @@
|
|||
print *(#q:s/#(#b)tmp(*e)/'scrunchy${match[1]}'/)
|
||||
unsetopt histsubstpattern
|
||||
0:HIST_SUBST_PATTERN option
|
||||
>TINGcd TINGfile1 TINGfile2
|
||||
>TINGcd TINGfile1 TINGfile2 homedir
|
||||
>THUMPcd THUMPfile1 THUMPfile2
|
||||
>one.c Two.X Three.X
|
||||
>scrunchyfile1 scrunchyfile2 tmpcd
|
||||
>homedir scrunchyfile1 scrunchyfile2 tmpcd
|
||||
|
||||
setopt ignorebraces
|
||||
echo X{a,b}Y
|
||||
|
@ -853,6 +854,7 @@
|
|||
|
||||
# Do you have any idea how dull this is?
|
||||
|
||||
(export HOME=$mydir/homedir
|
||||
pushd $mydir/tmpcd
|
||||
pushd
|
||||
dirs
|
||||
|
@ -863,11 +865,11 @@
|
|||
popd
|
||||
pushd
|
||||
popd
|
||||
dirs
|
||||
dirs)
|
||||
0q:PUSHD_TO_HOME option
|
||||
>$mydirt $mydirt/tmpcd
|
||||
>~ $mydirt $mydirt/tmpcd
|
||||
>$mydirt
|
||||
>$mydirhome $mydirhome/tmpcd
|
||||
>~ $mydirhome $mydirhome/tmpcd
|
||||
>$mydirhome
|
||||
|
||||
array=(one two three four)
|
||||
setopt rcexpandparam
|
||||
|
@ -1067,6 +1069,7 @@
|
|||
fn2() {
|
||||
foo3=bar6
|
||||
}
|
||||
foo4=bar7 =true
|
||||
}
|
||||
fn
|
||||
0:WARN_CREATE_GLOBAL option
|
||||
|
|
Loading…
Reference in New Issue