[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Chicken-hackers] -block not properly mixing with -strict-types

From: Jörg F . Wittenberger
Subject: Re: [Chicken-hackers] -block not properly mixing with -strict-types
Date: 11 Apr 2013 12:25:59 +0200

On Apr 11 2013, Felix wrote:

From: Jörg F. Wittenberger <address@hidden>
Subject: [Chicken-hackers] -block not properly mixing with -strict-types
Date: 10 Apr 2013 19:40:32 +0200


I just noticed, that I can't mix -block with -strict-types.

That is, when I -emit-type-file, the resulting file contains
the type definitions ONLY if -block is NOT given.  With -block
it's empty (except for comments),

Thus I can either get warnings for call sites violating the
required types OR apply -block.

I don't thing this is how it should be, is it?

Well, actually it is. -emit-type-file emits types for all exported
toplevel variables. But -block effectively hides all toplevel
bindings, so no variables get exported. Block mode "seals" the
compilation unit, nothing inside it is visible from the outside.

Hm.  This means that there is only one compilation unit ever?

I've got 82 modules for a single program.  Would I have to merge
them all into a single file if I want -block to take effect?

Well, this would still not cut it.  I'd still need a way to
(however complicated) to make some bindings visible (read only
that is) from eval.

So block it not for me?



-strict-types will work with -block, but -emit-type-file will not.
We should probably document this properly to make it more obvious.


reply via email to

[Prev in Thread] Current Thread [Next in Thread]