Esc

date_time_from_calendar

procedureextensionsince 0.36.1Source
  • macOS: date_time_from_calendar works on macOS
  • Linux: date_time_from_calendar works on Linux
  • Windows: date_time_from_calendar works on Windows
  • Wasm: date_time_from_calendar works on Wasm

Validates Basic's zero-based components; ignores zone and derived weekday metadata.

Signature

date_time_from_calendar :: (
    value: Basic.Calendar_Time
) -> (Date_Time, Time_Error)
Example↗
calendar, _ := date_time_to_calendar(.{ .{ 2024, 2, 29 }, .{ 12, 30, 0, 0 } });
wall, error := date_time_from_calendar(calendar);
assert(error.kind == .NONE && wall.date.day == 29 && wall.time.hour == 12);

See also