5 ms·
In some sense, it is, it's just happening every slowly. Functional programming features are getting a foothold in mainstream languages. It's a drizzle, but the
by unscaled 8y ago
In some sense, it is, it's just happening every slowly.
Functional programming features are getting a foothold in mainstream languages. It's a drizzle, but the direction is clear.
Let's look at closures. Back in the 90s and early 2000s, if you were a mainstream developer using C, C++, Java or C# you were out of luck. But during the following decade all said languages (except C) added them, and nowadays closures are taken for granted in almost any new language being designed.
Functional list/stream processing APIs are the next feature being popularized, with such APIs being available in most mainstream languages nowadays (Go is a notable exception).
Other FP concepts like immutability, sum types, pattern matching and even type classes are finding their way into mainstream languages. Their adoption is far from universal but direction is clear. FP is becoming more widely adopted, just not necessarily FP languages.
- externalreality 8y ago> In some sense, it is, it's just happening every slowly. Yup, real world engineering doesn't heed purity of concept. What you get is a hodgepodge of best practices and ideas that work. Today we see JS, Golang, Ruby, modern C, C++, all of these things have ideas and features directly drawn from functional programming and likewise, many functional programming languages use ideas from other paradigms. We likely won't see Lisp or Smalltalk become dominant anytime soon but there is no denying that many of their features have made it into many of the main stream languages that have become mainstream for reasons far detached from their programming paradigms (um maybe not Java, for better or worse, Java sold OOD and OOD sold Java).
- apta 8y ago> Golang > all of these things have ideas and features directly drawn from functional programming golang is the complete opposite of that, they disregarded useful research with unsubstantiated claims and it's just a basic procedural language with some concurrency, that's it.
- externalreality 8y agoYou kind of forget the fact that the language has first class functions. That alone qualifies it as a functional programming language in every sense of the MF word. It also has interface and (like you mention CSP). Its more than a strictly procedural language. I'm afraid I am going to have to standby what I said.
- apta 8y agoBy that argument, C# is a functional programming language, so is Python, and maybe even C.
- externalreality 8y agoYes, they are. Its not the dominate paradigm and you wouldn't want to program them that way, but that's my point.
- Rotareti 8y ago> In some sense, it is, it's just happening every slowly. The web frontend world has become very functional as well. The react stack is full of FP, for example. React was initially written in SML, then transcribed to JS and recently to OCaml/ReasonML.