This REPLACES the patch in workers/52831 for changing ${|var|cmd} to ${{var} cmd}. Besides generally that, it implements the following (also mentioning changes vs 52831): Clarify or expand comments, use more meaningful variable names. Refactor to avoid scanning "{var} cmd" three times to separate "var" from "cmd". Require space after {var} to limit vulnerability to ${{var}} vs ${${var}} typos. Lift tokenize() block to avoid code duplication. Signal handling paranoia. Update tests and add additional special case tests. Now only ${|cmd} has magic local $REPLY, rather than all 3 forms. Some details about the latter: I've stepped onto the slippery slope of having a ".zsh" namespace for internal parameters. ${{var} cmd} doesn't use a local at all now, and ${|cmd} creates a local $REPLY as before, but ${ cmd } creates a local readonly ${.zsh.cmdsubst}. Making it readonly (and unset) prevents user code in cmd from attempting to use that name nefariously. After executing the cmd, the readonly state is cleared and the output is assigned to it. Then later when we're ready to substitute the value and apply any state passed down from ${(flags)${|cmd}} etc., each of {var} or REPLY or .zsh.cmdsubst can be referenced the same way. There's probably some optimization to be had, i.e., avoid assignment only to fetch the value back immediately, but the two forms where user code assigns to a parameter are required to work that way, so it's no worse to have the stdout branch do the same under the hood. RE the "edge cases" in the other thread: ${{var}} is a bad substitution because of the required space, noted above. ${{var} }, ${{var};}, ${{} }, etc., substitute the empty string rather than erroring. ${{REPLY[2]} REPLY=abc} now substitutes "b" because REPLY is not implicitly local. This does not yet update the Doc, nor do anything about the "break" situation.