summaryrefslogtreecommitdiffstats
path: root/eval_method.ci
diff options
context:
space:
mode:
authornobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2007-09-26 06:01:43 +0000
committernobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2007-09-26 06:01:43 +0000
commit3cc595484341c7510fbca8e0e01315727714492f (patch)
tree1612b7708be4248e1ee1eb01178367f7836c88e4 /eval_method.ci
parentfa51dfb0cefeffd6ee0db4b63d276248e7c38897 (diff)
downloadruby-3cc595484341c7510fbca8e0e01315727714492f.tar.gz
ruby-3cc595484341c7510fbca8e0e01315727714492f.tar.xz
ruby-3cc595484341c7510fbca8e0e01315727714492f.zip
* eval_method.ci (rb_get_alloc_func): cast to suppress a warning.
* eval_method.ci (remove_method): local variable to be initialized. git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@13517 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'eval_method.ci')
-rw-r--r--eval_method.ci4
1 files changed, 2 insertions, 2 deletions
diff --git a/eval_method.ci b/eval_method.ci
index 5dfcdfacb..61ff38f53 100644
--- a/eval_method.ci
+++ b/eval_method.ci
@@ -204,7 +204,7 @@ rb_get_alloc_func(VALUE klass)
if (nd_type(n) != NODE_METHOD) return 0;
n = n->nd_body;
if (nd_type(n) != NODE_CFUNC) return 0;
- return n->nd_cfnc;
+ return (rb_alloc_func_t)n->nd_cfnc;
}
static NODE *
@@ -292,7 +292,7 @@ static void
remove_method(VALUE klass, ID mid)
{
st_data_t data;
- NODE *body;
+ NODE *body = 0;
if (klass == rb_cObject) {
rb_secure(4);