End of Life Ruby 3.2 has reached end of life and gets no more fixes. Switch to Ruby 4.0 →
class method
Time.mktime
mktime(*args)
time.c
View on GitHub ↗
static VALUE
time_s_mktime(int argc, VALUE *argv, VALUE klass)
{
struct vtm vtm;
time_arg(argc, argv, &vtm);
return time_localtime(time_new_timew(klass, timelocalw(&vtm)));
}
Alias of .local
Like Time.utc, except that the returned Time object has the local timezone, not the UTC timezone:
Example
# With seven arguments. Time.local(0, 1, 2, 3, 4, 5, 6) # => 0000-01-02 03:04:05.000006 -0600 # With exactly ten arguments. Time.local(0, 1, 2, 3, 4, 5, 6, 7, 8, 9) # => 0005-04-03 02:01:00 -0600