aboutsummaryrefslogtreecommitdiffhomepage
path: root/doc_src/set.txt
diff options
context:
space:
mode:
authorGravatar Jan Kanis <jan.code@jankanis.nl>2012-12-29 16:39:41 +0100
committerGravatar ridiculousfish <corydoras@ridiculousfish.com>2012-12-29 11:56:10 -0800
commit737972be2f326bfffb9f1db43a0f9f99bad49e58 (patch)
tree163700b713dbb456df21325e7625052526677a9a /doc_src/set.txt
parent4cb70e8e2a718d62122401b8cbe0353136606433 (diff)
clarify docs on variable scope in functions
Diffstat (limited to 'doc_src/set.txt')
-rw-r--r--doc_src/set.txt2
1 files changed, 1 insertions, 1 deletions
diff --git a/doc_src/set.txt b/doc_src/set.txt
index 7a2faf08..63a15d71 100644
--- a/doc_src/set.txt
+++ b/doc_src/set.txt
@@ -44,7 +44,7 @@ The scoping rules when creating or updating a variable are:
-# If a variable is explicitly set to either universal, global or local, that setting will be honored. If a variable of the same name exists in a different scope, that variable will not be changed.
-# If a variable is not explicitly set to be either universal, global or local, but has been previously defined, the previous variable scope is used.
--# If a variable is not explicitly set to be either universal, global or local and has never before been defined, the variable will be local to the currently executing functions. If no function is executing, the variable will be global.
+-# If a variable is not explicitly set to be either universal, global or local and has never before been defined, the variable will be local to the currently executing function. Note that this is different from using the \c -l or \c --local flag. If one of those flags is used, the variable will be local to the most inner currently executing block, while without these the variable will be local to the function. If no function is executing, the variable will be global.
The exporting rules when creating or updating a variable are identical
to the scoping rules for variables: