Skip to content

Extension members not suggested by IntelliSense when "Show items from unimported namespaces" is enabled #80561

@meziantou

Description

@meziantou

Version Used:

  • .NET SDK 10 RC1
  • 5.0.0-2.25459.9 (5d47bb1)
  • Language version: 14.0

Steps to Reproduce:

You can surely create your own extension member (using the new extension keyword), but here's my repro:

  1. Create a new application
  2. Add a reference to Meziantou.Framework@5.0.0
  3. Ensure "Show items from unimported namespaces" is enabled in Visual Studio options

Extension source code: https://github.com/meziantou/Meziantou.Framework/blob/84a3684af409a323159229914ed7d1c8f54dd596/src/Meziantou.Framework/EncodingExtensions.cs

  • Extension methods show up (using the "old" syntax):
Image
  • Extension members are not visible (using the new extension syntax)
Image
  • Extension members show up after adding the using directive
Image

Expected Behavior:

  • Extension members should appear in IntelliSense automatically, just like extension methods using the old syntax

Actual Behavior:

  • Extension members do not appear unless a using directive is explicitly added
  • Extension methods (old syntax) appear correctly in completion

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions