diff options
author | Nobuyoshi Nakada <nobu@ruby-lang.org> | 2019-07-09 08:31:27 +0900 |
---|---|---|
committer | Hiroshi SHIBATA <hsbt@ruby-lang.org> | 2019-10-31 13:34:00 +0900 |
commit | e1f3bce7edc8e8335167dcf38dcedc7687d478c0 (patch) | |
tree | 3157631232fbcea28ac0bf76197d064fdb4e639e /ext | |
parent | c2978a97b714c2bfca6fb38cc5da13e70a09234f (diff) | |
download | json-e1f3bce7edc8e8335167dcf38dcedc7687d478c0.tar.gz |
Suppress uninitialized instance variable warnings
Diffstat (limited to 'ext')
-rw-r--r-- | ext/json/ext/generator/generator.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/ext/json/ext/generator/generator.c b/ext/json/ext/generator/generator.c index f481346..871f258 100644 --- a/ext/json/ext/generator/generator.c +++ b/ext/json/ext/generator/generator.c @@ -696,7 +696,7 @@ static VALUE cState_aref(VALUE self, VALUE name) if (RTEST(rb_funcall(self, i_respond_to_p, 1, name))) { return rb_funcall(self, i_send, 1, name); } else { - return rb_ivar_get(self, rb_intern_str(rb_str_concat(rb_str_new2("@"), name))); + return rb_attr_get(self, rb_intern_str(rb_str_concat(rb_str_new2("@"), name))); } } |