From d5f3a09ce932779346d521afe1ba0ffdcb1cbfa9 Mon Sep 17 00:00:00 2001 From: ridiculousfish Date: Fri, 23 Oct 2015 15:15:39 -0700 Subject: Make 'set -ql' search up to function scope Previously 'set -ql' would only look for variables in the immediate local scope. This was not very useful. It's also arguably surprising, since a 'set -l' in a function, followed by a 'set -ql' in a child block, would fail. There was also no way to check for a function-scoped variable, since omitting the scope would also pull in global variables. We could revisit this and introduce an explicit function scope. Fixes #2502 --- tests/test4.out | 2 ++ 1 file changed, 2 insertions(+) (limited to 'tests/test4.out') diff --git a/tests/test4.out b/tests/test4.out index 148d870c..f38fa96f 100644 --- a/tests/test4.out +++ b/tests/test4.out @@ -34,3 +34,5 @@ Verify that set passes through exit status, except when passed -n or -q or -e 9 1 10 0 A 11 1 B +Verify set -ql behavior +Pass -- cgit v1.2.3