rune::parse

Trait Parse

Source
pub trait Parse
where Self: Sized,
{ // Required method fn parse(p: &mut Parser<'_>) -> Result<Self>; }
Expand description

The parse trait, implemented by items that can be parsed.

Required Methods§

Source

fn parse(p: &mut Parser<'_>) -> Result<Self>

Parse the current item from the parser.

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementations on Foreign Types§

Source§

impl<A, B> Parse for (A, B)
where A: Parse + Peek, B: Parse,

Source§

fn parse(parser: &mut Parser<'_>) -> Result<Self>

Source§

impl<T> Parse for Option<T>
where T: Parse + Peek,

Parse implementation for something that can be optionally parsed.

Source§

fn parse(parser: &mut Parser<'_>) -> Result<Self>

Implementors§

Source§

impl Parse for AttrStyle

Source§

impl Parse for Condition

Source§

impl Parse for Expr

Source§

impl Parse for ExprClosureArgs

Source§

impl Parse for ExprRangeLimits

Source§

impl Parse for ExprSelectBranch

Source§

impl Parse for Fields

Source§

impl Parse for FnArg

Source§

impl Parse for Item

Source§

impl Parse for ItemModBody

Source§

impl Parse for ItemOrExpr

Source§

impl Parse for ItemUseSegment

Source§

impl Parse for Lit

Source§

impl Parse for ObjectIdent

Source§

impl Parse for ObjectKey

Source§

impl Parse for Pat

Source§

impl Parse for PathSegment

Source§

impl Parse for Stmt

Source§

impl Parse for UnOp

Source§

impl Parse for Visibility

Source§

impl Parse for Abstract

Source§

impl Parse for AlignOf

Source§

impl Parse for Amp

Source§

impl Parse for AmpAmp

Source§

impl Parse for AmpEq

Source§

impl Parse for Arrow

Source§

impl Parse for As

Source§

impl Parse for Async

Source§

impl Parse for At

Source§

impl Parse for Attribute

Source§

impl Parse for Await

Source§

impl Parse for Bang

Source§

impl Parse for BangEq

Source§

impl Parse for Become

Source§

impl Parse for Block

Source§

impl Parse for Break

Source§

impl Parse for Caret

Source§

impl Parse for CaretEq

Source§

impl Parse for CloseBrace

Source§

impl Parse for CloseBracket

Source§

impl Parse for CloseEmpty

Source§

impl Parse for CloseParen

Source§

impl Parse for Colon

Source§

impl Parse for ColonColon

Source§

impl Parse for Comma

Source§

impl Parse for Const

Source§

impl Parse for Continue

Source§

impl Parse for Crate

Source§

impl Parse for Dash

Source§

impl Parse for DashEq

Source§

impl Parse for Default

Source§

impl Parse for Div

Source§

impl Parse for Do

Source§

impl Parse for Dollar

Source§

impl Parse for Dot

Source§

impl Parse for DotDot

Source§

impl Parse for DotDotEq

Source§

impl Parse for Else

Source§

impl Parse for EmptyBlock

Source§

impl Parse for Enum

Source§

impl Parse for Eq

Source§

impl Parse for EqEq

Source§

impl Parse for ExprAssign

Source§

impl Parse for ExprAwait

Source§

impl Parse for ExprBinary

Source§

impl Parse for ExprBlock

Source§

impl Parse for ExprBreak

Source§

impl Parse for ExprCall

Source§

impl Parse for ExprClosure

Source§

impl Parse for ExprContinue

Source§

impl Parse for ExprDefaultBranch

Source§

impl Parse for ExprElse

Source§

impl Parse for ExprElseIf

Source§

impl Parse for ExprEmpty

Source§

impl Parse for ExprFieldAccess

Source§

impl Parse for ExprFor

Source§

impl Parse for ExprGroup

Source§

impl Parse for ExprIf

Source§

impl Parse for ExprIndex

Source§

impl Parse for ExprLet

Source§

impl Parse for ExprLit

Source§

impl Parse for ExprLoop

Source§

impl Parse for ExprMatch

Source§

impl Parse for ExprMatchBranch

Source§

impl Parse for ExprObject

Source§

impl Parse for ExprRange

Source§

impl Parse for ExprReturn

Source§

impl Parse for ExprSelect

Source§

impl Parse for ExprSelectPatBranch

Source§

impl Parse for ExprTry

Source§

impl Parse for ExprTuple

Source§

impl Parse for ExprUnary

Source§

impl Parse for ExprVec

Source§

impl Parse for ExprWhile

Source§

impl Parse for ExprYield

Source§

impl Parse for Extern

Source§

impl Parse for False

Source§

impl Parse for Field

Source§

impl Parse for FieldAssign

Source§

impl Parse for File

Source§

impl Parse for Final

Source§

impl Parse for Fn

Source§

impl Parse for For

Source§

impl Parse for Group

Source§

impl Parse for Gt

Source§

impl Parse for GtEq

Source§

impl Parse for GtGt

Source§

impl Parse for GtGtEq

Source§

impl Parse for Ident

Source§

impl Parse for If

Source§

impl Parse for Impl

Source§

impl Parse for In

Source§

impl Parse for Is

Source§

impl Parse for ItemConst

Source§

impl Parse for ItemEnum

Source§

impl Parse for ItemFn

Source§

impl Parse for ItemImpl

Source§

impl Parse for ItemInlineBody

Source§

impl Parse for ItemMod

Source§

impl Parse for ItemStruct

Source§

impl Parse for ItemUse

Source§

impl Parse for ItemUsePath

Source§

impl Parse for ItemVariant

Source§

impl Parse for Label

Source§

impl Parse for Let

Source§

impl Parse for LitBool

Source§

impl Parse for LitByte

Source§

impl Parse for LitByteStr

Source§

impl Parse for LitChar

Source§

impl Parse for LitNumber

Source§

impl Parse for LitStr

Source§

impl Parse for Local

Source§

impl Parse for Loop

Source§

impl Parse for Lt

Source§

impl Parse for LtEq

Source§

impl Parse for LtLt

Source§

impl Parse for LtLtEq

Source§

impl Parse for Macro

Source§

impl Parse for MacroCall

Source§

impl Parse for Match

Source§

impl Parse for Mod

Source§

impl Parse for Move

Source§

impl Parse for Mut

Source§

impl Parse for Not

Source§

impl Parse for OffsetOf

Source§

impl Parse for OpenBrace

Source§

impl Parse for OpenBracket

Source§

impl Parse for OpenEmpty

Source§

impl Parse for OpenParen

Source§

impl Parse for Override

Source§

impl Parse for PatBinding

Source§

impl Parse for Path

Source§

impl Parse for PathSegmentExpr

Source§

impl Parse for Perc

Source§

impl Parse for PercEq

Source§

impl Parse for Pipe

Source§

impl Parse for PipeEq

Source§

impl Parse for PipePipe

Source§

impl Parse for Plus

Source§

impl Parse for PlusEq

Source§

impl Parse for Pound

Source§

impl Parse for Priv

Source§

impl Parse for Proc

Source§

impl Parse for Pub

Source§

impl Parse for Pure

Source§

impl Parse for QuestionMark

Source§

impl Parse for Ref

Source§

impl Parse for Return

Source§

impl Parse for Rocket

Source§

impl Parse for Select

Source§

impl Parse for SelfType

Source§

impl Parse for SelfValue

Source§

impl Parse for SemiColon

Source§

impl Parse for Shebang

Source§

impl Parse for SizeOf

Source§

impl Parse for SlashEq

Source§

impl Parse for Star

Source§

impl Parse for StarEq

Source§

impl Parse for Static

Source§

impl Parse for Struct

Source§

impl Parse for Super

Source§

impl Parse for Tilde

Source§

impl Parse for Token

Source§

impl Parse for True

Source§

impl Parse for TypeOf

Source§

impl Parse for Underscore

Source§

impl Parse for Unsafe

Source§

impl Parse for Use

Source§

impl Parse for Virtual

Source§

impl Parse for While

Source§

impl Parse for Yield

Source§

impl Parse for ItemId

Source§

impl Parse for FormatArgs

Source§

impl Parse for TokenStream

Source§

impl<T> Parse for Box<T>
where T: Parse,

Parse implementation for something that is boxed.

Source§

impl<T> Parse for Vec<T>
where T: Parse + Peek,

Parser implementation for a vector.

Source§

impl<T, S> Parse for AngleBracketed<T, S>
where T: Parse, S: Peek + Parse,

Source§

impl<T, S> Parse for Braced<T, S>
where T: Parse, S: Peek + Parse,

Source§

impl<T, S> Parse for Bracketed<T, S>
where T: Parse, S: Peek + Parse,

Source§

impl<T, S> Parse for Parenthesized<T, S>
where T: Parse, S: Peek + Parse,

Source§

impl<T: Parse> Parse for EqValue<T>