/* * call-seq: * Integer(arg) => integer * * Converts <i>arg</i> to a <code>Fixnum</code> or <code>Bignum</code>. * Numeric types are converted directly (with floating point numbers * being truncated). If <i>arg</i> is a <code>String</code>, leading * radix indicators (<code>0</code>, <code>0b</code>, and * <code>0x</code>) are honored. Others are converted using * <code>to_int</code> and <code>to_i</code>. This behavior is * different from that of <code>String#to_i</code>. * * Integer(123.999) #=> 123 * Integer("0x1a") #=> 26 * Integer(Time.new) #=> 1049896590 */ static VALUE rb_f_integer(obj, arg) VALUE obj, arg; { return rb_Integer(arg); }