pub struct VariableType<'arena> {
pub span: Span,
pub value: &'arena str,
}Fields§
§span: Span§value: &'arena strImplementations§
Source§impl<'arena> VariableType<'arena>
impl<'arena> VariableType<'arena>
Sourcepub fn from_token(token: TypeToken<'arena>, file_id: FileId) -> Self
pub fn from_token(token: TypeToken<'arena>, file_id: FileId) -> Self
Creates a VariableType from a TypeToken and file_id.
Trait Implementations§
Source§impl<'arena> Clone for VariableType<'arena>
impl<'arena> Clone for VariableType<'arena>
Source§fn clone(&self) -> VariableType<'arena>
fn clone(&self) -> VariableType<'arena>
Returns a duplicate 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<'arena> Debug for VariableType<'arena>
impl<'arena> Debug for VariableType<'arena>
Source§impl Display for VariableType<'_>
impl Display for VariableType<'_>
Source§impl HasSpan for VariableType<'_>
impl HasSpan for VariableType<'_>
Source§fn start_position(&self) -> Position
fn start_position(&self) -> Position
A convenience method to get the starting position of the span.
Source§fn start_offset(&self) -> u32
fn start_offset(&self) -> u32
A convenience method to get the starting byte offset of the span.
Source§fn end_position(&self) -> Position
fn end_position(&self) -> Position
A convenience method to get the ending position of the span.
Source§fn end_offset(&self) -> u32
fn end_offset(&self) -> u32
A convenience method to get the ending byte offset of the span.
Source§impl<'arena> Hash for VariableType<'arena>
impl<'arena> Hash for VariableType<'arena>
Source§impl<'arena> Ord for VariableType<'arena>
impl<'arena> Ord for VariableType<'arena>
Source§fn cmp(&self, other: &VariableType<'arena>) -> Ordering
fn cmp(&self, other: &VariableType<'arena>) -> Ordering
1.21.0 · Source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more
Source§impl<'arena> PartialEq for VariableType<'arena>
impl<'arena> PartialEq for VariableType<'arena>
Source§impl<'arena> PartialOrd for VariableType<'arena>
impl<'arena> PartialOrd for VariableType<'arena>
Source§impl<'arena> Serialize for VariableType<'arena>
impl<'arena> Serialize for VariableType<'arena>
impl<'arena> Copy for VariableType<'arena>
impl<'arena> Eq for VariableType<'arena>
impl<'arena> StructuralPartialEq for VariableType<'arena>
Auto Trait Implementations§
impl<'arena> Freeze for VariableType<'arena>
impl<'arena> RefUnwindSafe for VariableType<'arena>
impl<'arena> Send for VariableType<'arena>
impl<'arena> Sync for VariableType<'arena>
impl<'arena> Unpin for VariableType<'arena>
impl<'arena> UnsafeUnpin for VariableType<'arena>
impl<'arena> UnwindSafe for VariableType<'arena>
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§impl<T> HasPosition for Twhere
T: HasSpan,
impl<T> HasPosition for Twhere
T: HasSpan,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more