Design-by-contract continued

I goofed (a little). If you have an object literal:

foo = {
test: function() {
},
test.precondition: function() { // WRONG
}
}

So I am adding a setContract() method to the ecmaDebug.js library. I’ll upload the latest version in a few more days.
That way, I can say:

foo = {
test: function() {
},
test_precondition: function() { // WRONG
}
}
setContract(foo.test, foo.test_precondition, null);

I also added a bunch of asserts to the contract-management functions. There’s no sense in applying a contract if the contract you apply is bogus (for example, if the precondition isn’t a function or doesn’t have a matching number of arguments).