From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00 autolearn=unavailable autolearn_force=no version=3.4.4 Path: eternal-september.org!reader01.eternal-september.org!reader02.eternal-september.org!.POSTED!not-for-mail From: Paul Rubin Newsgroups: comp.lang.ada Subject: Re: "functional" programming in Ada Date: Wed, 07 Mar 2018 16:45:50 -0800 Organization: A noiseless patient Spider Message-ID: <871sgvtmwx.fsf@nightsong.com> References: <896b83c6-83d4-4ffc-8c56-1481802ea8fd@googlegroups.com> Mime-Version: 1.0 Content-Type: text/plain Injection-Info: reader02.eternal-september.org; posting-host="a758be8662b9aab46067d23c74e47735"; logging-data="23360"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1+5n1qsrU2Re81HVCKRVMeI" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/25.3 (gnu/linux) Cancel-Lock: sha1:gNNrtyIeE9EAK1OImDjamCOKOgg= sha1:2UQ4ls1hAdfE5xwBHUjQiBxKlLI= Xref: reader02.eternal-september.org comp.lang.ada:50889 Date: 2018-03-07T16:45:50-08:00 List-Id: "Alejandro R. Mosteo" writes: > Recommendations for current functional languages? I know only of > Haskell (and only by name). If you want to get a deep understanding of what FP is about as a programming language topic, I'd go with Haskell. Be aware that Haskell does things the way mathematicians do things: very rigorous and precise at the actual logical level, but more casual and relaxed at the organizational level. If you want something more like Ada, i.e. designed with attention to large-scale engineering features like separating spec from implementation, try Standard ML or the somewhat looser OCaml. Either of these will be a less mathematically rigorous than Haskell at the value and expression level, but have a much more serious module system, something like Ada's. Erlang and Elixir are more like Lisp or Python: they give a very quick and productive way to get simple things done, without much help for larger-scale rigor. The interesting thing about them is their concurrency system implements what the programmer sees as isolated lightweight processes communicating by message passing. That means you can split a big problem into smaller ones, so you can use low-tech methods on the small problems, letting the process isolation keep the subproblem solutions from interfering with each other too much. FWIW you can think of Erlang as a concurrent Lisp system with a front end for a funky Prolog-like syntax. Elixir is the same thing except the surface syntax is designed to look like Ruby. There's also LFE (Lisp-flavored Erlang), same idea except it looks like actual Lisp.