|
|
|
|
|
by Muromec
3 days ago
|
|
>My question then is: Assuming everything I just said isn't nonsense, aren't we still in the same place as before? You have a point, but the missing piece is the context size needed to iteratively write said contract. Another angle to look at it -- we already do something like this (TDD) and it works, even if the classic argument says you can have bugs and gaps in your tests
Yes you can, but you can also have good and helpful tests. Also type systems while not being tests are from the same general area -- they express constraints which can be wrong. Yet another angle to look at it -- it's easier to write a lot of declarative stateless code plus a small library solving general case of the statefullness than writing ton of stateful imperative code. From the correctness standpoint of course. Add: contract being smaller than implementation is mentioned here, but it's a correlated metric to what I mean above. Even if the contract is longer, it could in theory allow refining different desired properties and their interactions in separate context windows. The contract being longer will also mean it specifies the behaviour in more details. |
|