Skip to content

v0.2.0 — API refinement, clippy clean, docs update

Pre-release
Pre-release

Choose a tag to compare

@jamesgober jamesgober released this 27 Aug 07:19
· 55 commits to main since this release

Version 0.2.0 - 2025-08-27

This release refines the collector API, keeps the codebase clippy-clean under strict lints, and updates documentation and tests. A minor breaking change improves ergonomics and performance for recording measurements.

✨ Features

  • New types: Duration, Measurement
  • New functions: measure, measure_named
  • New macros: time!, time_named!
  • Optional std-only Collector with Stats aggregation (thread-safe; per-name stats)
  • Feature flags: enabled, std, minimal, full (default = ["std","enabled"])

🐛 Bug Fixes

  • Resolve Clippy warnings by adding targeted #[allow(clippy::cast_precision_loss)] and modernizing format strings, maintaining #![deny(clippy::all)] without warnings across all targets/features.
  • Ensure no_std test stability by gating test_duration_display behind the std feature.

💥 Breaking Changes

  • Collector::record now accepts &Measurement instead of taking it by value: pub fn record(&self, measurement: &Measurement).
    • Migration: Update call sites from collector.record(measurement) to collector.record(&measurement).
    • Rationale: Avoids unnecessary moves/clones and enables cheaper call sites.

📈 Improvements

  • Update Duration Display to use inline format args (no functional change).
  • Update documentation examples to version 0.2.0 and clarify feature usage (zero-overhead with default-features = false).
  • Update tests and examples to the new Collector::record(&Measurement) signature.

⚠️ Deprecations

None.


Full Changelog

Full Changelog: v0.1.5...v0.2.0