diff --git a/file.c b/file.c index de7ed5e33b..862f9630df 100644 --- a/file.c +++ b/file.c @@ -6504,12 +6504,10 @@ rb_find_file(VALUE path) return copy_path_class(tmp, path); } -static void -define_filetest_function(const char *name, VALUE (*func)(ANYARGS), int argc) -{ - rb_define_module_function(rb_mFileTest, name, func, argc); - rb_define_singleton_method(rb_cFile, name, func, argc); -} +#define define_filetest_function(name, func, argc) do { \ + rb_define_module_function(rb_mFileTest, name, func, argc); \ + rb_define_singleton_method(rb_cFile, name, func, argc); \ +} while(false) const char ruby_null_device[] = #if defined DOSISH