Hacker News new | past | comments | ask | show | jobs | submit login

This is the problem that I've run into trying to use formal methods.

I love them, I can express some things very concisely and even clearly. But there's no direct connection to the code and so keeping things synchronized (like keeping comments synchronized with code) is nigh impossible.

We need the details of these higher level models encoded in the language in a way that forces us to keep them synced. Type driven development seems like one possible route for this, and another is integrating the proof languages as is done with tools like Spark (for Ada).

This will reduce the speed of development, in some ways, but hopefully the improvement in reliability and the greater ability to communicate purpose of code along with the code will also improve maintainability and offset the initial lost time.

And by keeping it optional (or parts of it optional) you can choose (has to be a concious choice) to take on the technical debt of not including the proofs or details in your code (like people who choose to leave out various testing methodologies today).




>use formal methods.

My admittedly very brief experience with formal methods was that they were actually less close to the "design" of the software than the code. So not sure that's a direction that will get us anywhere we need to go.

>in a way that forces us to keep them synced.

Why "synced"? Wouldn't it be better if those higher level designs were actually coded up and simply part of the implementation, but at a level of abstraction that is appropriate to the design.

We used to increase our level of abstraction, but now we appear to have been stuck for the last 30-40 years or so. At least I don't see anything that's as much of a difference to, let's say Smalltalk as Smalltalk is to assembly language.


Gilad Bracha wandered off to work on progressively typed languages after he’d had enough of trying to fix Java’s type system.

I think if it took something like JSdoc and have it more teeth you could do something like this in just about any of the dynamically typed languages.


Well, he also "wandered in" from doing optionally statically typed languages...see Strongtalk and Newspeak. :-)


Especially in the functional space there are some good ways to do DDD, although I don't see why we limit this to functional languages.

https://fsharpforfunandprofit.com/series/designing-with-type...




Join us for AI Startup School this June 16-17 in San Francisco!

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: