Zero Install, or 0install, is another package installer, but one that is cross-platform. Or, as they put it, a “decentralised cross-distribution software installation system”.
It’s written in Python (except for the Windows version which is largely written in C#). Or rather, it was written in Python, but it’s being migrated to OCaml for several reasons: single binary, performance, static type checking. There are two blog posts written about this process, where the author explored multiple candidate languages for performance versus expressiveness (if performance were the only candidate, then C/C++ would have been the obvious answer).
The blog posts are worth reading whether or not you know much about any of these langauges, or whether you have any interest in 0install itself. For example, he doesn’t handwave about performance, but confronts it head-on. But more importantly, he spends a lot of time on correctness of outcome – not theoretical correctness, but “did the program do what the user intended and if it couldn’t did it tell the user what it failed to do and why?”
I don’t necessarily agree with his reasoning in every case, but some of his proposed safety tests made me think. The “can’t write to stdout needs to be an explicit failure case” is an example of one of those startling declarations.
There are follow-up posts that focus just on OCaml.
I recommend reading all of it. You might learn something.