Struct arithmetic_typing::arith::ConstraintSet
source · pub struct ConstraintSet<Prim: PrimitiveType> { /* private fields */ }
Expand description
Set of Constraint
s.
Display
ed as Foo + Bar + Quux
, where Foo
, Bar
and Quux
are
constraints in the set.
Implementations§
source§impl<Prim: PrimitiveType> ConstraintSet<Prim>
impl<Prim: PrimitiveType> ConstraintSet<Prim>
sourcepub fn just(constraint: impl Constraint<Prim>) -> Self
pub fn just(constraint: impl Constraint<Prim>) -> Self
Creates a set with one constraint.
sourcepub fn insert(&mut self, constraint: impl Constraint<Prim>)
pub fn insert(&mut self, constraint: impl Constraint<Prim>)
Inserts a constraint into this set.
sourcepub fn insert_object_safe(
&mut self,
constraint: impl ObjectSafeConstraint<Prim>,
)
pub fn insert_object_safe( &mut self, constraint: impl ObjectSafeConstraint<Prim>, )
Inserts an object-safe constraint into this set.
Trait Implementations§
source§impl<Prim: Clone + PrimitiveType> Clone for ConstraintSet<Prim>
impl<Prim: Clone + PrimitiveType> Clone for ConstraintSet<Prim>
source§fn clone(&self) -> ConstraintSet<Prim>
fn clone(&self) -> ConstraintSet<Prim>
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moresource§impl<Prim: Debug + PrimitiveType> Debug for ConstraintSet<Prim>
impl<Prim: Debug + PrimitiveType> Debug for ConstraintSet<Prim>
source§impl<Prim: PrimitiveType> Default for ConstraintSet<Prim>
impl<Prim: PrimitiveType> Default for ConstraintSet<Prim>
source§impl<Prim: PrimitiveType> Display for ConstraintSet<Prim>
impl<Prim: PrimitiveType> Display for ConstraintSet<Prim>
source§impl<Prim: PrimitiveType> PartialEq for ConstraintSet<Prim>
impl<Prim: PrimitiveType> PartialEq for ConstraintSet<Prim>
Auto Trait Implementations§
impl<Prim> Freeze for ConstraintSet<Prim>
impl<Prim> !RefUnwindSafe for ConstraintSet<Prim>
impl<Prim> Send for ConstraintSet<Prim>
impl<Prim> Sync for ConstraintSet<Prim>
impl<Prim> Unpin for ConstraintSet<Prim>
impl<Prim> !UnwindSafe for ConstraintSet<Prim>
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
source§default unsafe fn clone_to_uninit(&self, dst: *mut T)
default unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)