From 617fbbba6ab6412702ab67ceec93d307132e8363 Mon Sep 17 00:00:00 2001 From: Alex Shinn Date: Tue, 15 Oct 2013 09:06:50 +0900 Subject: [PATCH] Export a make-tm constructor to generate time values. Patch from Barry Fishman. --- lib/chibi/time.sld | 2 +- lib/chibi/time.stub | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/lib/chibi/time.sld b/lib/chibi/time.sld index a053d5a2..7ee2ee3e 100644 --- a/lib/chibi/time.sld +++ b/lib/chibi/time.sld @@ -2,7 +2,7 @@ (define-library (chibi time) (export current-seconds get-time-of-day set-time-of-day! seconds->time seconds->string time->seconds time->string - make-timeval timeval-seconds timeval-microseconds + make-timeval make-tm timeval-seconds timeval-microseconds timezone-offset timezone-dst-time time-second time-minute time-hour time-day time-month time-year time-day-of-week time-day-of-year time-dst? diff --git a/lib/chibi/time.stub b/lib/chibi/time.stub index 64cb68fd..f53e182b 100644 --- a/lib/chibi/time.stub +++ b/lib/chibi/time.stub @@ -7,6 +7,8 @@ (define-c-struct tm predicate: tm? + constructor: (make-tm tm_sec tm_min tm_hour + tm_mday tm_mon tm_year tm_isdst) (int tm_sec time-second) (int tm_min time-minute) (int tm_hour time-hour)