[r6rs-discuss] [Formal] blame assignment for contract violations

Robby Findler robby at cs.uchicago.edu
Tue Oct 31 10:46:21 EST 2006


At Tue, 31 Oct 2006 16:35:23 +0100, Michael Sperber wrote:
> I'm not sure I understand that.  The `contract-violation' procedure,
> when a call to it appears in a procedure P, is meant to signal that
> the caller of P did not fulfill the contract between the caller of P
> and P. Thus, the blame is being assigned to the caller.  The
> implementation of the report doesn't enter into it at this point.  (Of
> course, some built-in procedures are specified to do something similar
> to calling `contract-violation', but with the same intention.)  To my
> mind, the language of 9.17 spells this out quite clearly.  Could you
> clear up the confusion?

My only point is that "the caller" is not identified. Recording enough
information to be able to identify the caller (say, the name of the
library where the call was made), seems to require somehow specializing
each primitive to the library where it occurs, and I'm not sure how to
implement that efficiently.

All this is, of course, based on the notion that the parties agreeing
to the contracts are libraries. If you take the idea that there are
only two parties in the world (the language and the program) then it
seems reasonable (albeit less desirable) to have the blame always
(implicitly) be the program.

Does that make sense?

Robby




More information about the r6rs-discuss mailing list