time for Nim
the only difference with Python's is where some types in time is str, there is string in n_time's.
e.g. n_time.ctime() returns a string
py diff
Currently, tm_name is either "LOCAL" or "Etc/UTC", due to std/times only returning those two.
Consts
DefaultTimeFormat = "%a %b %d %H:%M:%S %Y"
- Source Edit
Procs
func asctime(t: struct_time): string {....raises: [], tags: [], forbids: [].}
- Source Edit
func asctime(tup: struct_time_tuple): typeof(asctime do: bind struct_time struct_time(tm_year: 1900, tm_mon: 1, tm_mday: 1, tm_yday: 1, tm_isdst: -1)) {. ...raises: [], tags: [], forbids: [].}
- Source Edit
func asctime(tup: struct_time_tuple10): typeof(asctime do: bind struct_time struct_time(tm_year: 1900, tm_mon: 1, tm_mday: 1, tm_yday: 1, tm_isdst: -1)) {. ...raises: [], tags: [], forbids: [].}
- Source Edit
func asctime(tup: struct_time_tuple11): typeof(asctime do: bind struct_time struct_time(tm_year: 1900, tm_mon: 1, tm_mday: 1, tm_yday: 1, tm_isdst: -1)) {. ...raises: [], tags: [], forbids: [].}
- Source Edit
proc strptime(s: string): struct_time {....raises: [ValueError, TimeParseError, TimeFormatParseError], tags: [TimeEffect], forbids: [].}
- Source Edit
Exports
-
fetchDoc, fetchDoc, docTable, sleep, time, time_ns, perf_counter, monotonic_ns, perf_counter_ns, process_time, monotonic, <=, struct_time, <=, <, <, ==, <=, struct_time_tuple10, ==, repr, Some_struct_time, <=, ==, Some_struct_time_tuple, <, struct_time_tuple11, <=, ==, ==, <, <, struct_time_tuple, toTuple, localtime, mktime, mktime, localtime, gmtime, gmtime, gmtime, localtime, fetchDoc, strptime, strftime, strftime, docTable, fetchDoc, strftime