Skip to main content

TakeWhile1

Struct TakeWhile1 

Source
pub struct TakeWhile1<F, I: Input>(/* private fields */);

Trait Implementations§

Source§

impl<I: Input, F> Parser<I> for TakeWhile1<F, I>
where F: FnMut(I::Token) -> bool,

Auto Trait Implementations§

§

impl<F, I> Freeze for TakeWhile1<F, I>
where F: Freeze,

§

impl<F, I> RefUnwindSafe for TakeWhile1<F, I>
where F: RefUnwindSafe,

§

impl<F, I> Send for TakeWhile1<F, I>
where F: Send,

§

impl<F, I> Sync for TakeWhile1<F, I>
where F: Sync,

§

impl<F, I> Unpin for TakeWhile1<F, I>
where F: Unpin,

§

impl<F, I> UnsafeUnpin for TakeWhile1<F, I>
where F: UnsafeUnpin,

§

impl<F, I> UnwindSafe for TakeWhile1<F, I>
where F: UnwindSafe,

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<I, P> ParserExt<I> for P
where I: Input, P: Parser<I>,

Source§

fn map<F, O2>(self, f: F) -> Map<Self, F>
where F: FnMut(Self::Output) -> O2,

Source§

fn zip<P2>(self, rhs: P2) -> Zip<Self, P2>
where P2: Parser<I, Error = Self::Error>,

Source§

fn zip_left<P2>(self, rhs: P2) -> ZipLeft<Self, P2>
where P2: Parser<I, Error = Self::Error>,

両方実行し、左(self)の値だけを返す(= terminated)。
Source§

fn zip_right<P2>(self, rhs: P2) -> ZipRight<Self, P2>
where P2: Parser<I, Error = Self::Error>,

両方実行し、右(rhs)の値だけを返す(= preceded)。
Source§

fn or<P2>(self, rhs: P2) -> Or<Self, P2>
where Self::Error: MergeError, P2: Parser<I, Output = Self::Output, Error = Self::Error>,

Source§

fn attempt(self) -> Attempt<Self>

Source§

fn cut(self) -> Cut<Self>

Source§

fn optional(self) -> Optional<Self>

Source§

fn many0(self) -> Many<Self>

Source§

fn many1(self) -> Many1<Self>

Source§

fn many0_fold<B, F, Acc>(self, init: B, f: F) -> ManyFold<Self, B, F>
where B: FnMut() -> Acc, F: FnMut(Acc, Self::Output) -> Acc,

ゼロ個以上の要素を畳み込む(ゼロアロケーション)。
Source§

fn many1_fold<B, F, Acc>(self, init: B, f: F) -> Many1Fold<Self, B, F>
where B: FnMut() -> Acc, F: FnMut(Acc, Self::Output) -> Acc,

1個以上の要素を畳み込む(ゼロアロケーション)。
Source§

fn many0_into<C>( self, container: C, ) -> ManyFold<Self, impl FnMut() -> C, impl FnMut(C, Self::Output) -> C>
where C: Extend<Self::Output> + Clone,

ゼロ個以上の要素をユーザー指定のコンテナに収集する。
Source§

fn many1_into<C>( self, container: C, ) -> Many1Fold<Self, impl FnMut() -> C, impl FnMut(C, Self::Output) -> C>
where C: Extend<Self::Output> + Clone,

1個以上の要素をユーザー指定のコンテナに収集する。
Source§

fn context(self, label: &'static str) -> Context<Self>
where Self::Error: ContextError,

エラーにコンテキストラベルを付与する。
Source§

fn sep_by0<S>(self, sep: S) -> SepBy0<Self, S>
where S: Parser<I, Error = Self::Error>,

区切り付き 0 個以上の繰り返し。
Source§

fn sep_by1<S>(self, sep: S) -> SepBy1<Self, S>
where S: Parser<I, Error = Self::Error>,

区切り付き 1 個以上の繰り返し。
Source§

fn sep_by0_fold<S, B, F, Acc>( self, sep: S, init: B, f: F, ) -> SepByFold0<Self, S, B, F>
where S: Parser<I, Error = Self::Error>, B: FnMut() -> Acc, F: FnMut(Acc, Self::Output) -> Acc,

区切り付き 0 個以上の要素を畳み込む(ゼロアロケーション)。
Source§

fn sep_by1_fold<S, B, F, Acc>( self, sep: S, init: B, f: F, ) -> SepByFold1<Self, S, B, F>
where S: Parser<I, Error = Self::Error>, B: FnMut() -> Acc, F: FnMut(Acc, Self::Output) -> Acc,

区切り付き 1 個以上の要素を畳み込む(ゼロアロケーション)。
Source§

fn sep_by0_into<S, C>( self, sep: S, container: C, ) -> SepByFold0<Self, S, impl FnMut() -> C, impl FnMut(C, Self::Output) -> C>
where S: Parser<I, Error = Self::Error>, C: Extend<Self::Output> + Clone,

区切り付き 0 個以上の要素をユーザー指定のコンテナに収集する。
Source§

fn sep_by1_into<S, C>( self, sep: S, container: C, ) -> SepByFold1<Self, S, impl FnMut() -> C, impl FnMut(C, Self::Output) -> C>
where S: Parser<I, Error = Self::Error>, C: Extend<Self::Output> + Clone,

区切り付き 1 個以上の要素をユーザー指定のコンテナに収集する。
Source§

fn chainl1<Op, F>(self, op: Op) -> ChainL1<Self, Op>
where Op: Parser<I, Output = F, Error = Self::Error>, F: FnMut(Self::Output, Self::Output) -> Self::Output,

左結合の二項演算子チェーン。operand (op operand)* を左から畳む。
Source§

fn chainr1<Op, F>(self, op: Op) -> ChainR1<Self, Op>
where Op: Parser<I, Output = F, Error = Self::Error>, F: FnMut(Self::Output, Self::Output) -> Self::Output,

右結合の二項演算子チェーン。operand (op operand)* を右から畳む。
Source§

fn map_res<F, O2, E2>(self, f: F, label: &'static str) -> MapRes<Self, F>
where Self: Parser<I, Error = ParseError>, F: FnMut(Self::Output) -> Result<O2, E2>,

パーサーの結果を失敗しうる関数で変換する。 関数が Err を返した場合、Backtrack エラーになる。 入力は巻き戻さない(巻き戻したい場合は .attempt() と組み合わせる)。
Source§

fn flat_map<F, P2>(self, f: F) -> FlatMap<Self, F>
where P2: Parser<I, Error = Self::Error>, F: FnMut(Self::Output) -> P2,

Source§

fn and_then<F, P2>(self, f: F) -> FlatMap<Self, F>
where P2: Parser<I, Error = Self::Error>, F: FnMut(Self::Output) -> P2,

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.