Earlier quoted context omitted.
Can you provide an example of how a language like C++ or Java would require a "design pattern" when another language wouldn't?
The Visitor pattern mostly addresses the shortcomings of the type system (i.e no "match" statement). The Command pattern, in its most basic form, could also be considered as implementing 1st class functions by wrapping them into objects. So if you're using a functional langage, there's a good chance you're wondering why consider both of the above as "design patterns", as you're seing them as basic things, and the com…
The visitor pattern addresses doing multiple dispatch in a single dispatch language.
> The Command pattern, in its most basic form, could also be considered as implementing 1st class functions by wrapping them into objects.
BTW, that's not really true; first class functions are not a replacement for commands. Commands are about turning behavior into state so it can be stored and executed, potentially replayed for example, at a later time. Commands aren't just functions, even languages that have first class functions still use the OO command pattern when doing things that benefit from command patterns.