title: Does functional programming replace GoF design patterns?
body: <p>Since I started learning <a href="http://en.wikipedia.org/wiki/F_Sharp_%28programming_language%29" rel="noreferrer">F#</a> and <a href="http://en.wikipedia.org/wiki/Objective_Caml" rel="noreferrer">OCaml</a> last year, I've read a huge number of articles which insist that design patterns (especially in Java) are workarounds for the missing features in imperative languages. One article I found <a href="http://www.defmacro.org/ramblings/fp.html" rel="noreferrer">makes a fairly strong claim</a>:</p>
  
  <blockquote>
    <p>Most people I've met have read 
    <a href="http://en.wikipedia.org/wiki/Design_Patterns" rel="noreferrer">the Design Patterns book</a> by the Gang of
    Four (GoF). Any self respecting programmer
    will tell you that the book is
    language agnostic and the patterns
    apply to software engineering in
    general, regardless of which language
    you use. This is a noble claim.
    Unfortunately it is far removed from
    the truth.</p>
    
    <p>Functional languages are extremely
    expressive. <strong>In a functional language
    one does not need design patterns
    because the language is likely so high
    level, you end up programming in
    concepts that eliminate design
    patterns all together.</strong></p>
  </blockquote>
  
  <p>The main features of functional programming (FP) include functions as first-class values, currying, immutable values, etc. It doesn't seem obvious to me that OO design patterns are approximating any of those features.</p>
  
  <p>Additionally, in functional languages which support OOP (such as F# and OCaml), it seems obvious to me that programmers using these languages would use the same design patterns found available to every other OOP language. In fact, right now I use F# and OCaml every day, and there are no striking differences between the patterns I use in these languages vs. the patterns I use when I write in Java.</p>
  
  <p>Is there any truth to the claim that functional programming eliminates the need for OOP design patterns? If so, could you post or link to an example of a typical OOP design pattern and its functional equivalent?</p>