[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Endless loop in guile 1.6.1 if using macros
From: |
Christian Neukirchen |
Subject: |
Endless loop in guile 1.6.1 if using macros |
Date: |
Sat, 18 Jan 2003 13:41:41 +0100 (CET) |
Hello,
The following program will make guile 1.6.1 enter an endless loop
while garbage collecting.
Put this into `module.scm':
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
(define-module (module)
:use-syntax (ice-9 syncase))
(export f)
(define-syntax ds
(syntax-rules ()
((ds a) (string-append a " (by define-syntax)\n"))))
(define (f)
(display "In F.\n")
(display (ds "In F")))
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
And this into `main.scm':
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
(use-modules (module))
(f)
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
If you run this now:
$ guile -s main.scm
In F.
<-- Endless loop!
However, if you change the
(export f)
into
(export f ds)
everything works correctly!
$ guile -s main.scm
In F.
In F (by define-syntax)
Therefore I think, all macros used by exported guile functions have to
get exported too.
This bug seems to appear in guile 1.6 only, since I talked to the mixp
developer, he uses guile 1.7 and can't reproduce it.
If you have patches, could you please CC: them to me?
Happy hacking,
Christian Neukirchen <address@hidden>
__________________________________________________________________
Gesendet von Yahoo! Mail - http://mail.yahoo.de
Bis zu 100 MB Speicher bei http://premiummail.yahoo.de
- Endless loop in guile 1.6.1 if using macros,
Christian Neukirchen <=