Re:Ranges, Code Quality, and the future of C++
by avmich on Thursday December 27, 2018 @02:23PM
(#18771801)
Let's define "objectively better" as "allowing to do A, then B as well as to do B, then A - rather than only allowing to do A, then B". Then composability - defined as "allowing to do A, then B as well as to do B, then A" - is objectively better than imperative style - defined as "only allowing to do A, then B".
In these terms it looks like a tautology. But the essense is still there - if for some reason you'd like to have a freedom of order of some transformations, you need composability, as an opposite to an approach which prescribes the order.
In these terms it looks like a tautology. But the essense is still there - if for some reason you'd like to have a freedom of order of some transformations, you need composability, as an opposite to an approach which prescribes the order.