[racket-dev] [plt] Push #29023: master branch updated

From: Robby Findler (robby at eecs.northwestern.edu)
Date: Mon Jul 14 09:38:22 EDT 2014

Sorry-- I replied on my phone and too tersely the first time.

What I'm trying to say is that I do not agree that compiler bugs or
ffi bugs that corrupt memory or things along these lines are
analogous. I do agree that those things do not deserve lines in our
contract error messages.

Contracts are different because the error message is really saying
only "I detected an inconsistency between the contract and the
program". The messages in previous releases were 100% one-sided. I
lean towards keeping the emphasis on the "code is wrong" side and not
the "contract is wrong" side, since that seems to make more intuitive
sense to people, but I would not mind a change that moves us more
towards an error message that is more balanced (proposals welcome!).

Not even admitting the second possibility seems unwise, however.

Robby



On Mon, Jul 14, 2014 at 8:30 AM, Robby Findler
<robby at eecs.northwestern.edu> wrote:
> I do not buy this argument: the user didn't write the compiler but they
> wrote the contract.
>
> Robby
>
>
> On Monday, July 14, 2014, Sam Tobin-Hochstadt <samth at cs.indiana.edu> wrote:
>>
>> This seems like a situation where the new error message is potentially
>> more confusing, even though it's technically more correct. There are
>> lots of other caveats we could add ("assuming there isn't a compiler
>> bug", etc) but I think adding them would make Racket harder to use.
>>
>> Sam
>>
>> On Mon, Jul 14, 2014 at 9:11 AM,  <robby at racket-lang.org> wrote:
>> > robby has updated `master' from 737330deb6 to 1dda800ca2.
>> >   http://git.racket-lang.org/plt/737330deb6..1dda800ca2
>> >
>> > =====[ One Commit ]=====================================================
>> > Directory summary:
>> >  100.0% racket/collects/racket/contract/private/
>> >
>> > ~~~~~~~~~~
>> >
>> > 1dda800 Robby Findler <robby at racket-lang.org> 2014-07-14 08:09
>> > :
>> > | add contract-correct caveat to contract violation error messages
>> > :
>> >   M racket/collects/racket/contract/private/blame.rkt | 1 +
>> >
>> > =====[ Overall Diff ]===================================================
>> >
>> > racket/collects/racket/contract/private/blame.rkt
>> > ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
>> > --- OLD/racket/collects/racket/contract/private/blame.rkt
>> > +++ NEW/racket/collects/racket/contract/private/blame.rkt
>> > @@ -320,6 +320,7 @@
>> >     from-line
>> >     on-line
>> >     blaming-line
>> > +   "   (assuming the contract is correct)"
>> >     at-line))
>> >
>> >  ;; combine-lines : (->* #:rest (listof (or/c string? #f))) string?)

Posted on the dev mailing list.