Commit c56d2dab authored by Erick Gallesio's avatar Erick Gallesio

Thread safety (in C) preparation. Almost complete

parent f1acacc1
2006-09-12 Erick Gallesio <eg@essi.fr>
* src/port.c: Added READ-BYTE and WRITE-BYTE
2006-09-08 Erick Gallesio <eg@essi.fr>
* lib/bonus.stk: Added primitives PRINTF, EPRINTF, FPRINTF
2006-09-05 Erick Gallesio <eg@essi.fr>
* lib/boot.stk ("base64"): Added base64 functions
* lib/bonus.stk (make-path): Accept now multiple file to build a
complete hierarchy
2006-09-04 Erick Gallesio <eg@essi.fr>
* lib/r5rs.stk (%make-with-file): The file name in error messages
was incorrect.
* src/process.c: PROCESS-EXIT-STATUS was not exported.
2006-08-04 Erick Gallesio <eg@essi.fr>
* src/lib.c: Deletedthe managemement of the STk_library_path
variable which was not used anymore
2006-06-20 Erick Gallesio <eg@essi.fr>
* src/system.c: file-size, file-exists? and a bunch of other
functions didn't use the ~ expansion.
* lib/repl.stk: Added the MAIN-REPL-HOOK parameter.
2006-06-16 Erick Gallesio <eg@essi.fr>
* lib/repl.stk (repl-display-prompt): A new parameter which permit
to get/change the repl display function.
2006-05-29 Erick Gallesio <eg@essi.fr>
* lib/bonus.stk (parameterize): Bug fix when using parallel
assignments
2006-05-26 Erick Gallesio <eg@essi.fr>
* src/socket.c (set_socket_io_ports): Going back and added back
the dup on socket creation.
2006-04-26 Erick Gallesio <eg@essi.fr>
* src/thread-pthreads.c (thread-terminate!): Fixed a deadlock problem.
......
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
......@@ -18,7 +18,7 @@
;; USA.
;; Author: Erick Gallesio [eg@unice.fr]
;; Creation date: 26-Nov-2000 18:19 (eg)
;; Last file update: 3-Feb-2006 17:54 (eg)
;; Last file update: 12-Sep-2006 15:27 (eg)
;;
;; ======================================================================
......@@ -473,7 +473,9 @@ be accessed as a normal port with the standard Scheme primitives.])
(insertdoc 'read-char)
(insertdoc 'read-chars)
(insertdoc 'read-chars!)
(insertdoc 'read-byte)
(insertdoc 'peek-char)
(insertdoc 'peek-byte)
(insertdoc 'eof-object?)
(insertdoc 'eof-object)
(insertdoc 'char-ready?)
......@@ -490,6 +492,7 @@ be accessed as a normal port with the standard Scheme primitives.])
(insertdoc 'newline)
(insertdoc 'write-char)
(insertdoc 'write-chars)
(insertdoc 'write-byte)
(index "SRFI-28")
(insertdoc 'format)
(insertdoc 'flush-output-port)
......@@ -764,5 +767,9 @@ See SRFI document for more information.])
(insertdoc 'pp)
(insertdoc 'uri-parse)
(insertdoc 'string->html))
(insertdoc 'base64-encode)
(insertdoc 'base64-decode)
(insertdoc 'base64-encode-string)
(insertdoc 'base64-decode-string)
)
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
......@@ -2,7 +2,7 @@
#
# Author: Erick Gallesio [eg@unice.fr]
# Creation date: 11-Apr-2000 10:30 (eg)
# Last file update: 16-Apr-2006 11:47 (eg)
# Last file update: 11-Sep-2006 17:24 (eg)
SUBDIRS = Match.d SILex.d Lalr.d @LURCDIR@
......@@ -144,7 +144,7 @@ boot: ../src/boot.img
doc: $(DOCDB)
$(DOCDB): $(scheme_SRCS) $(scheme_BOOT)
../src/stklos -c -b ../src/boot.img -f ../doc/extract-doc \
../src/stklos -q -c -b ../src/boot.img -f ../doc/extract-doc \
$(scheme_SRCS) $(scheme_BOOT) > $(DOCDB)
clean:
......
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
......@@ -21,7 +21,7 @@
;;;;
;;;; Author: Erick Gallesio [eg@unice.fr]
;;;; Creation date: 14-Jun-2000 17:24 (eg)
;;;; Last file update: 6-Apr-2006 17:54 (eg)
;;;; Last file update: 11-Sep-2006 17:23 (eg)
;;;;
;;
......@@ -814,6 +814,36 @@ doc>
(proc (lambda l (raise (cons tag l)))))))
;; ======================================================================
;; base64 ...
;; ======================================================================
#|
<doc EXT base64-encode-string
* (base64-encode-string str)
*
* Return a string contening the contents of |str| converted to Base64
* encoded format
doc>
<doc EXT base64-decode-string
* (base64-encode-string str)
*
* Decode the contents of |str| expressed in Base64.
doc>
|#
(define base64-encode-string #f)
(define base64-decode-string #f)
(let ((encode/decode (lambda (op)
(lambda (str)
(let ((in (open-input-string str))
(out (open-output-string)))
(op in out)
(get-output-string out))))))
(set! base64-encode-string (encode/decode base64-encode))
(set! base64-decode-string (encode/decode base64-decode)))
;; ======================================================================
;; ansi-color ...
;; ======================================================================
......@@ -927,6 +957,30 @@ doc>
(for-each (lambda (x) (display x p)) l)
(newline p)))
#|
<doc EXT printf fprintf eprintf
* (printf fmt obj ...)
* (fprintf port fmt obj ...)
* (eprintf fmt obj ...)
*
* These procedures are specialized version of |,(ref :mark "format")|.
* In these procedures, |fmt| is a string using the |format| conventions.
* |printf| outputs go on the current output port.
* |eprintf| outputs go on the current error port.
* |fprintf| outputs go on the specified |port|.
doc>
|#
(define (eprintf fmt . args)
(apply format (current-error-port) fmt args))
(define (printf fmt . args)
(apply format #t fmt args))
(define (fprintf port fmt . args)
(apply format port fmt args))
#|
<doc EXT exec exec-list
* (exec str)
......@@ -1099,15 +1153,21 @@ doc>
#|
<doc EXT make-path
* (make-path dirname name)
*
* Builds a file name from the directory |dirname| and |name|.
* (make-path dirname . names)
*
* Builds a file name from the directory |dirname| and |names|. For instance,
* on a Unix system:
* @lisp
* (make-path "a" "b" "c") => "a/b/c"
* @lisp
doc>
|#
(define (make-path dirname name)
(format "~A~A~A" dirname (file-separator) name))
(define (make-path dirname . names)
(if (null? names)
dirname
(apply make-path
(format "~A~A~A" dirname (file-separator) (car names))
(cdr names))))
#|
<doc EXT port-idle-register! port-idle-unregister! port-idle-reset!
......@@ -1391,16 +1451,22 @@ doc>
doc>
|#
(define-macro (parameterize bindings . body)
(if (null? bindings)
`(begin ,@body)
`(dynamic-wind
(let ((tmp (map (lambda (_) (gensym)) bindings)))
`(let ,(map (lambda (x y) (list y (cadr x)))
bindings tmp)
(dynamic-wind
(lambda ()
(%parameter-dynenv-push! ,(caar bindings))
,(car bindings))
;; First push all the current parameter values
,@(map (lambda (x) `(%parameter-dynenv-push! ,(car x)))
bindings)
;; Change all parameters values
,@(map (lambda (x y) `(,(car x) ,y))
bindings tmp))
(lambda ()
(parameterize ,(cdr bindings) ,@body))
,@body)
(lambda ()
(%parameter-dynenv-pop! ,(caar bindings))))))
,@(map (lambda (x) `(%parameter-dynenv-pop! ,(car x)))
bindings))))))
;;
;; SRFI-55: "require-extension"
......
......@@ -897,7 +897,7 @@ doc>
(unless port
(raise (make-condition &i/o-filename-error
'location name
'message (format "cannot open file ~S" name)
'message (format "cannot open file ~S" string)
'backtrace (%vm-backtrace)
'filename string)))
(dynamic-wind
......
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
......@@ -93,7 +93,7 @@
/* Define to the version of this package. */
#undef PACKAGE_VERSION
/* The size of a `long', as computed by sizeof. */
/* The size of `long', as computed by sizeof. */
#undef SIZEOF_LONG
/* Define to 1 if you have the ANSI C header files. */
......
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment