" Language: Factor
" Maintainer: Alex Chapman <chapman.alex@gmail.com>
" Last Change: ]=] write
- now >gmt { YYYY " " MONTH " " DD } formatted [=[
+ now-gmt { YYYY " " MONTH " " DD } formatted [=[
" Minimum Version: 600
" To regenerate: USE: editors.vim.generate-syntax generate-vim-syntax
: timestamp>windows-time ( timestamp -- n )
! 64bit number representing # of nanoseconds since Jan 1, 1601 (UTC)
- >gmt windows-1601 (time-) 10,000,000 * >integer ;
+ clone >gmt windows-1601 (time-) 10,000,000 * >integer ;
: windows-time>FILETIME ( n -- FILETIME )
[ FILETIME <struct> ] dip
[ 32 bits >>dwLowDateTime ] [ -32 shift >>dwHighDateTime ] bi ;
: timestamp>FILETIME ( timestamp -- FILETIME/f )
- dup [ >gmt timestamp>windows-time windows-time>FILETIME ] when ;
+ dup [ clone >gmt timestamp>windows-time windows-time>FILETIME ] when ;
: FILETIME>timestamp ( FILETIME -- timestamp/f )
FILETIME>windows-time windows-time>timestamp ;