Re: propositions, oppositions, and some minor details
Alex Shinn 14 Sep 2004 06:58 UTC
At Mon, 13 Sep 2004 10:33:15 +0200, Felix Winkelmann wrote:
>
> That leads me to another issue: What about separate compilation?
> The problem is here that I might have two source-files, using the
> same record type, compiled separately in two different instances of
> the compiler. How can I make sure that
>
> ; a.scm
>
> (define-record foo ...)
>
> ; b.scm
>
> (define-record foo ...)
>
> Refer to the same type?
My assumption would be that they in fact refer to different types, and
if you wanted both to refer to the same foo definition then you would
refactor that into c.scm. This is based on treated records as (at
least potentially) first class objects, as opposed to C where they are
simple header declarations and it doesn't matter how often you
redefine them.
--
Alex