Skip to content

refactor: resolve move_items.rs + move_items/ directory duality #950

@chubes4

Description

@chubes4

Problem

There is both a file and a directory with the same stem name:

src/core/refactor/move_items.rs       (700 lines — main move logic)
src/core/refactor/move_items/         (5 files — supporting types)
    ├── extension_integration.rs
    ├── item_kind.rs
    ├── move_options.rs
    ├── types.rs
    └── whole_file_move.rs

This is a Rust module anti-pattern. Having both move_items.rs and move_items/ at the same level creates confusion about which is the "real" module root. Rust 2021 edition supports this layout, but it's widely considered a code smell.

Proposed Fix

Rename move_items.rsmove_items/mod.rs, making the directory the single source of truth:

src/core/refactor/move_items/
├── mod.rs                      (current move_items.rs content)
├── extension_integration.rs
├── item_kind.rs
├── move_options.rs
├── types.rs
└── whole_file_move.rs

Constraints

  • No behavioral changes
  • All imports and re-exports preserved
  • cargo test and cargo clippy clean

Related

Metadata

Metadata

Assignees

No one assigned

    Labels

    cleanupDead code removal and cleanup

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions