test に 'e' コマンドと同じ効果として 'a' のエントリがありますが前段階の チェックで実際には機能しません。 これは有効にしたほうがいいのか、エントリを削除したほうがいいのか、どっ ちでしょうか。bash の builtin などにはあるようですが。 Index: file.c =================================================================== --- file.c (リビジョン 45822) +++ file.c (作業コピー) @@ -4527,6 +4527,7 @@ * File tests on a single file: * * Cmd Returns Meaning + * "a" | boolean | True if file1 exists * "A" | Time | Last access time for file1 * "b" | boolean | True if file1 is a block device * "c" | boolean | True if file1 is a character device @@ -4592,7 +4593,7 @@ rb_raise(rb_eArgError, "unknown command \"\\x%02X\"", cmd); } } - if (strchr("bcdefgGkloOprRsSuwWxXz", cmd)) { + if (strchr("bcdaefgGkloOprRsSuwWxXz", cmd)) { CHECK(1); switch (cmd) { case 'b': Index: test/ruby/test_file_exhaustive.rb =================================================================== --- test/ruby/test_file_exhaustive.rb (リビジョン 45822) +++ test/ruby/test_file_exhaustive.rb (作業コピー) @@ -942,6 +942,7 @@ assert_equal(File.blockdev?(f), test(?b, f)) assert_equal(File.chardev?(f), test(?c, f)) assert_equal(File.directory?(f), test(?d, f)) + assert_equal(File.exist?(f), test(?a, f)) assert_equal(File.exist?(f), test(?e, f)) assert_equal(File.file?(f), test(?f, f)) assert_equal(File.setgid?(f), test(?g, f))