- functions: name() { ...; }, function name { ...; }, return, local,
unset -f; in pipes, & and $(...) they run in a subshell that gets all
function definitions and the positional parameters
- positional parameters $0, $1 ... ${10}, $#, "$@", "$*", $$; set by
gosh script args, gosh -c command name args, function calls,
source file args and set --; shift; for x without "in"
- case word in pattern|pattern) ...;; esac and { list; } groups
- read [-r] [-p prompt] [name ...] with $IFS splitting and $REPLY
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
- $(command) is replaced by the output of command, which runs in a
subshell (gosh -c), so cd/set in it do not change the shell
- trailing newlines are removed; unquoted the output is split into words
at blanks and newlines, "$(...)" stays one word; wildcards in the
output are not expanded
- nested substitutions, quotes and operators inside are handled; the
list, alias and brace scanners skip $(...) as a whole
- a command that consists only of a substitution has its exit status,
Ctrl+C in a substitution aborts the command
- $((...)) is reported as not supported
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>