Summary

Import with renaming fails when syntax refers to exported binding

Metadata

Description

(reported by Imran Rafique)

The following fails:

 (module foo (bar baz)
 (import scheme chicken)
 
 (define (baz x)
   (print x))
 
 (define-syntax bar
   (syntax-rules ()
     ((_ x) (baz x))))
 
 )
 
 (import (prefix foo f:))
 (f:bar 1)

If the export list is replaced by `((bar baz))`, then it works. The reason is that the SE of `bar` in the former case does not contain `baz`.

Changes and comments

[2010-07-26 13:41:00 UTC] felix wrote:

Update: this example works if the module and the import are compiled, separately. So the cases where it fails are:

[2010-07-29 12:40:32 UTC] felix changed status from new to closed

[2010-07-29 12:40:32 UTC] felix set resolution to fixed

[2011-04-04 08:31:00 UTC] felix removed milestone 4.6.0

[2011-04-04 08:31:00 UTC] felix wrote:

Milestone 4.6.0 deleted