Delete pub items nothing uses, and the stubs that hid unused code

93 pub items (78 functions and methods, 14 constants, 1 struct) in horizon-client,
horizon-world, horizon-core, horizon-friends and horizon-server-files had
no caller anywhere in the repository: not in the crate, the other crates,
the examples, the tests or the binaries. rustc can't flag them because
horizon-client and the others are libraries, where a pub item counts as
used. The imports and the private helpers only they used go with them
(title.rs date_string, goals.rs flag_index).

Also drops the #[allow(dead_code)]/#[allow(unused)] items that only hid
dead code: chat_debug_fill, merchant_title and Goals::locked_by had no
caller, and four stubs (_keep, _unused, _rule_kind, const _) existed only
to keep an import used. LightTables::from_parts is used by its tests, so
it is #[cfg(test)] instead of allowed.

Protocol id tables and entity data serializer ids stay: they mirror
vanilla's registries in full. The launcher's three unused items are left
for a launcher PR.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
Ludovic Marie
2026-10-23 12:08:35 +02:00
parent 62a6b3a620
commit 173a55e608
81 changed files with 8 additions and 688 deletions
@@ -190,14 +190,6 @@ impl UserCache {
result
}
/// `get(UUID)`: a cached player by id (expired or not).
pub fn get_by_id(&mut self, id: u128) -> Option<NameAndId> {
let index = *self.by_uuid.get(&id)?;
self.operations += 1;
self.infos[index].last_access = self.operations;
Some(self.infos[index].user.clone())
}
/// The file's text: the 1000 most recently used entries, most recent
/// first, as Gson writes them (compact, HTML-safe).
pub fn to_json(&self) -> String {