The part of my question is answered in this answer.
However, there is another situation:
public class A { }
public static class ExtendedA
{
public static void Ext(this A a) { }
}
public static class ExtendedB
{
public static void Ext(this A a) { }
}
public static class App
{
public static void Main()
{
A a = new A();
a.Ext();
}
}
How does the C# compiler chooses the method to call?