Static Assertions Rs Versions Save

Ensure correct assumptions about constants, types, and more in Rust

v1.1.0

4 years ago

About

Documentation

Changes

Added

  • assert_impl_any! macro
    • Asserts that the type implements any of the given traits.
  • assert_impl_one! macro
    • Asserts that the type implements exactly one in a set of traits.
  • assert_trait_sub_all! macro
    • Asserts that the trait is a child of all of the other traits.
  • assert_trait_super_all! macro
    • Asserts that the trait is a parent of all of the other traits.
  • Frequently asked questions to README.md

Fixed

  • assert_eq_size_val!, const_assert_eq!, and const_assert_ne! to export their local inner macros. Not having this prevented them from working when used or called directly via static_assertions::macro!(...)

Removed

  • Unused _assert_obj_safe! from pre-1.0

v0.3.1

5 years ago

About

Documentation

Fixed

  • Macros that refer to other internal macros can now be imported when compiling for Rust 2018 (issue #10)

v0.3.0

5 years ago

About

Documentation

Changed

  • Bumped minimum supported (automatically tested) Rust version to 1.24.0
  • Moved message parameter for assert_cfg! to last argument position, making it consistent with other macros

Removed

  • No need to use macro!(label; ...) syntax when compiling on nightly Rust and enabling the nightly feature flag (read more)

v0.2.5

5 years ago

v0.2.4

6 years ago

v0.2.3

6 years ago

Improvements

  • Removed clippy warnings
  • Trailing commas are now allowed

v0.2.2

6 years ago

New Features

  • Added assert_impl macro to ensure a type implements a given set of traits

v0.2.1

6 years ago

New Features

  • Added assert_obj_safe macro for ensuring that a trait is object-safe

v0.2.0

6 years ago

New Features

  • Added assert_eq_size_ptr macro

Improvements

  • Allow assert_eq_size, const_assert, and const_assert_eq in non-function contexts via providing a unique label #1

Changes

  • Semicolon-separated assert_eq_size is no longer allowed

v0.1.1

6 years ago

New Features

  • Added const_assert_eq macro