Skip to content

[[ ]] comparison operands do not materialize process-substitution spans (== / =~ can answer opposite to GNU) #1932

Closed

Description

@caomengxuan666

分歧(master 既存,#1915 t7 接续簇探针 u4/u6/u8 发现)

条件操作数展开不做 procsub 跨度抽取/物化,比较时用的是去引号后的跨度原文,不是 /dev/fd 路径。后果:

  • 跨度作 ==/=~ 主体时判定可与 GNU 相反(探针 u4/u6:GNU yes、rubash no,两边脚本 rc 均 0——静默错答,比报错更坏);
  • <(awk "$1" …) 的子侧诊断在 [[ ]] 路径不复现(u8 缺一行 stderr,其余全同)。

简单命令面此事是对的(同批 d2 探针逐字节同 GNU);缺口只在 conditional 展开/物化路径。属展开本体,与 #1929 的 nounset 维度(已修)是不同机制。证据:~/workspace/clear-1915-procsub/REPORT.md §7.4 + probes/u4.sh、u6.sh、u8.sh。

归宿

conditional 面后续批;非 #1915 验收面、不阻断 1.5.0,但「静默错答」性质要求后续批必收。

Regression seed: probes/u4.sh(期望 GNU 的 yes/no 与 rc 逐字节)。

Activity

  1. added
    bug
    gnu-baseline
    P2-medium
    area:expansion
    on Oct 28, 2026
  2. added a commit that references this issue on Oct 29, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Labels

P2-mediumarea:expansionbuggnu-baseline

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions