私はこれを見ています。パイプで混乱します。 'cat -A'は出力の一部を除外しているようです。
cat test.hs |./TonHospel
25 x 25 matrix, 8 threads
permanent=-5258461839360 (0.213000 s)
[email protected]:~/python$ cat test.hs |./TonHospel |cat -A
25 x 25 matrix, 8 threads$
何らかの理由でcat -A
が出力の一部を除外しています。私はそれが何とかstderrとstdoutに関連するかもしれないと推測したので、私はstdoutに両方のパイプを試みました。これは役に立たなかった。
[email protected]:~/python$ cat test.hs |./TonHospel 2>&1 |cat -A
25 x 25 matrix, 8 threads$
最後にランダムに試しました。
[email protected]:~/python$ cat test.hs |./TonHospel 3>&1 1>&2 2>&3 |cat -A
25 x 25 matrix, 8 threads
permanent=-5258461839360 (0.236000 s)
何が起こっているのですか? C++のソースコードはhttps://bpaste.net/show/ce5ca8643ba5です。
プログラムに応じてその出力を変更することができますstdoutが端末であるかどうか。 –
'TonHospel'ではどうなりますか?それはリダイレクトされますか? –
これはC++です。私はソースはhttps://bpaste.net/show/ce5ca8643ba5です。私はそれが何か変わったとは思わない? – eleanora