mirror of
https://github.com/fish-shell/fish-shell.git
synced 2026-04-22 18:21:13 -03:00
Unallowed command subst error: add missing newline and simplify
Fixes ommitted newline char shown after complete -n'(foo)' Also axes the 'contains syntax errors' line before the error. Update tests before > complete -n'(foo)' complete: Condition '(foo)' contained a syntax error complete: Command substitutions not allowed⏎ after > complete -n'(foo)' complete: -n '(foo)': command substitutions not allowed here
This commit is contained in:
@@ -19,15 +19,15 @@ echo 'true | time false' | $fish 2>| string replace -r '(.*)' '<$1>'
|
||||
|
||||
echo '
|
||||
|
||||
(true one)
|
||||
FOO=BAR (true one)
|
||||
(true two)
|
||||
|
||||
# more things
|
||||
' | $fish 2>| string replace -r '(.*)' '<$1>'
|
||||
|
||||
# CHECK: <fish: Command substitutions not allowed>
|
||||
# CHECK: <(true one)>
|
||||
# CHECK: <^~~~~~~~~^>
|
||||
# CHECK: <fish: command substitutions not allowed here>
|
||||
# CHECK: <FOO=BAR (true one)>
|
||||
# CHECK: < ^~~~~~~~~^>
|
||||
|
||||
$fish -c 'echo "unfinished "(subshell' 2>| string replace -r '.*' '<$0>'
|
||||
# CHECK: <fish: Unexpected end of string, expecting ')'>
|
||||
|
||||
Reference in New Issue
Block a user