title: Wrap a delegate in an IEqualityComparer
body: <p>Several Linq.Enumerable functions take an <code>IEqualityComparer&lt;T&gt;</code>. Is there a convenient wrapper class that adapts a <code>delegate(T,T)=&gt;bool</code> to implement <code>IEqualityComparer&lt;T&gt;</code>? It's easy enough to write one (if your ignore problems with defining a correct hashcode), but I'd like to know if there is an out-of-the-box solution.</p>
  
  <p>Specifically, I want to do set operations on <code>Dictionary</code>s, using only the Keys to define membership (while retaining the values according to different rules).</p>