[racket] Creating a #lang language, and modifying contract system

From: Robby Findler (robby at eecs.northwestern.edu)
Date: Tue Aug 9 16:59:33 EDT 2011

Could you put the value into a continuation mark and then, when you
catch the exception, look in the continuation marks to get it out
again?

Robby

On Tue, Aug 9, 2011 at 3:56 PM, Ismael Figueroa Palet
<ifigueroap at gmail.com> wrote:
>
>
> 2011/8/9 Robby Findler <robby at eecs.northwestern.edu>
>>
>> On Tue, Aug 9, 2011 at 3:01 PM, Ismael Figueroa Palet
>> <ifigueroap at gmail.com> wrote:
>> > 2011/8/4 Robby Findler <robby at eecs.northwestern.edu>
>> >>
>> >> The blame assignment stuff is wired pretty deep into the contract
>> >> system. There isn't currently any way to change that aspect of the
>> >> system without doing what you've done below.
>> >>
>> >> If you can say more about how/why you want to change it, tho, there
>> >> maybe some extension to the current API that would work for you and
>> >> that we'd be willing to maintain going forward.
>> >
>> > I defined a new-exn struct to represent exceptions and defined a raise
>> > macro
>> > that wraps Racket's raise to throw a new-exn value. Also, I need to
>> > raise
>> > the exception thrown by raise-blame-error inside a parameterize
>> > expression.
>> > I want to access and modify a parameter that will be used to construct
>> > the
>> > new-exn value.
>>
>> It sounds like you're maybe adding a field to the exn record? Can you
>> say more about what that field is and how you compute its value? (Or
>> if I'm just wrong about that?)
>
> Yes, the end result I want is to tag the exn record with a value. That value
> is stored in a parameter A. I want to make raise-blame-error to always raise
> an exception tagged with A+1.
>
> --
> Ismael
>
>


Posted on the users mailing list.