fix(app-iced,presenter): 修 clippy -D warnings 抓到的三处(文档注释位置、manual_range_contains、单元素 for)

1. view.rs:我删掉手写 `LOADERS` 常量后,那段文档注释落到了 `VERSION_ROWS` 头上并留了空行
   (clippy::empty_line_after_doc_comments)。说明本身是给「chip 顺序为什么委派」用的,
   改成普通 `//` 注释,不冒充某个条目的文档。
2. model.rs:LiteLoader 的版本区间判定改成 `((1, 5, 2)..=(1, 12, 2)).contains(&version)`
   (clippy::manual_range_contains),语义一字未变。
3. install_tests.rs:只剩 OptiFine 一家后,单元素 `for` 改成直调(clippy::single_element_loop)。
This commit is contained in:
AskaEth committed 2026-11-10 19:34:12 +08:00
1 parent 3114fa2d4f
commit 04a123deab
3 files changed
+11 -14

No files matched your search

+5 -6
View File
@@ -149,12 +149,11 @@ fn loader_support_matrix_is_explicit() {
assert!(supported(kind), "{} 应当受支持", kind.label());
}
// OptiFine 仍没有安装管线(要跑外部 Patcher + 原地改 zip),显式拒装并说清可替代做法。
for kind in [LoaderKind::OptiFine] {
assert!(!supported(kind), "{} 不该被当成可装", kind.label());
let reason = unsupported_reason(kind);
assert!(reason.contains(kind.label()), "{reason}");
assert!(reason.contains("还没有接入"), "{reason}");
}
let optifine = LoaderKind::OptiFine;
assert!(!supported(optifine), "{} 不该被当成可装", optifine.label());
let reason = unsupported_reason(optifine);
assert!(reason.contains(optifine.label()), "{reason}");
assert!(reason.contains("还没有接入"), "{reason}");
}
#[test]