Commit e6ab9237 authored by skandhas's avatar skandhas

rename method

parent 59d33146
...@@ -23,7 +23,7 @@ ...@@ -23,7 +23,7 @@
*/ */
static mrb_value static mrb_value
mrb_ary_try_convert(mrb_state *mrb, mrb_value self) mrb_ary_s_try_convert(mrb_state *mrb, mrb_value self)
{ {
mrb_value ary; mrb_value ary;
...@@ -127,7 +127,7 @@ mrb_mruby_array_ext_gem_init(mrb_state* mrb) ...@@ -127,7 +127,7 @@ mrb_mruby_array_ext_gem_init(mrb_state* mrb)
{ {
struct RClass * a = mrb->array_class; struct RClass * a = mrb->array_class;
mrb_define_class_method(mrb, a, "try_convert", mrb_ary_try_convert, ARGS_REQ(1)); mrb_define_class_method(mrb, a, "try_convert", mrb_ary_s_try_convert, ARGS_REQ(1));
mrb_define_method(mrb, a, "assoc", mrb_ary_assoc, ARGS_REQ(1)); mrb_define_method(mrb, a, "assoc", mrb_ary_assoc, ARGS_REQ(1));
mrb_define_method(mrb, a, "at", mrb_ary_at, ARGS_REQ(1)); mrb_define_method(mrb, a, "at", mrb_ary_at, ARGS_REQ(1));
......
...@@ -21,7 +21,7 @@ assert("Array#at") do ...@@ -21,7 +21,7 @@ assert("Array#at") do
a.at(0) == "a" and a.at(-1) == "e" a.at(0) == "a" and a.at(-1) == "e"
end end
assert("Array::rassoc") do assert("Array#rassoc") do
a = [ [ 1, "one"], [2, "two"], [3, "three"], ["ii", "two"] ] a = [ [ 1, "one"], [2, "two"], [3, "three"], ["ii", "two"] ]
a.rassoc("two") == [2, "two"] and a.rassoc("two") == [2, "two"] and
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment