title: Breaking change in method overload resolution in C# 6 - explanation?
body: <p>We've recently moved from VS2013 to VS2017 in our company. After the upgrade our codebase would no longer build. We would get the following error:</p>
  
  <blockquote>
    <p>The call is ambiguous between the following methods or properties: 'IRepository&lt;T>.Get(object, params Expression&lt;Func&lt;T, object>>[])' and 'IRepository&lt;T>.Get(object, params string[])'</p>
  </blockquote>
  
  <p>Here is the call itself:</p>
  
  <pre><code>this.mainRepository.Get(newEntity.Id);
  </code></pre>
  
  <p>...and the interface definition:</p>
  
  <pre><code>public interface IRepository&lt;T&gt; where T : class
  {
      T Get(object id, params Expression&lt;Func&lt;T, object&gt;&gt;[] includeExprs);
      T Get(object id, params string[] includeExprs);
  }
  </code></pre>
  
  <p>I was wondering if anyone here could explain why this is the case. I suspect the new <em>Improved method overload resolution</em> feature of C# 6.0 but looking at the language spec I wasn't able to find out the exact rule responsible for the issue.</p>
  
  <p><strong>EDIT</strong></p>
  
  <p>I wrote a follow-up blog post about this problem: <a href="http://codewithstyle.info/method-overload-resolution-in-c-6-0-an-interesting-bug-story" rel="noreferrer">http://codewithstyle.info/method-overload-resolution-in-c-6-0-an-interesting-bug-story</a></p>