Skip to content

Static extension members for enum type are not part of IntelliSense #79444

@just-ero

Description

@just-ero

Full issue information + repro project:
https://github.com/just-ero/roslyn-issues-repros/tree/main/5.0.0/006_EnumExtensionResolution

Version

Note

Roslyn: 5.0.0-1.25361.2 (fdd628a)
.NET SDK: 10.0.100-preview.6.25358.103

Visual Studio Code: 1.102.1
C# Extension: 2.86.19
C# Dev Kit Extension: 1.40.25

Steps to Reproduce

  1. Add the following code wherever syntactically applicable:
    enum E;
    
    static class EExt
    {
        extension(E)
        {
            public static void M() { }
        }
    }
  2. Type E. to see suggested members. This can be in the same file.

Expected Behavior

M is listed as a static method on E.

Actual Behavior

It is not.

Metadata

Metadata

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions