mirror of
git://git.code.sf.net/p/zsh/code
synced 2025-01-19 11:31:26 +01:00
37303: test WARN_CREATE_GLOBAL negative cases.
This commit is contained in:
parent
e40a14c5e4
commit
dc8c39efff
1 changed files with 9 additions and 0 deletions
|
@ -1120,6 +1120,15 @@
|
|||
?fn:5: scalar parameter foo1 created globally in function fn
|
||||
?fn:15: numeric parameter foo5 created globally in function fn
|
||||
|
||||
fn() {
|
||||
emulate -L zsh
|
||||
setopt warncreateglobal
|
||||
TZ=UTC date >&/dev/null
|
||||
local um=$(TZ=UTC date 2>/dev/null)
|
||||
}
|
||||
fn
|
||||
0:WARN_CREATE_GLOBAL negative cases
|
||||
|
||||
# This really just tests if XTRACE is egregiously broken.
|
||||
# To test it properly would need a full set of its own.
|
||||
fn() { print message; }
|
||||
|
|
Loading…
Reference in a new issue