The way I have found to do this is to both use the `tag` form and
explicitly rename all signature elements, e.g.:
(define-unit twice-collector@
(import (tag base (prefix base: collector^)))
(export collector^)
(define item/c base:item/c)
(define (collect . xs)
(apply base:collect (app
Imagine I have the following signature:
(define-signature collector^
[(contracted
[item/c contract?]
[collect (-> item/c ... item/c)])])
Writing a unit that exports this signature is easy. For example, here’s one
that sums its arguments:
(define-unit sum-collector@
2 matches
Mail list logo