Holy shit holy shit holy shit holy shit: The magnitude of what’s now happening (opens external site)
View full thread · View on Hacker News
To get push notifications on iPhone or iPad, add Hack and Chat to your Home Screen: tap Share → Add to Home Screen, then open the installed app and enable push in Settings.
View full thread · View on Hacker News
I only scratched the surface of De pendant Types long ago with The Little Typer[0], but there is basically nothing that cannot be verified correct at compile time, so long as we're smart enough and write the code.
Well, now we have a smart tool that can write lots of code. Why are we not verifying everything at compile time?
Let's say we want to write a function that: 1) receives data over the internet 2) returns that data so long as it is a valid solution to a Sudoku puzzle 3) returns an error otherwise 4) is allowed to print to a debug log, but nowhere else 5) is NOT allowed to access the local file system 6) cannot change global variables
We can write a function that does all of this and verify that all those condition are always true AT COMPILE TIME. We can make it so those things are ALWAYS true.
Well, I guess we can't ensure the function is connected to an operational internet, but... well, you get the point. There are limits outside the programming language, but within the rules of the programming language we can ensure all kinds of things are ALWAYS true, and we can prove this is true AT COMPILE TIME.
Unit tests suck, forget tests. We have a shape and we cut a hole to match the shape and then we put the shape through the hole and pat ourselves on the back because the shape passed through the hole. This is unit testing.
Meanwhile Lean's type system is proving the Riemann hypothesis.
I feel like we haven't seen the language of the future yet, but I bet Lean is the closest to it.
[0]: https://thelittletyper.com/
Replies (1)