mirror of
https://github.com/mruby/mruby
synced 2026-06-08 16:11:16 +00:00
Handle Array#[float, int] Close #2626
This commit is contained in:
@@ -658,6 +658,9 @@ aget_index(mrb_state *mrb, mrb_value index)
|
||||
if (mrb_fixnum_p(index)) {
|
||||
return mrb_fixnum(index);
|
||||
}
|
||||
else if (mrb_float_p(index)) {
|
||||
return mrb_float(index);
|
||||
}
|
||||
else {
|
||||
mrb_int i;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user