aboutsummaryrefslogtreecommitdiffhomepage
path: root/doc_src/set.txt
diff options
context:
space:
mode:
authorGravatar Kevin Ballard <kevin@sb.org>2014-07-12 14:40:46 -0700
committerGravatar Kevin Ballard <kevin@sb.org>2014-07-12 15:35:34 -0700
commitdcc043df3b4d3f2f8aae5d8e8fe50051f78ce848 (patch)
treeec71da325775526d617e946bef394210154176c3 /doc_src/set.txt
parent2457997cd9c624034f28f1be218f93cdc60a3e58 (diff)
Add an optional mode to env_get_string()
The mode restricts the scope in which the variable is searched for. Use this new restricted scope functionality in the `set` builtin. This fixes `set -g` to not show local shadowing variable values, and also allows for scoped erasing of slices.
Diffstat (limited to 'doc_src/set.txt')
-rw-r--r--doc_src/set.txt6
1 files changed, 1 insertions, 5 deletions
diff --git a/doc_src/set.txt b/doc_src/set.txt
index f72d9018..6602e860 100644
--- a/doc_src/set.txt
+++ b/doc_src/set.txt
@@ -65,11 +65,7 @@ to the scoping rules for variables:
In query mode, the scope to be examined can be specified.
In erase mode, if variable indices are specified, only the specified
-slices of the array variable will be erased. When erasing an entire
-variable (i.e. no slicing), the scope of the variable to be erased can
-be specified. That way, a global variable can be erased even if a
-local variable with the same name exists. Scope can not be specified
-when erasing a slice of an array. The innermost scope is always used.
+slices of the array variable will be erased.
\c set requires all options to come before any
other arguments. For example, <code>set flags -l</code> will have