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

Just curious - what is the niche for this languages and what's the motivation to choose one?





They’re not meant to be niche languages. They’re meant to be general purpose languages. They’re trying to use functional programming to achieve a high degree of correctness with short, readable programs.

Compilers are a good one. I know Rust's original compiler (before being self hosted) was implemented in OCaml. Darklang's compiler was in OCaml as well.

rustc targets LLVM IR by default, and I daresay the bulk of the optimisation and assembly-lowering work is done in LLVM. Which is solidly C++.

Not niche, Jane Street uses OCaml (and they contribute a lot to the compiler, too), it is "a research-driven trading firm where curious people work together on deep problems".

More about it here: https://www.janestreet.com/what-we-do/overview/


> where curious people work together on deep problems

'curious people': people who got jaded by academia and were attracted by the six- to seven-figure salaries at Jane Street.

'deep problems': Buy X units of Y instrument at A exchange, and sell Z units of said instrument at B exchange, and do this often enough that said company makes a pile of money for itself and its employees (mostly itself, given it can afford to pay its employees six to seven figures).


Jane Street is just one example, OCaml is widely used elsewhere, too. For example, the first compiler for Rust was written in OCaml, too.

I mentioned Jane Street because it uses OCaml for high-frequency trading, and because they are huge contributors to OCaml.




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

Search: