Struct sway_parse::brackets::Parens
source · [−]pub struct Parens<T> { /* private fields */ }
Implementations
sourceimpl<T> Parens<T>
impl<T> Parens<T>
pub fn new<'a>(inner: T, span: Span, _consumed: ParserConsumed<'a>) -> Parens<T>
pub fn get(&self) -> &T
pub fn into_inner(self) -> T
sourceimpl<T> Parens<T> where
T: ParseToEnd,
impl<T> Parens<T> where
T: ParseToEnd,
sourceimpl<T> Parens<T> where
T: Parse,
impl<T> Parens<T> where
T: Parse,
pub fn parse_all_inner(
parser: &mut Parser<'_, '_>,
on_error: impl FnOnce(Parser<'_, '_>) -> ErrorEmitted
) -> ParseResult<Parens<T>>
sourceimpl<T> Parens<T> where
T: Parse,
impl<T> Parens<T> where
T: Parse,
pub fn try_parse_all_inner(
parser: &mut Parser<'_, '_>,
on_error: impl FnOnce(Parser<'_, '_>) -> ErrorEmitted
) -> ParseResult<Option<Parens<T>>>
Trait Implementations
sourceimpl<T> Parse for Parens<T> where
T: ParseToEnd,
impl<T> Parse for Parens<T> where
T: ParseToEnd,
fn parse(parser: &mut Parser<'_, '_>) -> ParseResult<Parens<T>>
Auto Trait Implementations
impl<T> RefUnwindSafe for Parens<T> where
T: RefUnwindSafe,
impl<T> Send for Parens<T> where
T: Send,
impl<T> Sync for Parens<T> where
T: Sync,
impl<T> Unpin for Parens<T> where
T: Unpin,
impl<T> UnwindSafe for Parens<T> where
T: UnwindSafe,
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more