
Is the recommended way to support a C library these days to copy what Sam did for bcrypt (if it’s self contained, of course)?

I’m writing a new contract combinator, but my #:late-neg-projection function is getting passed a blame object with a missing positive blame instead of a missing negative blame. Is that because of how I’m using my contract combinator, or some sort of bug?

@robby any idea what might be going on here?

@thinkmoore: I think that can happen if the blame gets swapped before getting to you.

ah, what’s the right thing to do in this case? somehow check and insert positive blame instead?

also, if this is the case, the documentation needs to be updated

ISTR that’s what the contract profiler does, but I’m not 100%.

@thinkmoore: blame-add-missing-party should do what you want, I think.

just found that :slightly_smiling_face:

@thinkmoore the idea is that you hold onto the “blame name” value that you get and then pass it to raise-blame-error

as the missing-party
argument

The docs really shouldn’t bias things as “neg/pos” there. Initially it is a negative party, but if you combinator is used in a negative position, you’ll get a blame object with a missing postivie party.

You can also use blame-add-missing-party

that makes sense, but the docs say “The late-neg-proj defines the behavior of applying the contract. If it is supplied, it accepts a blame object that does not have a value for the blame-negative field.”

Sorry