[racket-dev] Blame and re-provided bindings

From: Casey Klein (clklein at eecs.northwestern.edu)
Date: Mon Jan 17 06:39:23 EST 2011

On Sun, Jan 16, 2011 at 10:03 PM, Matthias Felleisen
<matthias at ccs.neu.edu> wrote:
>
> On Jan 15, 2011, at 5:05 PM, Casey Klein wrote:
>
>> On Sat, Jan 15, 2011 at 11:26 AM, Stevie Strickland
>> <sstrickl at ccs.neu.edu> wrote:
>>> On Jan 15, 2011, at 12:19 PM, Robby Findler wrote:
>>>> I think that we are just throwing up stumbling blocks. It is really a
>>>> design choice (does a reprovide "carry over" the contract or does it
>>>> put a new one on there?) and I seriously doubt there are any places
>>>> where someone does a reprovide intending to change the contract in
>>>> this manner. To the contrary, I expect that nearly every place where
>>>> someone does a reprovide, they indented to use the exact same contract
>>>> (with different parties now).
>>>
>>> This is possible, but _which_ parties?  Do you wish to export internals through an external interface that should now take on the positive blame, so that you don't leak your internals (via module names and such used as blame parties)?  This seems to me what you'd want for something like redex [...]
>>
>> No, that's not the use case.
>>
>> There are three modules, each of which is an external interface:
>>
>> 1. redex/reduction-semantics, which provides the non-GUI portion of Redex,
>> 2. redex/pict, which provides the typesetting utilities, and
>> 3. redex, which provides all of redex/reduction-semantics and
>> redex/pict, plus some more.
>>
>> The redex module does an all-from-out provide on what it gets from
>> redex/reduction-semantics and redex/pict, making it the negative party
>> on the contracts. When a redex client breaks one of the contracts,
>> redex gets blamed instead of the client.
>
> This sounds like a plain bug.
>

Yes, it's definitely a bug (in Redex).

All I want is a convenient way to fix the bug. Naming all the
contracts and applying them at both levels seems pretty cumbersome,
even with macros.

(But I do share Robby's concern that the easy way to reprovide is not
the right way to reprovide.)


Posted on the dev mailing list.