From 1da55b38fab0e55201cb1d97672caac92f4cd3a7 Mon Sep 17 00:00:00 2001 From: nobu Date: Tue, 18 Nov 2008 17:39:33 +0000 Subject: [PATCH] * error.c (Init_syserr): moved function definition itself from template/known_errors.inc.tmpl. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@20275 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- ChangeLog | 5 +++++ error.c | 4 ++++ template/known_errors.inc.tmpl | 3 --- 3 files changed, 9 insertions(+), 3 deletions(-) diff --git a/ChangeLog b/ChangeLog index 0dc77ee653..04b2ba30e9 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +Wed Nov 19 02:39:31 2008 Nobuyoshi Nakada + + * error.c (Init_syserr): moved function definition itself from + template/known_errors.inc.tmpl. + Wed Nov 19 01:10:52 2008 Masatoshi SEKI * lib/drb/drb.rb (DRbConn::alive?): fixed NoMethodError problem diff --git a/error.c b/error.c index 3248335b96..c28a855ea7 100644 --- a/error.c +++ b/error.c @@ -1157,7 +1157,11 @@ rb_check_frozen(VALUE obj) if (OBJ_FROZEN(obj)) rb_error_frozen(rb_obj_classname(obj)); } +void Init_syserr(void) +{ + rb_eNOERROR = set_syserr(0, "NOERROR"); #include "known_errors.inc" +} static void err_append(const char *s) diff --git a/template/known_errors.inc.tmpl b/template/known_errors.inc.tmpl index 2a569bda12..23bca21362 100644 --- a/template/known_errors.inc.tmpl +++ b/template/known_errors.inc.tmpl @@ -5,8 +5,6 @@ */ % error_names = ARGF.read.split(/\s+/) -void Init_syserr(void) { - rb_eNOERROR = set_syserr(0, "NOERROR"); % error_names.each do |name| #ifdef <%=name%> set_syserr(<%=name%>, "<%=name%>"); @@ -14,4 +12,3 @@ void Init_syserr(void) { set_syserr(0, "<%=name%>"); #endif % end -}