From 4684239efa63dc1b2c1cbe37ef7d3062029f5532 Mon Sep 17 00:00:00 2001 From: Bryan Newbold Date: Mon, 20 Feb 2017 00:05:40 -0800 Subject: Import Upstream version 3b1 --- chez.init | 28 +++++++++++++++++----------- 1 file changed, 17 insertions(+), 11 deletions(-) (limited to 'chez.init') diff --git a/chez.init b/chez.init index 5047f96..dd923f9 100644 --- a/chez.init +++ b/chez.init @@ -28,7 +28,10 @@ ;;; the directory where any auxillary files to your Scheme ;;; implementation reside. (define implementation-vicinity - (lambda () "/usr/unsup/scheme/chez/")) + (let ((impl-path + (or (getenv "CHEZ_IMPLEMENTATION_PATH") + "/usr/unsup/scheme/chez/"))) + (lambda () impl-path))) ;;; (library-vicinity) should be defined to be the pathname of the ;;; directory where files of Scheme library functions reside. @@ -95,8 +98,7 @@ ;@ (define sub-vicinity (case (software-type) - ((vms) (lambda - (vic name) + ((vms) (lambda (vic name) (let ((l (string-length vic))) (if (or (zero? (string-length vic)) (not (char=? #\] (string-ref vic (- l 1))))) @@ -137,6 +139,7 @@ ;(SLIB:LOAD-COMPILED "filename") vicinity srfi-59 + srfi-96 ;; Scheme report features ;; R5RS-compliant implementations should provide all 9 features. @@ -180,11 +183,11 @@ ;; Other common features -;;; srfi ;srfi-0, COND-EXPAND finds all srfi-* +;;; srfi-0 ;srfi-0, COND-EXPAND finds all srfi-* ;;; sicp ;runs code from Structure and ;Interpretation of Computer ;Programs by Abelson and Sussman. -;;; defmacro ;has Common Lisp DEFMACRO + defmacro ;has Common Lisp DEFMACRO record ;has user defined data structures string-port ;has CALL-WITH-INPUT-STRING and ;CALL-WITH-OUTPUT-STRING @@ -374,6 +377,15 @@ ;;; At this point SLIB:LOAD must be able to load SLIB files. (define slib:load slib:load-source) +;;; If your implementation provides R4RS macros: +(define macro:eval slib:eval) +;;; macro:load also needs the default suffix. +(define macro:load slib:load-source) + +;;; If your implementation provides syntax-case macros: +;;(define syncase:eval slib:eval) +;;(define syncase:load slib:load-source) + ;;; The following make procedures in Chez Scheme compatible with ;;; the assumptions of SLIB. @@ -431,11 +443,6 @@ (close-input-port insp) res))) -;;; If your implementation provides R4RS macros: -(define macro:eval slib:eval) -;;; macro:load also needs the default suffix. -(define macro:load slib:load-source) - (define *defmacros* (list (cons 'defmacro (lambda (name parms . body) @@ -468,7 +475,6 @@ (require 'defmacroexpand) (apply defmacro:expand* x '())) (define (defmacro:load ) (slib:eval-load defmacro:eval)) -;; slib:eval-load definition moved to "require.scm" (define slib:warn (lambda args -- cgit v1.2.3