0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 5 years have passed since last update.

ls > sourceCode > sortfcn = revnamecmp ...

Last updated at Posted at 2015-07-16

引用: プログラミングテクニック UNIXコマンドのソースコードにみる実践プログラミング手法 by 多治見寿和さん

/* 並べ替え用の関数を選択 */
if (f_reversesort) {
    if (!f_timesort)
        sortfcn = revnamecmp;
    else if (f_accesstime)
        sortfcn = revacccmp;
    else if (f_statustime)
        sortfcn = revstatcmp;
    else /* 修正時刻を利用 */
        sortfcn = revmodcmp;
} else {
    if (!f_timesort)
        sortfcn = namecmp;
    else if (f_accesstime)
        sortfcn = acccmp;
    else if (f_statustime)
        sortfcn = statcmp;
    else /* 修正時刻を利用 */
        sortfcn = modcmp;
}    

sortfcnの「fcn」が何の略なのかわからない。 function?

0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?