pub struct ShapeType<'arena> {
pub kind: ShapeTypeKind,
pub keyword: Keyword<'arena>,
pub left_brace: Span,
pub fields: Sequence<'arena, ShapeField<'arena>>,
pub additional_fields: Option<ShapeAdditionalFields<'arena>>,
pub right_brace: Span,
}Fields§
§kind: ShapeTypeKind§keyword: Keyword<'arena>§left_brace: Span§fields: Sequence<'arena, ShapeField<'arena>>§additional_fields: Option<ShapeAdditionalFields<'arena>>§right_brace: SpanImplementations§
Source§impl ShapeType<'_>
impl ShapeType<'_>
pub fn has_fields(&self) -> bool
pub fn has_non_optional_fields(&self) -> bool
Trait Implementations§
Source§impl HasSpan for ShapeType<'_>
impl HasSpan for ShapeType<'_>
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> Ord for ShapeType<'arena>
impl<'arena> Ord for ShapeType<'arena>
1.21.0 (const: unstable) · 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 ShapeType<'arena>
impl<'arena> PartialEq for ShapeType<'arena>
Source§impl<'arena> PartialOrd for ShapeType<'arena>
impl<'arena> PartialOrd for ShapeType<'arena>
impl<'arena> Eq for ShapeType<'arena>
impl<'arena> StructuralPartialEq for ShapeType<'arena>
Auto Trait Implementations§
impl<'arena> Freeze for ShapeType<'arena>
impl<'arena> !RefUnwindSafe for ShapeType<'arena>
impl<'arena> !Send for ShapeType<'arena>
impl<'arena> !Sync for ShapeType<'arena>
impl<'arena> Unpin for ShapeType<'arena>
impl<'arena> UnsafeUnpin for ShapeType<'arena>
impl<'arena> !UnwindSafe for ShapeType<'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