title: Array extension to remove object by value
body: <pre><code>extension Array {
      func removeObject&lt;T where T : Equatable&gt;(object: T) {
          var index = find(self, object)
          self.removeAtIndex(index)
      }
  }
  </code></pre>
  
  <p>However, I get an error on <code>var index = find(self, object)</code></p>
  
  <blockquote>
    <p>'T' is not convertible to 'T'</p>
  </blockquote>
  
  <p>I also tried with this method signature: <code>func removeObject(object: AnyObject)</code>, however, I get the same error:</p>
  
  <blockquote>
    <p>'AnyObject' is not convertible to 'T'</p>
  </blockquote>
  
  <p>What is the proper way to do this?</p>