Ruby Newbie homepage Ruby Newbie homepage

How to use

Quick guide

Official content
If object is an Array object, returns object.
Otherwise if object responds to :to_ary, calls object.to_ary and returns the result.
Returns nil if object does not respond to :to_ary
Raises an exception unless object.to_ary returns an Array object.
               static VALUE
rb_ary_s_try_convert(VALUE dummy, VALUE ary)
    return rb_check_array_type(ary);

Was this page useful?