From ef0b239704c2552f19f4e23d6c206884650a77ac Mon Sep 17 00:00:00 2001 From: "Yukihiro \"Matz\" Matsumoto" Date: Fri, 11 Aug 2017 12:57:37 +0900 Subject: Remove unnecessary inline function `ary_elt`. And the function does not conform the naming convention anyway. --- include/mruby/array.h | 9 --------- 1 file changed, 9 deletions(-) (limited to 'include') diff --git a/include/mruby/array.h b/include/mruby/array.h index a0c642a80..946897a22 100644 --- a/include/mruby/array.h +++ b/include/mruby/array.h @@ -276,15 +276,6 @@ MRB_API mrb_value mrb_ary_join(mrb_state *mrb, mrb_value ary, mrb_value sep); */ MRB_API mrb_value mrb_ary_resize(mrb_state *mrb, mrb_value ary, mrb_int new_len); -static inline mrb_value -ary_elt(mrb_value ary, mrb_int offset) -{ - if (offset < 0 || RARRAY_LEN(ary) <= offset) { - return mrb_nil_value(); - } - return RARRAY_PTR(ary)[offset]; -} - MRB_END_DECL #endif /* MRUBY_ARRAY_H */ -- cgit v1.2.3