Skip to content

Commit 8f0c818

Browse files
Fix the Docs build and address review
Three things, from CI and from review on #42. Docs (CI failure) ----------------- `RUSTDOCFLAGS="-D warnings" cargo doc` rejected `[`UnifiedMemory`](crate::store::UnifiedMemory)` as a redundant explicit link target -- the type is already imported at the top of this module, so the bare form resolves on its own. A reference definition would have been redundant for the same reason, so there is none. `DriverRegistry::builtin` rustdoc (CodeRabbit) --------------------------------------------- Valid: the doc still enumerated "the null placeholder, TinyCortex, and the three supported native HTTP engines" after this PR added a fifth reserved id. A registry whose doc does not list what it reserves is exactly the drift the doc exists to prevent. Lint scope (CodeRabbit) ----------------------- Narrowed rather than removed. `expect_used` is `warn` workspace-wide (Cargo.toml) and CI runs clippy with `-D warnings`, and `expect`'s message is the failure diagnostic in a conformance test -- converting these to `Result` would trade a named assertion for an anonymous `?`. Eight files in this workspace carry the same attribute, including the sibling `conformance_test.rs` this one is modelled on. The finding did surface something real though: this file has seven `expect` calls and no explicit `panic!`, so `clippy::panic` was never needed. Dropped, leaving this file stricter than its siblings. cargo fmt --all -- --check: clean RUSTDOCFLAGS="-D warnings" cargo doc --no-deps --all-features -p tinymemory-core: clean cargo test -p tinymemory-core --lib store::factories_provider_test: 5 passed
1 parent 8977440 commit 8f0c818

3 files changed

Lines changed: 10 additions & 4 deletions

File tree

core/src/store/factories.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -357,7 +357,7 @@ pub fn create_memory(
357357
/// engine in the workspace is bound.
358358
///
359359
/// Issue #18 §A3/§A5. Until this existed, `tinymemory-core`'s
360-
/// [`UnifiedMemory`](crate::store::UnifiedMemory) was the one storage
360+
/// [`UnifiedMemory`] was the one storage
361361
/// implementation in the workspace with no route through the contract: the
362362
/// TinyCortex adapter binds the bundled engine, `adapters/remote` binds the
363363
/// three hosted services, and core's own SQLite store was reachable only by

core/src/store/factories_provider_test.rs

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,12 @@
66
//! no way to express it as a driver at all — which is precisely the gap §A3
77
//! describes. These are the missing equivalents.
88
9-
#![allow(clippy::expect_used, clippy::panic)]
9+
// `expect` is the assertion mechanism here, and its message is the failure
10+
// diagnostic — `expect_used` is `warn` workspace-wide (Cargo.toml) and CI runs
11+
// clippy with `-D warnings`. Scoped to that one lint: unlike the sibling
12+
// conformance tests this file has no explicit `panic!`, so it does not need
13+
// `clippy::panic` too.
14+
#![allow(clippy::expect_used)]
1015

1116
use std::sync::Arc;
1217

src/registry/mod.rs

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -186,8 +186,9 @@ impl Default for DriverRegistry {
186186
}
187187

188188
impl DriverRegistry {
189-
/// The registry every host starts from: the null placeholder, TinyCortex,
190-
/// and the three supported native HTTP engines.
189+
/// The registry every host starts from: the null placeholder, the two
190+
/// embedded engines — TinyCortex and this workspace's own `namespace`
191+
/// store — and the three supported native HTTP engines.
191192
#[must_use]
192193
pub fn builtin() -> Self {
193194
let mut reserved = BTreeMap::new();

0 commit comments

Comments
 (0)