Skip to content

$BASH_SUBSHELL inside $( ) reports 2 (GNU: 1) #403

Closed

Description

@caomengxuan666

Summary

$BASH_SUBSHELL inside a command substitution reports 2; GNU reports 1.

Reproducer (probe wt37-374 K009)

printf '%s:%s:%s\n' "$BASH_SUBSHELL" "$(echo $BASH_SUBSHELL)" "$BASH_SUBSHELL"

GNU: 0:1:0. rubash CLI: 0:2:0.

GNU owner

variables.c (BASH_SUBSHELL incremented once per comsub level in command_substitute).

Artifacts

target/issue-suites/results/wt37-374/run/K009.*

Activity

  1. added
    bug
    on Oct 2, 2026
  2. added 2 commits that reference this issue on Oct 2, 2026
  3. caomengxuan666 commented on Oct 3, 2026

    @caomengxuan666
    MemberAuthor

    Landed on master through the wt38 pool recovery waves (CI green on the batch head); see the issueNNN regression suite and the lane matrices on the ticket trail. Carrier-domain #399 landed with the full true-baseline A/B held byte-identical.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    bug

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions