mirror of
https://git.savannah.gnu.org/git/guile.git
synced 2025-05-20 11:40:18 +02:00
Avoid circular dependency between (rnrs base) and (rnrs exceptions).
* module/rnrs/base.scm (raise): Define as a macro instead of a procedure.
This commit is contained in:
parent
c62da8f891
commit
b8fff11ed9
1 changed files with 7 additions and 2 deletions
|
@ -123,8 +123,13 @@
|
||||||
(define (vector-map proc . vecs)
|
(define (vector-map proc . vecs)
|
||||||
(list->vector (apply map (cons proc (map vector->list vecs)))))
|
(list->vector (apply map (cons proc (map vector->list vecs)))))
|
||||||
|
|
||||||
(define raise
|
(define-syntax raise
|
||||||
(@ (rnrs exceptions) raise))
|
;; Resolve the real `raise' lazily to avoid a circular dependency
|
||||||
|
;; between `(rnrs base)' and `(rnrs exceptions)'.
|
||||||
|
(syntax-rules ()
|
||||||
|
((_ c)
|
||||||
|
((@ (rnrs exceptions) raise) c))))
|
||||||
|
|
||||||
(define condition
|
(define condition
|
||||||
(@ (rnrs conditions) condition))
|
(@ (rnrs conditions) condition))
|
||||||
(define make-error
|
(define make-error
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue