What are contracts (as proposed for C++17)?
I was reading about contracts in Thoughts about C++17 by B. Stroustrup and assisted a small presentation talking about them but I am not sure I have understood them really. So I have a some interrogations and if it is possible to illustrate them with some examples : Are contracts just a better replacement of the classic assert() and should they be used together ? What contracts really are put in simple terms for a software dev ? Would contracts have an impact on how we handle exceptions ? If yes, how should we use exceptions and contracts ? Would using contracts imply an overhead at execution