This is a series of post I wrote in 2020-2021 to dissect C++ claim about supporting (also) functional programming. I wrote these while working on a C++ firmware and trying to incorporate good practices from my former experience with Scala Language.
Scala and C++ are quite different languages designed for different goal, although both being marketed as general purpouse programming languages. Despite of this there are a number of safe and sound functional programming techniques and constructs that could be proficiently used in C++ only if…
- Is C++ Ready for Functional Programming? – Intro. What do we mean by Functional Programming, why it is important and what do we mean by C++.
- Is C++ Ready for Functional Programming? – Functions, Functions for Everyone! About the central role of functions
- Is C++ Ready for Functional Programming? – Everything is a Function. Where I examine constructs that in FP should return a value, while in C++ doesn’t.
- Is C++ Ready for Functional Programming? – Standard Library. About the functional programming support in the C++ standard library (spoiler – close to 0).
- Is C++ Ready for Functional Programming? – Types. The role of types in modern FP and how C++ fares in this field.
- Is C++ Ready for Functional Programming? – Wrap Up. Closing notes and personal considerations.