Relate in rustc_type_ir::relate - Rust
Description: API documentation for the Rust `Relate` trait in crate `rustc_type_ir`.

Skip to main content

## Relate

# Trait Relate

Source

    pub trait Relate<I: Interner>:
        TypeFoldable<I>
        + PartialEq
        + Copy {
        // Required method
        fn relate<R: TypeRelation<I>>(
            relation: &mut R,
            a: Self,
            b: Self,
        ) -> RelateResult<I, Self>;
    }

## Required Methods§

Source

#### fn relate<R: TypeRelation<I>>( relation: &mut R, a: Self, b: Self, ) -> RelateResult<I, Self>

## Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

## Implementors§

Source§

### impl<I: Interner> Relate<I> for AliasTerm<I>

Source§

### impl<I: Interner> Relate<I> for AliasTy<I>

Source§

### impl<I: Interner> Relate<I> for ExistentialProjection<I>

Source§

### impl<I: Interner> Relate<I> for ExistentialTraitRef<I>

Source§

### impl<I: Interner> Relate<I> for FnSig<I>

Source§

### impl<I: Interner> Relate<I> for TraitPredicate<I>

Source§

### impl<I: Interner> Relate<I> for TraitRef<I>

Source§

### impl<I: Interner, T: Relate<I>> Relate<I> for Binder<I, T>