Hacker News new | ask | show | jobs
by golergka 1105 days ago
Weren't a lot of functional languages, like ML and it's descendants, created specifically to write parsers and compilers?
2 comments

No. ML was the meta language for a theorem prover (LCF).

https://en.wikipedia.org/wiki/Logic_for_Computable_Functions

I've seen it claimed that ML was originally written, in lisp, in order to have a better language to write compilers in.
ML was written as the language used by the theorem prover LCF. It was written in Lisp.
I didn't know that link, searches seem to confirm. Thank you.

The LCF style provers rely on the host language type system. A theorem instance can only be created by the trusted kernel. Lisp doesn't obviously lend itself to that - you could represent the proof, but I'm not clear how you'd prevent forging one.