Skip to content

Commit

Permalink
add docs for is_safe
Browse files Browse the repository at this point in the history
  • Loading branch information
carolynzech committed Sep 19, 2024
1 parent 20696bf commit 51a0cbc
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions library/core/src/ub_checks.rs
Original file line number Diff line number Diff line change
Expand Up @@ -226,5 +226,6 @@ mod predicates {
/// Therefore, validity invariants must be upheld at all times, while safety
/// invariants only need to be upheld at the boundaries to safe code.
pub trait Invariant {
/// Specify the type's safety invariants
fn is_safe(&self) -> bool;
}

0 comments on commit 51a0cbc

Please sign in to comment.