Skip to content

"Find All References" doesn't work on explicit implementation of conversion operator. #54023

@AlekseyTs

Description

@AlekseyTs
interface I4<T> where T : I4<T>
{
    abstract static int operator +(T x);
}

class C4_2 : I4<C4_2>
{

    // Explicit implementation
    static int I4<C4_2>.operator +(C4_2 x) => default;
}

interface I5<T> where T : I5<T>
{
    abstract static implicit operator int(T x);
}

class C5_2 : I5<C5_2>
{

    // Explicit implementation
    static implicit I5<C5_2>.operator int(C5_2 x) => default;
}

Observed:
I couldn't find a way to get "Find All References" working on static implicit I5<C5_2>.operator int(C5_2 x).

Expected:
Works as expected on a + token in static int I4<C4_2>.operator +(C4_2 x), finds the declaration and the call sites. Expect to be able to do something similar with conversion operator.

Metadata

Metadata

Assignees

Type

No type
No fields configured for issues without a type.

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions