Skip to content

Commit

Permalink
Clean up trait impls, add some safety comments (#136)
Browse files Browse the repository at this point in the history
Previously, impls of the `FromBytes`, `AsBytes`, and `Unaligned` traits
were spread across a number of inconsistent and hard-to-follow macro
invocations. This commit cleans that up by introducing a single macro
and a single section of `lib.rs` to hold macro invocations.

This commit also adds some safety comments, but there are still some
left as TODOs. Note that, since this commit does not add or remove any
trait impls (see `test_impls` for a confirmation that the exact set of
impls are tested), these TODOs are acceptable to add in this commit;
this commit moves us strictly forward in terms of safety comment
coverage.
  • Loading branch information
joshlf authored Nov 10, 2022
1 parent 140b89c commit 6beb8a4
Show file tree
Hide file tree
Showing 2 changed files with 310 additions and 188 deletions.
1 change: 1 addition & 0 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -43,5 +43,6 @@ default-features = false
[dev-dependencies]
rand = "0.6"
rustversion = "1.0"
static_assertions = "1.1"
# Required for "and $N others" normalization
trybuild = ">=1.0.70"
Loading

0 comments on commit 6beb8a4

Please sign in to comment.