[plt-scheme] Linking units with multiple dependencies

From: Thomas Chust (chust at web.de)
Date: Sun Dec 20 03:13:09 EST 2009

Hello,

maybe I am really too dumb to find the right tools in the documentation,
but I can't figure out how to create a compound unit with multiple other
units providing its imported interfaces in case the automatic inference
of linkage information cannot be used.

Suppose I have something like

  (define-signature a^
    ())

  (define-signature b^
    ())

  (define-signature c^
    ())

  (define-unit a@
    (import)
    (export a^))

  (define-unit b@
    (import)
    (export b^))

  (define-unit c@
    (import a^ b^)
    (export c^))

Using inference of linkage information I can now define

  (define-compound-unit/infer a+b+c@
    (import)
    (export c^)
    (link a@ b@ c@))

But is there some way I can use compound-unit (or a similar form without
the /infer suffix) to the same effect? As far as I can see this is
impossible, because compound-unit allows only for a single import per
unit to be satisfied through a linkage declaration — or am I overlooking
something here?

Ciao,
Thomas


-- 
When C++ is your hammer, every problem looks like your thumb.


Posted on the users mailing list.