3 ms·
As design patterns became popular in the world of statically typed, class-based OO languages that lacked first-class functions (C++, then Java and C#) there alw
by mattrepl 17y ago
As design patterns became popular in the world of statically typed, class-based OO languages that lacked first-class functions (C++, then Java and C#) there always seemed to be an emphasis on the implementation details, namely counterfeit function objects.
The higher level abstraction aspects of a design pattern are usually better expressed without introducing codewords. E.g., the Observer pattern is just, "let's call a function on objects that want notification." It's the baggage that comes along with implementing these abstractions in blub that justifies a name as a pointer.
Related to the above, design patterns connote boilerplate; all that generic code that's needed to setup the pattern in blub.