dotnet/roslyn

Rename doesn't resolve conflict via callsite cast

Open

#8296 aperta il 2 feb 2016

Vedi su GitHub
 (0 commenti) (0 reazioni) (0 assegnatari)C# (4257 fork)batch import
Area-IDEFeature - Renamehelp wanted

Metriche repository

Star
 (20.414 star)
Metriche merge PR
 (Merge medio 6g 17h) (256 PR mergiate in 30 g)

Descrizione

interface IX
{
    void M(); 
} 
interface IY : IX
{
    int A(); 
} 

class C
{
    void Foo()
    {
        IY y = null; 
        y.M();
    }
}

Rename A to M.

Roslyn will show an unresolvable conflict, instead of casting the callsite to IX to call the base method.

Guida contributor