Eric Sunshine <sunshine@xxxxxxxxxxxxxx> writes: > I had the same concern that it didn't necessarily make sense to allow > "-" for $2, but eventually thought of a case such as: > > sed '...' actual | test_cmp expect - && > > which massages 'actual' before test_cmp() sees it. True, we don't > actually have such callers, but it theoretically is legitimate. Yup, that looks a bit too stretching [*] to me, but that was what I had in mind when I said "I'll let it pass". Side note. Presumably that 'actual' was written by Git, to avoid losing its exit code, e.g. git frotz >actual && sed '...' actual | test_cmp expect - but then it becomes more natural to write the second one like so: git frotz >raw && sed '...' raw >actual && test_cmp expect actual