From 1cbebd9c51977dc26b228fb88dbea05950eea09b Mon Sep 17 00:00:00 2001 From: matz Date: Fri, 16 Jan 1998 12:36:14 +0000 Subject: *** empty log message *** git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/v1_1r@15 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- variable.c | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'variable.c') diff --git a/variable.c b/variable.c index 0115b87d68..afc4ea96b6 100644 --- a/variable.c +++ b/variable.c @@ -702,6 +702,7 @@ rb_ivar_get(obj, id) case T_OBJECT: case T_CLASS: case T_MODULE: + case T_FILE: if (ROBJECT(obj)->iv_tbl && st_lookup(ROBJECT(obj)->iv_tbl, id, &val)) return val; return Qnil; @@ -728,6 +729,7 @@ rb_ivar_set(obj, id, val) case T_OBJECT: case T_CLASS: case T_MODULE: + case T_FILE: if (!ROBJECT(obj)->iv_tbl) ROBJECT(obj)->iv_tbl = new_idhash(); st_insert(ROBJECT(obj)->iv_tbl, id, val); break; @@ -750,6 +752,7 @@ rb_ivar_defined(obj, id) case T_OBJECT: case T_CLASS: case T_MODULE: + case T_FILE: if (ROBJECT(obj)->iv_tbl && st_lookup(ROBJECT(obj)->iv_tbl, id, 0)) return TRUE; break; @@ -779,6 +782,7 @@ obj_instance_variables(obj) case T_OBJECT: case T_CLASS: case T_MODULE: + case T_FILE: if (ROBJECT(obj)->iv_tbl) { st_foreach(ROBJECT(obj)->iv_tbl, ivar_i, hash); } @@ -804,6 +808,7 @@ obj_remove_instance_variable(obj, name) case T_OBJECT: case T_CLASS: case T_MODULE: + case T_FILE: if (ROBJECT(obj)->iv_tbl) { st_delete(ROBJECT(obj)->iv_tbl, &id, &val); } -- cgit v1.2.3