diff options
author | Andy Wingo <wingo@pobox.com> | 2020-01-12 20:14:30 +0100 |
---|---|---|
committer | Andy Wingo <wingo@pobox.com> | 2020-01-12 20:31:47 +0100 |
commit | fd2ffc649c2d08639c2ac41c25e4ebdbeb4b151d (patch) | |
tree | 6597b90a6cdc77d949608b379c9a9c493e3daf69 /module/scheme | |
parent | 639d0b37687d0cc66202b1d6e60286c843fb3ffd (diff) | |
download | guile-fd2ffc649c2d08639c2ac41c25e4ebdbeb4b151d.tar.gz |
Support R7RS define-library
* module/Makefile.am (ice-9/boot-9.go, NOCOMP_SOURCES): Add
r7rs-libraries.
* module/ice-9/boot-9.scm ("ice-9/r7rs-libraries"): Include file.
* module/ice-9/psyntax.scm (call-with-include-port): New definition.
(include): Use call-with-include-port.
* module/ice-9/psyntax-pp.scm: Regenerate.
* module/ice-9/r7rs-libraries.scm: New file.
* module/scheme/base.scm (r7:include, r7:include-ci): Fix mistaken use
of core "include". Use include-ci from core.
(features): Remove features that are already part of core.
* NEWS: Update.
Diffstat (limited to 'module/scheme')
-rw-r--r-- | module/scheme/base.scm | 16 |
1 files changed, 6 insertions, 10 deletions
diff --git a/module/scheme/base.scm b/module/scheme/base.scm index aec90d231..5a366f846 100644 --- a/module/scheme/base.scm +++ b/module/scheme/base.scm @@ -1,5 +1,5 @@ ;;; R7RS compatibility libraries -;;; Copyright (C) 2019 Free Software Foundation, Inc. +;;; Copyright (C) 2019-2020 Free Software Foundation, Inc. ;;; ;;; This library is free software: you can redistribute it and/or modify ;;; it under the terms of the GNU Lesser General Public License as @@ -297,12 +297,11 @@ #'(begin body ...) #'(r7:cond-expand more-clauses ...)))))) -(define-syntax-rule (r7:include k fn* ...) - (begin (include k fn*) ...)) +(define-syntax-rule (r7:include fn* ...) + (begin (include fn*) ...)) -;; FIXME -(define-syntax-rule (r7:include-ci k fn* ...) - (r7:include k fn* ...)) +(define-syntax-rule (r7:include-ci fn* ...) + (begin (include-ci fn*) ...)) (define-syntax-rule (r7:let-syntax ((vars trans) ...) . expr) (let-syntax ((vars trans) ...) @@ -577,14 +576,11 @@ defaults to 0 and SEND defaults to the length of SOURCE." (define (features) (append - %cond-expand-features (case (native-endianness) ((big) '(big-endian)) ((little) '(little-endian)) (else '())) - '(r6rs - syntax-case - r7rs exact-closed ieee-float full-unicode ratios))) + %cond-expand-features)) (define (input-port-open? port) (and (not (port-closed? port)) (input-port? port))) |