2 USING: kernel alien.syntax alien.c-types math ;
9 { "int" "sec" } ! Seconds: 0-59 (K&R says 0-61?)
10 { "int" "min" } ! Minutes: 0-59
11 { "int" "hour" } ! Hours since midnight: 0-23
12 { "int" "mday" } ! Day of the month: 1-31
13 { "int" "mon" } ! Months *since* january: 0-11
14 { "int" "year" } ! Years since 1900
15 { "int" "wday" } ! Days since Sunday (0-6)
16 { "int" "yday" } ! Days since Jan. 1: 0-365
17 { "int" "isdst" } ! +1 Daylight Savings Time, 0 No DST,
18 { "long" "gmtoff" } ! Seconds: 0-59 (K&R says 0-61?)
25 : make-timespec ( ms -- timespec )
28 [ set-timespec-nsec ] keep
29 [ set-timespec-sec ] keep ;
31 FUNCTION: time_t time ( time_t* t ) ;
32 FUNCTION: tm* localtime ( time_t* clock ) ;
33 FUNCTION: int gettimeofday ( timespec* TP, void* TZP ) ;