(rontolisp) docs
← Functions

encode-universal-time

(encode-universal-time second minute hour date month year &optional time-zone)

Returns the universal time -- seconds since the Common Lisp epoch of 1900-01-01 00:00:00 GMT -- denoted by the decoded components. time-zone is the offset west of GMT in hours; a missing (or nil) zone means GMT, not the machine's local zone, because no backend-portable local-zone source exists (the WASM targets expose no timezone at all). The calendar arithmetic is exact for any year: it runs the era-based proleptic-Gregorian algorithm over integers, so every backend answers identically.

The inverse is decode-universal-time, and get-universal-time reads the clock in the same units.