Debian Codegraph @

scheme/ikarus.date-string.ss

raw
1 ;;; Ikarus Scheme -- A compiler for R6RS Scheme.
2 ;;; Copyright (C) 2006,2007,2008 Abdulaziz Ghuloum
3 ;;;
4 ;;; This program is free software: you can redistribute it and/or modify
5 ;;; it under the terms of the GNU General Public License version 3 as
6 ;;; published by the Free Software Foundation.
7 ;;;
8 ;;; This program is distributed in the hope that it will be useful, but
9 ;;; WITHOUT ANY WARRANTY; without even the implied warranty of
10 ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
11 ;;; General Public License for more details.
12 ;;;
13 ;;; You should have received a copy of the GNU General Public License
14 ;;; along with this program. If not, see <http://www.gnu.org/licenses/>.
15
16
17 (library (ikarus date-string)
18 (export date-string)
19 (import
20 (rnrs bytevectors)
21 (except (ikarus) date-string))
22 (define date-string
23 (lambda ()
24 (let ([s (make-bytevector 10)])
25 (foreign-call "ikrt_bvftime" s
26 (string->utf8 "%F"))
27 (utf8->string s)))))