Re:Formal methods only solve half my problems
by csours on Friday June 03, 2022 @09:18PM
(#31615847)
The longer I spend in IT/Software Dev, the more I see a dichotomy between Correctness and Usefulness. You can certainly have both, but different people concentrate on either correctness or usefulness. I think the future of software dev is people who understand both.
[ Parent
| on HN ]
Re:Formal methods only solve half my problems
by justahuman74 on Friday June 03, 2022 @09:29PM
(#31615918)
The tools make it very hard to do both at the same time.
To pick a topic, is there something I could write shell-style scripts in that leans towards correctness?
Re:Formal methods only solve half my problems
by pharmakom on Saturday June 04, 2022 @06:08AM
(#31618683)
Yes! F# scripts
Some features:
- open-source
- cross-platform
- quick editing with syntax highlighting, type annotations etc. in VS Code
- run in a single command (‘dotnet fsi script.fsx’)
- type-safe but with global type inference
- grab dependencies using directives in the script (no project manifests or global dependencies)
The added safety of a typed language is fantastic for scripting because it’s not worth writing tests for most scripts.
Re:Formal methods only solve half my problems
by simonmic on Sunday June 05, 2022 @03:00AM
(#31628698)
Haskell
(using https://docs.haskellstack.org/en/stable/GUIDE/#script-interp...).
The downside: requires 1. installing stack and 2. waiting for it to install ghc and libs on first run of the script.