cl_typeck::entry

Struct EntryMut

Source
pub struct EntryMut<'t, 'a> { /* private fields */ }

Implementations§

Source§

impl<'t, 'a> EntryMut<'t, 'a>

Source

pub fn new(table: &'t mut Table<'a>, id: Handle) -> Self

Source

pub fn as_ref(&self) -> Entry<'_, 'a>

Source

pub const fn id(&self) -> Handle

Source

pub fn evaluate<Out>( &mut self, ty: &impl TypeExpression<Out>, ) -> Result<Out, Error>

Evaluates a TypeExpression in this entry’s context

Source

pub fn categorize(&mut self) -> Result<(), Error>

Source

pub fn with_id(&mut self, parent: Handle) -> EntryMut<'_, 'a>

Constructs a new Handle with the provided parent Handle

Source

pub fn nav(&mut self, path: &[PathPart]) -> Option<EntryMut<'_, 'a>>

Source

pub fn new_entry(&mut self, kind: NodeKind) -> EntryMut<'_, 'a>

Source

pub fn add_child(&mut self, name: Sym, child: Handle) -> Option<Handle>

Source

pub fn set_ty(&mut self, kind: TypeKind) -> Option<TypeKind>

Source

pub fn set_span(&mut self, span: Span) -> Option<Span>

Source

pub fn set_meta(&mut self, meta: &'a [Meta]) -> Option<&'a [Meta]>

Source

pub fn set_source(&mut self, source: Source<'a>) -> Option<Source<'a>>

Source

pub fn set_impl_target(&mut self, target: Handle) -> Option<Handle>

Source

pub fn mark_use_item(&mut self)

Source

pub fn mark_impl_item(&mut self)

Trait Implementations§

Source§

impl<'t, 'a> Debug for EntryMut<'t, 'a>

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more

Auto Trait Implementations§

§

impl<'t, 'a> Freeze for EntryMut<'t, 'a>

§

impl<'t, 'a> RefUnwindSafe for EntryMut<'t, 'a>

§

impl<'t, 'a> Send for EntryMut<'t, 'a>

§

impl<'t, 'a> Sync for EntryMut<'t, 'a>

§

impl<'t, 'a> Unpin for EntryMut<'t, 'a>

§

impl<'t, 'a> !UnwindSafe for EntryMut<'t, 'a>

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.