Thanks both - DBC is one answer - yes. Very nice - I hadn't realised this was there.
So this is the issue - funcD and funcE shouldn't know about the contract because they have no requirement for :cost-replace-with-new - they are simply wrappers for logging and performance monitoring for example. This means that funcC's post constructor should check for the output and func-calculate-insurance should assert it in the pre condition. I guess the navigational issue (who else is affected by the change in this func) can be done using keywords to search. I assumed a protocol should still return null rather than throw an exception? This definitely feels like the right solution - so essentially the reason this isn't an issue in statically typed languages is because the compiler enforces DBC where the contract *is* the type of the method signatures. I should have realised that and written a three line question originally ;) -- You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this group, send email to clojure@googlegroups.com Note that posts from new members are moderated - please be patient with your first post. To unsubscribe from this group, send email to clojure+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/clojure?hl=en