mirror of
https://github.com/fish-shell/fish-shell
synced 2024-12-26 12:53:13 +00:00
905766fca2
* Hoist `for` loop control var to enclosing scope It should be possible to reference the last value assigned to a `for` loop control var when the loop terminates. This makes it easier to detect if we broke out of the loop among other things. This change makes fish `for` loops behave like most other shells. Fixes #1935 * Remove redundant line
51 lines
1.2 KiB
Text
51 lines
1.2 KiB
Text
|
|
####################
|
|
# Comments in odd places don't cause problems
|
|
|
|
####################
|
|
# Bracket expansion
|
|
|
|
####################
|
|
# Escaped newlines
|
|
|
|
####################
|
|
# Simple function tests
|
|
|
|
####################
|
|
# Ensure eval doesn't unnecessarily mess with the exit status
|
|
|
|
####################
|
|
# Verify that we can turn stderr into stdout and then pipe it
|
|
|
|
####################
|
|
# Test that trailing ^ doesn't trigger redirection, see #1873
|
|
|
|
####################
|
|
# Verify that we can pipe something other than stdout
|
|
|
|
####################
|
|
# echo tests
|
|
|
|
####################
|
|
# Verify that pipes don't conflict with fd redirections
|
|
|
|
####################
|
|
# Make sure while loops don't run forever with no-exec (#1543)
|
|
|
|
####################
|
|
# For loops with read-only vars is an error (#4342)
|
|
fish: You cannot use read-only variable 'status' in a for loop
|
|
for status in a b c
|
|
^
|
|
|
|
####################
|
|
# For loop control vars available outside the for block
|
|
|
|
####################
|
|
# Comments allowed in between lines (#1987)
|
|
|
|
####################
|
|
# Backslashes are part of comments and do not join lines (#1255)
|
|
|
|
####################
|
|
# Verify $argv set correctly in sourced scripts (#139)
|