summaryrefslogtreecommitdiff
path: root/file.c
diff options
context:
space:
mode:
authornobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2013-03-14 07:59:16 +0000
committernobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2013-03-14 07:59:16 +0000
commit844c04f462e0677c2723789325366f233cbd0a01 (patch)
treeee417d24bb41f269d3b43cdf82d32ba8bf4e59b5 /file.c
parentfb34a2600326f6ba3ba116c35d1395e90d10fd00 (diff)
configure.in, file.c: RUBY_FUNCTION_NAME_STRING
* configure.in (rb_cv_function_name_string): macro for function name string predefined identifier, __func__ in C99, or __FUNCTION__ in gcc. * file.c (rb_sys_fail_path): use RUBY_FUNCTION_NAME_STRING. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@39754 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'file.c')
-rw-r--r--file.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/file.c b/file.c
index 14636d34c9..20673cbbb8 100644
--- a/file.c
+++ b/file.c
@@ -102,8 +102,8 @@ int flock(int, int);
#define STAT(p, s) stat((p), (s))
#endif
-#ifdef __GNUC__
-# define rb_sys_fail_path(path) rb_sys_fail_path0(__func__, path)
+#ifdef RUBY_FUNCTION_NAME_STRING
+# define rb_sys_fail_path(path) rb_sys_fail_path0(RUBY_FUNCTION_NAME_STRING, path)
NORETURN(static void rb_sys_fail_path0(const char *,VALUE));
static void
rb_sys_fail_path0(const char *func_name, VALUE path)