3 ms·
The only thing that keeps FP and OOP from integrating properly is the "Everything is an Object" mentality. Actually ... in Scala everything is an obje
by mafribe 10y ago
The only thing that keeps FP and OOP from
integrating properly is the "Everything
is an Object" mentality.
Actually ... in Scala everything is an object.
Functions are special cases of objects. That's Scala's great insight and it reverses what people used to think: everything is a function, and OOP is a special case of FP (this is e.g. OCaml's idea). If you look at Scala's foundations (DOT -- the dependent object calculus) this becomes pretty clear.
Could you be referring to the difference between pure programming and stateful programming? Note that OO can be done in a pure way.