Skip to content

Easy complexity cleanup: fix diagnostic example scanner stale index #111

@cuzzo

Description

@cuzzo

Report-backed easy refactor.

Source: Decomplex report-tools-diagnostic-scan / Derived-State Staleness.

Problem:
src/ast/diagnostic_examples.rb#scan_file derives j from i, then continues with stateful scanning. The scanner is small, covered by tests, and suitable for a low-risk cleanup.

Acceptance:

  • Refactor scanner state so the next describe index is explicit and not stale-derived.
  • Add focused coverage for fix-line scanning and malformed annotations.
  • No new T.untyped slots.
  • Decomplex/SlopCop metrics stay flat or improve.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions