Cleanup: remove unused helpers, imports and dead readers #326
Loading…
Reference in a new issue
No description provided.
Delete branch "Coder629nx/Darner:cleanup-dead"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Dead code only; 91 lines deleted (+4 / −91, 8 files). Helpers with no caller, plus four standalone harness sources. The review notes are covered: the module header links
carry_over_with, andShader/Attrare imported inside the Windows-only helper that uses them.crates/darner-core/src/config.rs(−8):require_game_dir, a pub helper nothing in the tree calls.crates/darner-core/src/renamed.rs(+2 / −7):carry_over, a wrapper aroundcarry_over_with(true); the start (apps/darner/src/main.rs:615) callscarry_over_withdirectly. The doc abovecarry_over_withnames that function. The module header now linkscarry_over_withinstead of the deletedcarry_over.crates/darner-gpu/src/draw.rs(−6):skipped_all, an#[allow(dead_code)]reader of the SKIPPED counter; the counter itself stays andnot_runkeeps writing it.crates/darner-shader/src/emit/mod.rs(+2 / −2): the test module no longer importsAttrandShaderfor every target (a non-Windows build flags them unused).constant_coloris#[cfg(windows)]and still callsShader::newandAttr::NoUnwind, so those two imports sit inside that helper.tools/native-dstorage-bridge/budget_harness.rs(−37): standalone budget/slot harness (fn main), not a crate target.tools/native-dstorage-bridge/timeout_harness.rs(−22): standalone timeout/fallback harness.tools/native-dstorage-bridge/missing_harness.rs(−8): standalone missing-bridge harness.tools/native-dstorage-bridge/test_harness.rs(−1): a one-line#[path]include and nomain.That folder has no
Cargo.toml. The bridge README still buildsbridge.cppand runs thedarner-hletests; those stay. Nothing was measured — nothing here is claimed to be faster. NoDARNER_default changes.Independent Windows build, gate, and code-read review of
6ebad446c(full head6ebad446cbc2f4655d20fcd375bb382a6181e726, based onmainf3840d73d3504c30218debfbc8795b9225447317). Not run in-game.Environment
x86_64-pc-windows-msvc), MSVC 19.44.35230.Measured results
cargo clippy --workspace --all-targets --locked -- -D warnings): FAIL (exit 101;darner-shadertest build cannot resolveShaderorAttr).cargo clippy --workspace --all-targets --all-features --locked -- -D warnings): FAIL (exit 101; same compile errors).cargo xtask policy: PASS (asset policy: 551 files ok).cargo test --locked -p darner-core: PASS (31 passed; 0 failed; 0 ignored; doc tests: 0).cargo test --locked -p darner-shader --lib emit::tests::: FAIL during compilation before tests ran;ShaderandAttrare unresolved.cargo doc --locked -p darner-core --no-deps: completed, with onerustdoc::broken_intra_doc_linkswarning atcrates/darner-core/src/renamed.rs:3.Code-read audit
crates/darner-shader/src/emit/mod.rs:2392omitShaderandAttr, but its Windows-gatedconstant_colorstill usesShader::new(true)at line 3240 andAttr::NoUnwindat line 3261. Both workspace gates and the focused test fail with E0433 on this Windows target. Restore these imports (or scope them inside the helper) before merge.Config::require_game_dirhas no in-tree call sites; the workspace is explicitly unpublished (Cargo.toml:12). The removedrenamed::carry_overwrapper has no code callers; startup usescarry_over_withdirectly (apps/darner/src/main.rs:615,crates/darner-core/src/renamed.rs:41).draw::skipped_allhad no callers;SKIPPEDremains andnot_runstill increments it for intentionally skipped pipelines (crates/darner-gpu/src/draw.rs:955-962).carry_overatcrates/darner-core/src/renamed.rs:3;cargo docconfirms the unresolved link warning. Update the link tocarry_over_withor remove it.Verdict: CHANGES NEEDED.
AI-assisted: yes (GitHub Copilot, Auto mode).
Ok
Cleanup: remove unused helpers, imports and dead readersto WIP: Cleanup: remove unused helpers, imports and dead readersI fixed everything
WIP: Cleanup: remove unused helpers, imports and dead readersto Cleanup: remove unused helpers, imports and dead readersqnjk referenced this pull request2026-12-04 21:14:49 +00:00
View command line instructions
Checkout
From your project repository, check out a new branch and test the changes.Merge
Merge the changes and update on Forgejo.Warning: The "Autodetect manual merge" setting is not enabled for this repository, you will have to mark this pull request as manually merged afterwards.