/* * call-seq: * time.mon => fixnum * time.month => fixnum * * Returns the month of the year (1..12) for <i>time</i>. * * t = Time.now #=> Wed Apr 09 08:56:03 CDT 2003 * t.mon #=> 4 * t.month #=> 4 */ static VALUE time_mon(time) VALUE time; { struct time_object *tobj; GetTimeval(time, tobj); if (tobj->tm_got == 0) { time_get_tm(time, tobj->gmt); } return INT2FIX(tobj->tm.tm_mon+1); }