4 ms·
I don't have any idea what you're talking about when you say 'functional came before OO'. I'm guessing you are talking about Lisp, but not only are Common Lisp
by ltbarcly3 10y ago
I don't have any idea what you're talking about when you say 'functional came before OO'.
I'm guessing you are talking about Lisp, but not only are Common Lisp (and the languages it evolved from) not at all functional in any technical sense of the word, many of them only had dynamic scoping, and often used mutation of data structures implicitly.
Stop talking nonsense.
EDIT: If you are talking about scheme, then the same exact points apply. On top of all of the above points, nobody in the world other than a few extreme language-philes ever use any of the functional languages, and for good reason. Functional programming is nonsense, the only people that talk about it are academics and people who want to seem smart. Functional != Structured Programming, Functional != Procedural, 'functional' has a precise meaning: treats computation as the evaluation of mathematical functions and avoids changing-state and mutable data. Neither Schema nor Lisp nor any but a very few quite obscure languages satisfy this.
- qwertyuiop924 10y ago>I don't have any idea what you're talking about when you say 'functional came before OO'. Lambda calculus is technically the first functional language, and predates computers. But if we're talking about actual programming languages, SASL, one of the earliest functional languages actually implemented, was released the same year as Smalltalk, and was influenced by the older ISWIM, which was never implemented. >I'm guessing you are talking about Lisp, but not only are Common Lisp (and the languages it evolved from) not at all functional in any technical sense of the word. The functional style (writing most of your code as pure functions, keeping impure code isolated), however, can be practiced in ANY language. It makes your systems easier to reason about, because you know if state is being modified. And Lisps had many constructs that made FP convenient. Like map. So while Lisp, on the whole, wasn't functional, it was one of the easiest languages to write functional code in for some time. >On top of all of the above points, nobody in the world other than a few extreme language-philes ever use any of the functional languages, and for good reason. On the contrary, FP has heavy use in finance and other places where there is a low tolerance for error, as well as Microsoft and many other conpanies. It has heavy use in programming language research, and a functional programming language was used for program analysis to aid in the optimization of FFTW, which is still one of the fastest implementations of the Fast Fourier Transform. >Stop talking nonsense. As the above demonstrates, you're the only one who's doing that.
- abecedarius 10y agoThe lambda calculus was also the first OO language. (William Cook pointed this out in http://web.engr.oregonstate.edu/~walkiner/teaching/cs583-sp16/papers/Cook-DataAbstraction.pdf http://web.engr.oregonstate.edu/~walkiner/teaching/cs583-sp1... and I'd noticed the same thing. I just want to bring in a neat observation here, not fight for either side of the OO/FP culture war. I wish we humans wouldn't do that.)
- qwertyuiop924 10y agoHeh. Neat.
- justin_vanw 10y agoHow is 'the same year as smalltalk' predating it? Simula was working in like '67, which is like 5 years before smalltalk. My point is that functional languages do not predate OO languages, and if anything come later, and you never really addressed that.
- qwertyuiop924 10y ago>How is 'the same year as smalltalk' predating it? That's just the first one that was implemented. The IDEAS reach far further back. ISWIM was '66, it it's not the oldest. >My point is that functional languages do not predate OO languages, and if anything come later, and you never really addressed that. Between my points on Lisp, ISWIM, Lambda Calculus, and others, I think I did that quite adequately.
- justin_vanw 10y agoNot really? The claim that functional programming predates OO would require that functional programming languages existed before OO languages, which is clearly false. If anything they were both developed at approximately the exact same time, which has more to do with hardware coming into existence and wider use that could support higher level languages.
- GFK_of_xmaspast 10y ago> Neither Schema nor Lisp nor any but a very few quite obscure languages satisfy this. That doesn't seem like it would be a very useful definition then.
- justin_vanw 10y agoHaskell, Ocaml, etc. There's nothing at all functional about Common Lisp, not even a little bit, far from it, if anything the opposite.
- lispm 10y agoWhich is nonsense. Common Lisp and its implementations supports some parts of Functional Programming: * First Class Functions * Higher Order Functions * Anonymous Functions * Lexical Binding * Closures * TCO is supported by a variety of implementations