Skip to content

Tags

Tags give the ability to mark specific points in history as being important
  • 3.4.0
    [3.4.0] - 2024-12-17
    
    added:
    * added `StopwatchImpl::from_core` and `StopwatchImpl::to_core` for conversion between `libsw_core::Stopwatch`
    
    changed:
    * moved core stopwatch logic to a new crate [`libsw-core`](https://crates.io/crates/libsw-core/).
    
  • 3.3.1
    fe317148 · chore(release): 3.3.1 ·
    [3.3.1] - 2023-12-18
    
    changed:
    * bumped `quanta` support to ~0.12
    * added test coverage for `StopwatchImpl::new_started_at`
    
  • 3.3.0
    770f40d9 · chore(release): 3.3.0 ·
    [3.3.0] - 2023-06-03
    
    added:
    * added `StopwatchImpl::saturating_sub_at` and `StopwatchImpl::checked_sub_at`
    * added written introduction to front-page documentation
    * added explanation for the `Error` type's `Display` implementation to its documentation
    
    changed:
    * rewrote `Stopwatch` `PartialEq` impl without (unreachable) panicking branches
    
    removed:
    * removed example from front-page documentation
    
  • 3.2.4
    e56bab17 · chore(release): 3.2.4 ·
    [3.2.4] - 2023-04-14
    
    changed:
    * clarified documentation about overflow for `StopwatchImpl::checked_sub` and `StopwatchImpl::saturating_sub`
    
    fixed:
    * fixed `Eq` implementation for `StopwatchImpl<I>` (derived) restricting `I` to implement `Eq`
    * fixed `Eq` and `PartialEq` implementation for `Guard<'_, I>` (derived) restricting `I` to implement `Eq` and `PartialEq`, respectively
    
  • 3.2.3
    b9247114 · chore(release): 3.2.3 ·
    [3.2.3] - 2023-04-05
    
    fixed:
    * fixed incorrect hashing of `StopwatchImpl`s in specific circumstances
      * this issue only occurred when the desired `Instant` type was unrepresentable
    * fixed typo in `Hash` for `StopwatchImpl` docs
    
  • 3.2.2
    0d48edab · chore(release): 3.2.2 ·
    [3.2.2] - 2023-04-05
    
    fixed:
    * fixed incorrect `PartialEq` implementation for `StopwatchImpl`
      * two running stopwatches with different elapsed times compared equal
    * fixed incorrect `Hash` implementation for `StopwatchImpl`
      * two running stopwatches with different elapsed times hashed equally
      * **BREAKING (though warranted for patch):** for `StopwatchImpl<I>` to implement `Hash`, `I` must implement `Hash`
    
  • 3.2.1
    28ce1110 · chore(release): 3.2.1 ·
    [3.2.1] - 2023-04-04
    
    changed:
    * specify dependencies more loosely
    
  • 3.2.0
    952fb958 · chore(release): 3.2.0 ·
    [3.2.0] - 2023-03-20
    
    added:
    * added feature flag `quanta`: Implements `Instant` for `quanta::Instant`.
    * added `QuantaSw` type alias to `StopwatchImpl<quanta::Instant>`
    * added overview of features to documentation
    * added feature gate annotations to documentation
    
  • 3.1.0
    2898cc08 · chore(release): 3.1.0 ·
    [3.1.0] - 2023-02-18
    
    added:
    * added feature flag `time`: Implements `Instant` for `time::Instant`.
    * added feature flag `coarsetime`: Implements `Instant` for `coarsetime::Instant`.
    * added `TimeSw` type alias to `StopwatchImpl<time::Instant>`
    * added `CoarseSw` type alias to `StopwatchImpl<coarsetime::Instant>`
    * added `SystemSw` type alias to `StopwatchImpl<std::time::SystemTime>`
    * added `StopwatchImpl::checked_toggle`
    * added `StopwatchImpl::checked_toggle_at`
    * added documentation notes about overflow to `StopwatchImpl::toggle` and `StopwatchImpl::toggle_at`
    
    changed:
    * changed overloaded `StopwatchImpl` addition and subtraction to panic on overflow
    
  • 3.0.1
    84e51911 · chore(release): 3.0.1 ·
    [3.0.1] - 2023-02-17
    
    fixed:
    * fixed `StopwatchImpl::checked_sub` not detecting overflow when subtracting from an overflowing elapsed time
    
  • 3.0.0
    91176e5f · chore(release): 3.0.0 ·
    [3.0.0] - 2023-01-30
    
    added:
    * added `Instant` trait
    * added feature flag `nightly`: Depends on the standard library. Implements `std::error::Error` for `Error`.
    * added feature flag `std`: Implements `core::error::Error` for `Error` if std is not enabled. Requires a nightly compiler.
    * added feature flag `std_instant`: Implements `Instant` for `std::time::Instant`.
    * added feature flag `std_systemtime`: Implements `Instant` for `std::time::SystemTime`.
    * added feature flag `tokio`: Implements `Instant` for `tokio::time::Instant`.
    * added deprecated `Stopwatch` type alias to `Sw`
    * added `Sw` type alias to `StopwatchImpl<std::time::Instant>`
    * added `TokioSw` type alias to `StopwatchImpl<tokio::time::Instant>`
    * added `StopwatchImpl::new_started_at`
    * added `StopwatchImpl::set_in_place_at`
    * added `StopwatchImpl::reset_in_place`
    * added `StopwatchImpl::reset_in_place_at`
    * added `StopwatchImpl::replace_at`
    * added documentation notes about the chronology of `anchor` to the following methods:
      * `StopwatchImpl::checked_elapsed_at`
      * `StopwatchImpl::set_in_place_at`
      * `StopwatchImpl::replace_place_at`
    * added `Guard::inner`
    
    removed:
    * **BREAKING:** removed `Guard::elapsed` and `Guard::elapsed_at` in favor of `Guard::inner`
    
    changed:
    * **BREAKING:** bumped MSRV to `1.61.0`
    * renamed `Stopwatch` struct to `StopwatchImpl`
    
  • 2.2.0
    c92beb2c · chore(release): 2.2.0 ·
    [2.2.0] - 2023-01-13
    
    added:
    * added `Stopwatch::set_in_place`
    
    changed:
    * clarified documentation for `Stopwatch::from_raw` and `<Stopwatch as PartialEq>::eq`
    * optimized `Stopwatch` `PartialEq` and `Hash` impls
    
  • 2.1.1
    f488e16c · chore(release): 2.1.1 ·
    [2.1.1] - 2022-12-18
    
    changed:
    * changed `#[must_use]` message for `Guard`
    
  • 2.1.0
    d2c254ea · chore(release): 2.1.0 ·
    [2.1.0] - 2022-12-03
    
    added:
    * added `Stopwatch::checked_add` and `Stopwatch::checked_sub`
    * added `Stopwatch::checked_elapsed` and `Stopwatch::checked_elapsed_at`
    * added `Stopwatch::checked_stop` and `Stopwatch::checked_stop_at`
    
  • 2.0.2
    9bd83743 · chore(release): 2.0.2 ·
    [2.0.2] - 2022-11-19
    
    changed:
    * expanded on main-page crate documentation
    * clarified `*_at` method docs
      * previously they may have implied that they block until the current time is `anchor`, when they actually just pretend it is
    * re-ordered definitions of `Stopwatch` methods
    
  • 2.0.1
    aa6cc0e7 · chore(release): 2.0.1 ·
    [2.0.1] - 2022-11-04
    
    changed:
    * added `#[must_use]` message for `Guard`
    * inlined function called in `Display` impl for `Error`
    * removed unused lints
    
    fixed:
    * docs: fixed `Error` description, which implied it's exclusive to `Stopwatch`
    
  • 2.0.0
    e8f64c0a · chore(release): 2.0.0 ·
    [2.0.0] - 2022-10-07
    
    changed:
    * BREAKING: changed `Guard::new` to return `libsw::Result<Guard>`
    * BREAKING: changed `Error`
      * replaced all variants with `SwStart`, `SwStop`, `SwGuard`, and `GuardNew`
      * marked `non_exhaustive`
      * added `Error::expects_running`
      * added `Error::expects_stopped`
      * changed `Display` impl
    * changed `Stopwatch::guard` and `Stopwatch::guard_at` to return `Error::SwGuard`
    * shortened impl of `Stopwatch::start_at` and `Stopwatch::stop_at`
    * replaced unreachable unwrap in `Stopwatch::guard_at` with debug assertion
    * re-licensed under `MIT OR Apache-2.0`
    
  • 1.8.2
    9ec34ac6 · chore(release): 1.8.2 ·
    [1.8.2] - 2022-09-17
    
    * mark `Guard` with `#[must_use]`
    
  • 1.8.1
    dc5178bc · chore(release): 1.8.1 ·
    [1.8.1] - 2022-09-08
    
    * updated crate description
    * added documentation notes on functions which take an anchor
      * `Stopwatch::elapsed_at`
      * `Stopwatch::start_at`
      * `Stopwatch::toggle_at`
      * `Guard::elapsed_at`
    
  • 1.8.0
    bdcbc051 · chore(release): 1.8.0 ·
    [1.8.0] - 2022-09-05
    
    * added `Stopwatch::toggle_at`