title: How to implement a Scalaz Applicative?
body: <p>I have a customer type <code>QueryResult</code> which is</p>
  
  <pre><code>type QueryResult[A] = A org.scalactic.Or One[Error]
  </code></pre>
  
  <p>When doing multiple queries, I get a <code>List[QueryResult[A]]</code>, but I want a <code>QueryResult[List[A]]</code>.
  I can implement a <code>sequence</code> method for <code>List</code>s but I would like a more generic one, so I tried creating one with Scalaz.</p>
  
  <pre><code>def sequence2[A, T[_]: Traverse](traversable: T[QueryResult[A]])
      (implicit app: Applicative[QueryResult]): QueryResult[T[A]] = {
    app.sequence(traversable)
  }
  </code></pre>
  
  <p>This seems to work but does not compile because there is no implicit parameter <code>app</code> for an <code>Applicative[QueryResult]</code>.</p>
  
  <p>How do I create one?
  Or can Scalaz somehow 'magically' generate one somehow?</p>