Registry / utility / countme

countme

JSON →
library3.0.1rscratesunverified

Counts the number of live instances of types at runtime.

# Cargo.toml [dependencies] countme = "3.0.1"
INSTALL
IMPORT
SIG · COUNTME
C
countme
utilityrustv3.0.1
harness data pending
Install & Compatibility
Where this runs

No compatibility data collected yet for this library.

Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

CountMe
use countme::CountMe;

Derives CountMe to track live instances of a struct.

use countme::CountMe; #[derive(CountMe)] struct MyStruct; fn main() { let instance = MyStruct; println!("Live instances: {}", MyStruct::count()); }
Debug
Known issues
gotchaRequires the `derive` feature for the `CountMe` derive macro.
fix
Add `features = ["derive"]` to the Cargo.toml dependency.
affects: >=3.0.0
Upgrade
Version history
3.0.1latest on crates.io
Audit
Dependencies

No dependency data recorded yet.

Agent activity
11 hits · last 30 days
node
10
OpenAI (training)
1
Resources
countme — cargo add countme · libregistry