Skip to content

feat(namespace): update fully qualified type references in code #36

Closed

Description

@CalvinAllen

Description

Update fully qualified type references throughout the codebase, not just using and namespace statements.

Current Behavior

The extension updates:

  • ✅ namespace OldName → namespace NewName
  • ✅ using OldName; → using NewName;

But does NOT update:

  • ❌ var x = new OldName.MyClass()
  • ❌ OldName.MyClass.StaticMethod()
  • ❌ typeof(OldName.MyClass)

Proposed Changes

  • Add pattern to find fully qualified type references
  • Update references like OldName.ClassName → NewName.ClassName
  • Be careful not to match partial names (e.g., SomeOldName should not become SomeNewName)
  • Consider using Roslyn for more accurate parsing

Examples

// Before
var service = new OldName.Services.MyService();
OldName.Helpers.Utility.DoSomething();

// After
var service = new NewName.Services.MyService();
NewName.Helpers.Utility.DoSomething();

Considerations

  • Regex-based replacement may have edge cases
  • Roslyn-based parsing would be more accurate but adds complexity
  • Should only match at word boundaries

Priority

Medium - improves completeness of rename operation

Activity

  1. added
    enhancement
    on Dec 20, 2025
  2. added 2 commits that reference this issue on Dec 20, 2025
    df4824f
    ca0abee
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancement

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions