mirror of
https://github.com/fish-shell/fish-shell.git
synced 2026-05-31 20:31:19 -03:00
Execute the conditions of if and while statements outside of their block
Variables set in if and while conditions are in the enclosing block, not
the if/while statement block. For example:
if set -l var (somecommand) ; end
echo $var
will now work as expected.
Fixes #4820. Fixes #1212.
This commit is contained in:
@@ -20,3 +20,6 @@ $argle bargle: invalid var name
|
||||
|
||||
####################
|
||||
# Exporting works
|
||||
|
||||
####################
|
||||
# if/for/while scope
|
||||
|
||||
Reference in New Issue
Block a user