mirror of
https://github.com/fish-shell/fish-shell.git
synced 2026-05-28 09:31:16 -03:00
set -q: Return 255 if no variable name was passed
Previously this strictly returned the number of unset variables. So if no variable was given, it would return *true*, which is highly suspect.
This commit is contained in:
@@ -820,3 +820,11 @@ function erase-funcvar
|
||||
end
|
||||
|
||||
erase-funcvar
|
||||
|
||||
set --query $this_is_not_set
|
||||
echo $status
|
||||
# CHECK: 255
|
||||
|
||||
set --query
|
||||
echo $status
|
||||
# CHECK: 255
|
||||
|
||||
Reference in New Issue
Block a user