dotnet/roslyn

Renaming a global using alias does not update usages

Open

#74,474 创建于 2024年7月22日

在 GitHub 查看
 (2 评论) (0 反应) (1 负责人)C# (4,257 fork)batch import
Area-IDEBughelp wanted

仓库指标

Star
 (20,414 star)
PR 合并指标
 (平均合并 6天 17小时) (30 天内合并 256 个 PR)

描述

Version Used: 17.11.0 Preview 3.0

Steps to Reproduce: Test1.cs

global using MyInteger = int; // Rename here…

Test2.cs

public class C {
  public MyInteger M() => 42; // …or here
}

Rename the MyInteger using alias in any of the two places.

Expected Behavior: The using alias should be updated in both places.

Actual Behavior: Only the using alias declaration is updated. This looks especially weird when you start the rename from the usage.

贡献者指南