about summary refs log tree commit diff
path: root/Doc/Zsh/options.yo
diff options
context:
space:
mode:
authorPeter Stephenson <pws@users.sourceforge.net>2005-08-08 16:48:52 +0000
committerPeter Stephenson <pws@users.sourceforge.net>2005-08-08 16:48:52 +0000
commitd307660deeb115dd2061654c2ddcd4407cadb04c (patch)
tree5ee4d623c09b60695a8567ea22f2756c7685cdf3 /Doc/Zsh/options.yo
parentd7902f6badcc63cb76f3534cf542c4bd8889a18a (diff)
downloadzsh-d307660deeb115dd2061654c2ddcd4407cadb04c.tar.gz
zsh-d307660deeb115dd2061654c2ddcd4407cadb04c.tar.xz
zsh-d307660deeb115dd2061654c2ddcd4407cadb04c.zip
21575 plus unposted: Add WARN_CREATE_GLOBAL option
Diffstat (limited to 'Doc/Zsh/options.yo')
-rw-r--r--Doc/Zsh/options.yo10
1 files changed, 10 insertions, 0 deletions
diff --git a/Doc/Zsh/options.yo b/Doc/Zsh/options.yo
index e6e6af025..2f0e7d71d 100644
--- a/Doc/Zsh/options.yo
+++ b/Doc/Zsh/options.yo
@@ -460,6 +460,16 @@ item(tt(UNSET) (tt(PLUS()u), ksh: tt(PLUS()u)) <K> <S> <Z>)(
 Treat unset parameters as if they were empty when substituting.
 Otherwise they are treated as an error.
 )
+pindex(WARN_CREATE_GLOBAL)
+cindex(parameters, warning when created globally)
+item(tt(WARN_CREATE_GLOBAL))(
+Print a warning message when a global parameter is created in a function
+by an assignment.  This often indicates that a parameter has not been
+declared local when it should have been.  Parameters explicitly declared
+global from within a function using tt(typeset -g) do not cause a warning.
+Note that there is no warning when a local parameter is assigned to in
+a nested function, which may also indicate an error.
+)
 enditem()
 
 subsect(History)