pub struct StrInput<'a> { /* private fields */ }Implementations§
Trait Implementations§
Source§impl<'a> Input for StrInput<'a>
impl<'a> Input for StrInput<'a>
type Checkpoint = usize
type Slice = &'a str
type Token = char
Source§fn next_token(&mut self) -> Option<char>
fn next_token(&mut self) -> Option<char>
1トークン消費して返す。EOF なら None。
Source§fn peek_token(&self) -> Option<char>
fn peek_token(&self) -> Option<char>
次のトークンを消費せずに返す。
Source§fn slice_since(&self, cp: usize) -> &'a str
fn slice_since(&self, cp: usize) -> &'a str
checkpoint から現在位置までの Slice を返す。
fn checkpoint(&self) -> Self::Checkpoint
fn reset(&mut self, checkpoint: Self::Checkpoint)
fn offset(&self) -> usize
fn remaining(&self) -> &'a str
fn is_eof(&self) -> bool
Source§impl<'a, F> Parser<StrInput<'a>> for Escaped<F>
impl<'a, F> Parser<StrInput<'a>> for Escaped<F>
type Error = ParseError
type Output = String
fn parse_next( &mut self, input: &mut StrInput<'a>, ) -> PResult<String, ParseError>
Source§impl<'a> Parser<StrInput<'a>> for Identifier
impl<'a> Parser<StrInput<'a>> for Identifier
type Error = ParseError
type Output = &'a str
fn parse_next( &mut self, input: &mut StrInput<'a>, ) -> PResult<&'a str, ParseError>
Source§impl<'a> Parser<StrInput<'a>> for Integer
impl<'a> Parser<StrInput<'a>> for Integer
type Error = ParseError
type Output = i64
fn parse_next(&mut self, input: &mut StrInput<'a>) -> PResult<i64, ParseError>
Source§impl<'a> Parser<StrInput<'a>> for QuotedString
impl<'a> Parser<StrInput<'a>> for QuotedString
type Error = ParseError
type Output = String
fn parse_next( &mut self, input: &mut StrInput<'a>, ) -> PResult<String, ParseError>
Auto Trait Implementations§
impl<'a> Freeze for StrInput<'a>
impl<'a> RefUnwindSafe for StrInput<'a>
impl<'a> Send for StrInput<'a>
impl<'a> Sync for StrInput<'a>
impl<'a> Unpin for StrInput<'a>
impl<'a> UnsafeUnpin for StrInput<'a>
impl<'a> UnwindSafe for StrInput<'a>
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