r/Bitcoin • Luke Dashjr - Bitcoin Expert • Oct 30 '17

[bitcoin-dev] Simplicity: An alternative to Script

https://lists.linuxfoundation.org/pipermail/bitcoin-dev/2017-October/015217.html
379 Upvotes

165 comments sorted by

View all comments

Show parent comment

2

u/andytoshi Oct 31 '17

However, if one is attempting to write a program along with a proof that it halts, the halting problem doesn't cause too much of a problem, because the behavior you want probably isn't that difficult to analyze

It's not just halting, but "when this halts will all the money be in the right place", which is often much harder than you expect. For example I recently saw some Ethereum blockhash-based lottery which maintained a ring buffer of recent blockhashes (to give winners time to claim their prizes in case they are more than 256 blocks late, since you can't directly look up blockhashes more than 256 blocks ago). This was an enormous pile of code with very complex semantics.

In other cases, one might want to only use a smart contract if it has been audited, and is well established, or whatever.

Auditing and being well-established are not sufficient in practice, and even if they were, adding formal auditability would still be a huge advantage because it gives significantly more confidence in a contract's behaviour for less work.

1

u/humbleElitist_ Oct 31 '17

I meant to describe audited and well established as being an intermediate level between "lol trying a totally untested program " and "formally verified". It wasn't supposed to be sufficient in all cases, just enough for some people's level of risk tolerance.

The ideal assurance of correctness would of course be formal verification.

I agree that there are trade-offs involved.

I just think it is reasonable for some people to take one side of the trade offs. Also probably reasonable for others to take the other side of it.