……生成描述上溢/下溢的 assertions,进而倒逼你在函数参数上加上合适的前置条件。:-) 顺便问下,你读过 K. Rustan M. Leino 最近出的那本《Program Proofs》以及 Dafny 语言吗?这是我在该编程风格和技术领域见过的最新、且目前最好的一本书。
…generate assertions that describe overflow/underflow, which then forces you to put the appropriate preconditions on function parameters. :-) By the way, have you run across K. Rustan M. Leino's recent book, Program Proofs, and the Dafny language. It's the most recent and so far, best book I've seen on the style and technology.
…practice, you'll start to understand your systems better, and things like what I wrote up will come to you more easily when analyzing and designing them. To move towards formal proofs of code, I like Leino's Program Proofs (uses Dafny), one of the more approachable tutorials on the subject.
https://news.ycombinator.com/item?id=38691437 - Dec 2023, 1 comment This only had the one previous submission but I found it interesting. The mentioned book, Program Proofs, is worth checking out if the topic and language interests you.
…better as a pedagogical system than what I've seen and used for other languages. I'm exploring it now as a way to ease colleagues into SPARK. A lot of the material appears to transfer over and the book Program Proofs seems better to me than what I found for SPARK. I probably wouldn't have colleagues work through the book themselves so much as run a series of tutorials. We've done this often in the past when trying…
……生成描述上溢/下溢的 assertions,进而倒逼你在函数参数上加上合适的前置条件。:-) 顺便问下,你读过 K. Rustan M. Leino 最近出的那本《Program Proofs》以及 Dafny 语言吗?这是我在该编程风格和技术领域见过的最新、且目前最好的一本书。
…generate assertions that describe overflow/underflow, which then forces you to put the appropriate preconditions on function parameters. :-) By the way, have you run across K. Rustan M. Leino's recent book, Program Proofs, and the Dafny language. It's the most recent and so far, best book I've seen on the style and technology.
……多加练习,你就会开始更好地理解自己的系统,在分析和设计它们时,我写的那类东西就会更自然地信手拈来。如果想迈向代码的形式化证明,我推荐 Leino 的《Program Proofs》(使用的是 Dafny),这是该领域比较通俗易懂的入门教程之一。
…practice, you'll start to understand your systems better, and things like what I wrote up will come to you more easily when analyzing and designing them. To move towards formal proofs of code, I like Leino's Program Proofs (uses Dafny), one of the more approachable tutorials on the subject.
https://news.ycombinator.com/item?id=38691437 - 2023年12月,1条评论。之前就这一条提交,但我觉得挺有意思。如果你对这个话题和语言感兴趣,提到的那本《Program Proofs》很值得一读。
https://news.ycombinator.com/item?id=38691437 - Dec 2023, 1 comment This only had the one previous submission but I found it interesting. The mentioned book, Program Proofs, is worth checking out if the topic and language interests you.
……作为教学体系,比我在其他语言上见过和用过的都要好。我目前正在探索用它来帮同事平滑过渡到 SPARK。很多内容看起来是可以迁移过去的,而且对我来说,《Program Proofs》这本书似乎比我能找到的 SPARK 资料要更好。我大概不会让同事自己啃书,而是会办一系列的 tutorial。过去我们在尝试……时经常这么干。
…better as a pedagogical system than what I've seen and used for other languages. I'm exploring it now as a way to ease colleagues into SPARK. A lot of the material appears to transfer over and the book Program Proofs seems better to me than what I found for SPARK. I probably wouldn't have colleagues work through the book themselves so much as run a series of tutorials. We've done this often in the past when trying…