4 ms·
I don't think you have to go for purely functional. Jane Street, for example, went with OCaml in part because the business people found the code easier to revi
by wtetzner 7y ago
I don't think you have to go for purely functional.
Jane Street, for example, went with OCaml in part because the business people found the code easier to review than other languages.
- bayesian_horse 7y agoI've heard good things about OCaml, but it's extremely niche.
- wtetzner 7y agoSure, but that was just an example to illustrate my point. Some of these languages are viewed as hard to learn simply because they are unfamiliar. But to someone who's never programmed before, all languages are unfamiliar, and it turned out, at least in Jane Street's case, that OCaml was easier for the business people to understand than Java or C#, or even Excel macros.
- icxa 7y agoI am in no way a OCaml fan, and I primarily use Go at work. That said, the fact that OCaml is used by Bloomberg and Facebook (on multiple apps and products) alone make it not niche http://www.ocaml.org/learn/companies.html http://www.ocaml.org/learn/companies.html That plus ReasonML's growing popularity, which is essentially just a syntax extension of OCaml, makes it even further not niche.
- bayesian_horse 7y agoOh I don't doubt, that SOMEONE is using these nice languages. Still, the community of OCaml or Haskell is not nearly as big and diverse as the Python community. And that counts in all sorts of ways. You'll have much more trouble finding answers to any questions you have. You'll have less chances for community meetings or educational content. You'll definitely have more trouble finding new developers for your projects, both in business and in open source.
- icxa 7y agoAgain I am not trying to be a contrarian, but in my experience quantity != quality. You can take this statement the other way and say too much information is bad. There is a reason there are so few Go Stack Overflow questions and answers: most of Go's documentation is excellent and easy to follow and learn and they have excellent community resources, videos and guides. From what I have seen so far, the OCaml and Reason docs are great, and their communities are extremely supportive.
- jayd16 7y agoIf you throw purity out, then its no longer a language feature. You can write functional methods in any language.
- wtetzner 7y agoThere's a huge difference between "you can write functional methods in any language" and "writing functional code is default/idiomatic". Erlang doesn't support mutation at all, for example, and uses immutable types for everything. But it does let you send messages to other processes, which is a side-effect, so Erlang is not purely functional. But that doesn't mean that JavaScript is somehow just as functional as Erlang. Because it's not.
- lame88 7y agoI believe they have also cited an advantage of using OCaml being the quality of applicants they were able to pool for hiring by virtue of mainly using a functional language and being able to draw from the enthusiastic and skilled community around it. It's weird, right? In some ways, this actually has nothing to do with OCaml itself or its merits, or even the functional paradigm. I hadn't heard your example before but that's also quite interesting. I wonder how much weight these kind of side-effects account for their success, and how much is actually due to the merits of the technology itself?