pub struct Located<D, Sp = SimpleSpan, Sl = ()> { /* private fields */ }Expand description
A value with complete location information: both which source and where in that source.
Located<D, Sp, Sl> combines a value of type D with:
- A slice identifier
Slindicating which source the data came from - A span
Spindicating where within that source the data is located
This provides the most complete location tracking possible, combining the benefits
of both Sliced (source tracking) and Spanned (position tracking).
§Design
Located uses public fields for direct access, but also provides accessor methods
for consistency. It implements Deref and DerefMut to allow transparent access
to the inner data while keeping full location information available when needed.
§Common Patterns
§Transparent Access via Deref
Thanks to Deref, you can call methods on the wrapped value directly:
use tokora::{SimpleSpan, span::Located};
let located = Located::new("main.rs", SimpleSpan::new(10, 15), "hello");
// Can call str methods directly
assert_eq!(located.len(), 5);
assert_eq!(located.to_uppercase(), "HELLO");
// But can still access location info
assert_eq!(located.slice(), "main.rs");
assert_eq!(located.span().start(), 10);§Multi-File Error Reporting
use tokora::{SimpleSpan, span::Located};
use std::path::PathBuf;
fn report_error<T>(loc: &Located<T, SimpleSpan, PathBuf>, message: &str)
where
T: fmt::Debug
{
eprintln!(
"Error in {}:{}:{}: {}\n {:?}",
loc.slice().display(),
get_line_number(loc.span().start()),
get_column_number(loc.span().start()),
message,
loc.data()
);
}§Building Complete AST Nodes
use tokora::{SimpleSpan, span::Located};
use std::path::PathBuf;
type Loc<T> = Located<T, SimpleSpan, PathBuf>;
enum Expr {
Number(i64),
BinOp {
op: String,
left: Box<Loc<Expr>>,
right: Box<Loc<Expr>>,
},
}
// Each expression knows exactly where it came from
let expr = Loc::new(
PathBuf::from("src/calc.rs"),
SimpleSpan::new(45, 52),
Expr::Number(42)
);
// Can report: "Error in src/calc.rs:3:12-19"§Cross-File Reference Checking
use tokora::{SimpleSpan, span::Located};
fn check_reference(
reference: &Located<String, SimpleSpan, String>,
definition: &Located<String, SimpleSpan, String>
) -> Result<(), String> {
if reference.slice() != definition.slice() {
Err(format!(
"Cross-file reference: {} (in {}) references {} (in {})",
reference.data(),
reference.slice(),
definition.data(),
definition.slice()
))
} else {
Ok(())
}
}§Mapping Values While Preserving Full Location
use tokora::{SimpleSpan, span::Located};
let located_str = Located::new("input.txt", SimpleSpan::new(5, 7), "42");
// Parse the string, keeping both source and position
let parsed: Located<i32, SimpleSpan, &str> = located_str.map_data(|s| s.parse().unwrap());
assert_eq!(*parsed, 42);
assert_eq!(parsed.slice(), "input.txt");
assert_eq!(parsed.span().start(), 5);§IDE Integration
use tokora::{SimpleSpan, span::Located};
use std::path::PathBuf;
struct Diagnostic {
severity: Severity,
message: String,
location: Located<(), SimpleSpan, PathBuf>,
}
// Generate diagnostics with complete location info
fn undefined_variable(name: &Located<String, SimpleSpan, PathBuf>) -> Diagnostic {
Diagnostic {
severity: Severity::Error,
message: format!("Undefined variable '{}'", name.data()),
location: name.as_ref().map_data(|_| ()),
}
}
// IDE can jump to exact location:
// - Open file: diagnostic.location.slice()
// - Navigate to: diagnostic.location.span()§Incremental Compilation with Position Tracking
use tokora::{SimpleSpan, span::Located};
use std::collections::HashMap;
struct Definition {
name: String,
location: Located<(), SimpleSpan, String>,
}
// Track where each definition is located
let mut definitions: HashMap<String, Definition> = HashMap::new();
// When a file changes, only recheck definitions in that file
fn recheck_file(file: &str, definitions: &mut HashMap<String, Definition>) {
definitions.retain(|_, def| def.location.slice() != file);
// Re-parse and add new definitions from the changed file
}§Trait Implementations
Deref/DerefMut: Access the inner data transparentlyDisplay: Delegates to the inner data’sDisplayimplementationIntoComponents: Destructure into(Sl, Sp, D)tuple
§Examples
§Basic Usage
use tokora::{SimpleSpan, span::Located};
let located = Located::new("file.rs", SimpleSpan::new(0, 5), "hello");
assert_eq!(located.slice(), "file.rs");
assert_eq!(located.span(), SimpleSpan::new(0, 5));
assert_eq!(located.data(), &"hello");
assert_eq!(*located, "hello"); // Via Deref§Destructuring
use tokora::{SimpleSpan, span::Located};
let located = Located::new("main.rs", SimpleSpan::new(10, 20), 42);
let (slice, span, value) = located.into_components();
assert_eq!(slice, "main.rs");
assert_eq!(span, SimpleSpan::new(10, 20));
assert_eq!(value, 42);§Mutable Access
use tokora::{SimpleSpan, span::Located};
let mut located = Located::new("input", SimpleSpan::new(0, 2), 10);
// Modify the data
*located += 5;
assert_eq!(*located, 15);
// Modify the slice
*located.slice_mut() = "output";
assert_eq!(located.slice(), "output");
// Modify the span
located.span_mut().set_end(5);
assert_eq!(located.span().end(), 5);§Conversion from Spanned or Sliced
use tokora::{SimpleSpan, span::Located};
use tokora::slice::Sliced;
use tokora::span::Spanned;
// From Spanned by adding slice info
let spanned = Spanned::new(SimpleSpan::new(5, 10), "data");
let located = Located::new("file.rs", spanned.span(), spanned.into_data());
// From Sliced by adding span info
let sliced = Sliced::new("config.toml", "value");
let located = Located::new(sliced.into_slice(), SimpleSpan::new(0, 5), "value");Implementations§
Source§impl<D, Sp, Sl> Located<D, Sp, Sl>
impl<D, Sp, Sl> Located<D, Sp, Sl>
Sourcepub const fn new(slice: Sl, span: Sp, data: D) -> Self
pub const fn new(slice: Sl, span: Sp, data: D) -> Self
Create a new located value.
§Example
use tokora::{SimpleSpan, span::Located};
let located = Located::new("file.rs", SimpleSpan::new(10, 15), "hello");
assert_eq!(located.slice(), "file.rs");
assert_eq!(located.span(), SimpleSpan::new(10, 15));
assert_eq!(located.data(), &"hello");Sourcepub const fn slice(&self) -> Slwhere
Sl: Copy,
pub const fn slice(&self) -> Slwhere
Sl: Copy,
Get a copy of the slice.
§Example
use tokora::{SimpleSpan, span::Located};
let located = Located::new("main.rs", SimpleSpan::new(0, 5), "data");
assert_eq!(located.slice(), "main.rs");Sourcepub const fn slice_ref(&self) -> &Sl
pub const fn slice_ref(&self) -> &Sl
Get a reference to the slice.
§Example
use tokora::{SimpleSpan, span::Located};
let located = Located::new("config.toml", SimpleSpan::new(5, 10), "data");
assert_eq!(located.slice_ref(), &"config.toml");Sourcepub const fn slice_mut(&mut self) -> &mut Sl
pub const fn slice_mut(&mut self) -> &mut Sl
Get a mutable reference to the slice.
§Example
use tokora::{SimpleSpan, span::Located};
let mut located = Located::new("old.txt", SimpleSpan::new(0, 3), "data");
*located.slice_mut() = "new.txt";
assert_eq!(located.slice(), "new.txt");Sourcepub const fn span(&self) -> Spwhere
Sp: Copy,
pub const fn span(&self) -> Spwhere
Sp: Copy,
Get a copy of the span.
§Example
use tokora::{SimpleSpan, span::Located};
let located = Located::new("file.rs", SimpleSpan::new(5, 10), "data");
assert_eq!(located.span(), SimpleSpan::new(5, 10));Sourcepub const fn span_ref(&self) -> &Sp
pub const fn span_ref(&self) -> &Sp
Get a reference to the span.
§Example
use tokora::{SimpleSpan, span::Located};
let located = Located::new("file.rs", SimpleSpan::new(5, 10), "data");
assert_eq!(located.span_ref(), &SimpleSpan::new(5, 10));Sourcepub const fn span_mut(&mut self) -> &mut Sp
pub const fn span_mut(&mut self) -> &mut Sp
Get a mutable reference to the span.
§Example
use tokora::{SimpleSpan, span::Located};
let mut located = Located::new("file.rs", SimpleSpan::new(0, 5), "data");
located.span_mut().set_end(10);
assert_eq!(located.span().end(), 10);Sourcepub const fn data(&self) -> &D
pub const fn data(&self) -> &D
Get a reference to the data.
§Example
use tokora::{SimpleSpan, span::Located};
let located = Located::new("file.txt", SimpleSpan::new(0, 2), 42);
assert_eq!(*located.data(), 42);Sourcepub const fn data_mut(&mut self) -> &mut D
pub const fn data_mut(&mut self) -> &mut D
Get a mutable reference to the data.
§Example
use tokora::{SimpleSpan, span::Located};
let mut located = Located::new("file.txt", SimpleSpan::new(0, 2), 42);
*located.data_mut() = 100;
assert_eq!(*located.data(), 100);Sourcepub const fn as_ref(&self) -> Located<&D, &Sp, &Sl>
pub const fn as_ref(&self) -> Located<&D, &Sp, &Sl>
Returns a reference to the slice, span, and data.
§Example
use tokora::{SimpleSpan, span::Located};
let located = Located::new(
String::from("file.txt"),
SimpleSpan::new(0, 5),
String::from("hello")
);
let borrowed: Located<&String, &SimpleSpan, &String> = located.as_ref();
assert_eq!(borrowed.data(), &"hello");Sourcepub const fn as_mut(&mut self) -> Located<&mut D, &mut Sp, &mut Sl>
pub const fn as_mut(&mut self) -> Located<&mut D, &mut Sp, &mut Sl>
Returns a mutable reference to the slice, span, and data.
§Example
use tokora::{SimpleSpan, span::Located};
let mut located = Located::new(
String::from("file.txt"),
SimpleSpan::new(0, 5),
String::from("hello")
);
let mut borrowed: Located<&mut String, &mut SimpleSpan, &mut String> = located.as_mut();
borrowed.data_mut().push_str(" world");
assert_eq!(located.data(), &"hello world");Sourcepub fn into_slice(self) -> Sl
pub fn into_slice(self) -> Sl
Consume the located value and return the slice.
Sourcepub fn into_components(self) -> (Sl, Sp, D)
pub fn into_components(self) -> (Sl, Sp, D)
Decompose the located value into its slice, span, and data.
Sourcepub fn into_spanned(self) -> Spanned<D, Sp>
pub fn into_spanned(self) -> Spanned<D, Sp>
Convert into a Spanned value, discarding the slice information.
Sourcepub fn into_sliced(self) -> Sliced<D, Sl>
pub fn into_sliced(self) -> Sliced<D, Sl>
Convert into a Sliced value, discarding the span information.
Trait Implementations§
impl<D: Copy, Sp: Copy, Sl: Copy> Copy for Located<D, Sp, Sl>
impl<D: Eq, Sp: Eq, Sl: Eq> Eq for Located<D, Sp, Sl>
Source§impl<D, Sp, Sl> Error for Located<D, Sp, Sl>
impl<D, Sp, Sl> Error for Located<D, Sp, Sl>
1.30.0 · Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
use the Display impl or to_string()
Source§impl<D, Sp, Sl> IntoComponents for Located<D, Sp, Sl>
impl<D, Sp, Sl> IntoComponents for Located<D, Sp, Sl>
Source§type Components = (Sl, Sp, D)
type Components = (Sl, Sp, D)
Source§fn into_components(self) -> Self::Components
fn into_components(self) -> Self::Components
Source§impl<D: Ord, Sp: Ord, Sl: Ord> Ord for Located<D, Sp, Sl>
impl<D: Ord, Sp: Ord, Sl: Ord> Ord for Located<D, Sp, Sl>
1.21.0 (const: unstable) · Source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
1.21.0 (const: unstable) · Source§fn min(self, other: Self) -> Selfwhere
Self: Sized,
fn min(self, other: Self) -> Selfwhere
Self: Sized,
Source§impl<'inp, L, Ctx, Classifier, Lang: ?Sized, Cmpl> ParseInput<'inp, L, Located<<L as Lexer<'inp>>::Token, <L as Lexer<'inp>>::Span, <<L as Lexer<'inp>>::Source as Source<<L as Lexer<'inp>>::Offset>>::Slice<'inp>>, Ctx, Lang, Cmpl> for With<Expect<Classifier, Ctx, Lang>, PhantomLocated>where
L: Lexer<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
<Ctx::Emitter as Emitter<'inp, L, Lang>>::Error: From<UnexpectedToken<'inp, L::Token, <L::Token as Token<'inp>>::Kind, L::Span, Lang>> + From<UnexpectedEot<L::Offset, Lang>>,
Classifier: Check<L::Token, Result<(), Expected<'inp, <L::Token as Token<'inp>>::Kind>>>,
Cmpl: SurfaceIncomplete<'inp, L, Ctx, Lang>,
impl<'inp, L, Ctx, Classifier, Lang: ?Sized, Cmpl> ParseInput<'inp, L, Located<<L as Lexer<'inp>>::Token, <L as Lexer<'inp>>::Span, <<L as Lexer<'inp>>::Source as Source<<L as Lexer<'inp>>::Offset>>::Slice<'inp>>, Ctx, Lang, Cmpl> for With<Expect<Classifier, Ctx, Lang>, PhantomLocated>where
L: Lexer<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
<Ctx::Emitter as Emitter<'inp, L, Lang>>::Error: From<UnexpectedToken<'inp, L::Token, <L::Token as Token<'inp>>::Kind, L::Span, Lang>> + From<UnexpectedEot<L::Offset, Lang>>,
Classifier: Check<L::Token, Result<(), Expected<'inp, <L::Token as Token<'inp>>::Kind>>>,
Cmpl: SurfaceIncomplete<'inp, L, Ctx, Lang>,
Source§fn parse_input(
&mut self,
inp: &mut InputRef<'inp, '_, L, Ctx, Lang, Cmpl>,
) -> Result<Located<L::Token, L::Span, <L::Source as Source<L::Offset>>::Slice<'inp>>, <Ctx::Emitter as Emitter<'inp, L, Lang>>::Error>
fn parse_input( &mut self, inp: &mut InputRef<'inp, '_, L, Ctx, Lang, Cmpl>, ) -> Result<Located<L::Token, L::Span, <L::Source as Source<L::Offset>>::Slice<'inp>>, <Ctx::Emitter as Emitter<'inp, L, Lang>>::Error>
Source§fn delimited<D>(
self,
) -> impl for<'c> FnMut(&mut InputRef<'inp, 'c, L, Ctx, Lang, Cmpl>) -> DelimitedOf<'inp, D, L, Ctx, Lang, O>where
Self: Sized,
D: TypedDelimiter<'inp, L, Lang>,
L: Lexer<'inp>,
Ctx: ComposableParseContext<'inp, L, Lang>,
Cmpl: SurfaceIncomplete<'inp, L, Ctx, Lang>,
fn delimited<D>(
self,
) -> impl for<'c> FnMut(&mut InputRef<'inp, 'c, L, Ctx, Lang, Cmpl>) -> DelimitedOf<'inp, D, L, Ctx, Lang, O>where
Self: Sized,
D: TypedDelimiter<'inp, L, Lang>,
L: Lexer<'inp>,
Ctx: ComposableParseContext<'inp, L, Lang>,
Cmpl: SurfaceIncomplete<'inp, L, Ctx, Lang>,
Source§fn delimited_by_parens(
self,
) -> impl for<'c> FnMut(&mut InputRef<'inp, 'c, L, Ctx, Lang, Cmpl>) -> DelimitedOf<'inp, Paren<(), (), Lang>, L, Ctx, Lang, O>where
Self: Sized,
Paren<(), (), Lang>: TypedDelimiter<'inp, L, Lang>,
L: Lexer<'inp>,
Ctx: ComposableParseContext<'inp, L, Lang>,
Cmpl: SurfaceIncomplete<'inp, L, Ctx, Lang>,
fn delimited_by_parens(
self,
) -> impl for<'c> FnMut(&mut InputRef<'inp, 'c, L, Ctx, Lang, Cmpl>) -> DelimitedOf<'inp, Paren<(), (), Lang>, L, Ctx, Lang, O>where
Self: Sized,
Paren<(), (), Lang>: TypedDelimiter<'inp, L, Lang>,
L: Lexer<'inp>,
Ctx: ComposableParseContext<'inp, L, Lang>,
Cmpl: SurfaceIncomplete<'inp, L, Ctx, Lang>,
Paren delimiter pair by delegating to ParseInput::delimited.Source§fn delimited_by_braces(
self,
) -> impl for<'c> FnMut(&mut InputRef<'inp, 'c, L, Ctx, Lang, Cmpl>) -> DelimitedOf<'inp, Brace<(), (), Lang>, L, Ctx, Lang, O>where
Self: Sized,
Brace<(), (), Lang>: TypedDelimiter<'inp, L, Lang>,
L: Lexer<'inp>,
Ctx: ComposableParseContext<'inp, L, Lang>,
Cmpl: SurfaceIncomplete<'inp, L, Ctx, Lang>,
fn delimited_by_braces(
self,
) -> impl for<'c> FnMut(&mut InputRef<'inp, 'c, L, Ctx, Lang, Cmpl>) -> DelimitedOf<'inp, Brace<(), (), Lang>, L, Ctx, Lang, O>where
Self: Sized,
Brace<(), (), Lang>: TypedDelimiter<'inp, L, Lang>,
L: Lexer<'inp>,
Ctx: ComposableParseContext<'inp, L, Lang>,
Cmpl: SurfaceIncomplete<'inp, L, Ctx, Lang>,
Brace delimiter pair by delegating to ParseInput::delimited.Source§fn delimited_by_brackets(
self,
) -> impl for<'c> FnMut(&mut InputRef<'inp, 'c, L, Ctx, Lang, Cmpl>) -> DelimitedOf<'inp, Bracket<(), (), Lang>, L, Ctx, Lang, O>where
Self: Sized,
Bracket<(), (), Lang>: TypedDelimiter<'inp, L, Lang>,
L: Lexer<'inp>,
Ctx: ComposableParseContext<'inp, L, Lang>,
Cmpl: SurfaceIncomplete<'inp, L, Ctx, Lang>,
fn delimited_by_brackets(
self,
) -> impl for<'c> FnMut(&mut InputRef<'inp, 'c, L, Ctx, Lang, Cmpl>) -> DelimitedOf<'inp, Bracket<(), (), Lang>, L, Ctx, Lang, O>where
Self: Sized,
Bracket<(), (), Lang>: TypedDelimiter<'inp, L, Lang>,
L: Lexer<'inp>,
Ctx: ComposableParseContext<'inp, L, Lang>,
Cmpl: SurfaceIncomplete<'inp, L, Ctx, Lang>,
Bracket delimiter pair by delegating to ParseInput::delimited.Source§fn delimited_by_angles(
self,
) -> impl for<'c> FnMut(&mut InputRef<'inp, 'c, L, Ctx, Lang, Cmpl>) -> DelimitedOf<'inp, Angle<(), (), Lang>, L, Ctx, Lang, O>where
Self: Sized,
Angle<(), (), Lang>: TypedDelimiter<'inp, L, Lang>,
L: Lexer<'inp>,
Ctx: ComposableParseContext<'inp, L, Lang>,
Cmpl: SurfaceIncomplete<'inp, L, Ctx, Lang>,
fn delimited_by_angles(
self,
) -> impl for<'c> FnMut(&mut InputRef<'inp, 'c, L, Ctx, Lang, Cmpl>) -> DelimitedOf<'inp, Angle<(), (), Lang>, L, Ctx, Lang, O>where
Self: Sized,
Angle<(), (), Lang>: TypedDelimiter<'inp, L, Lang>,
L: Lexer<'inp>,
Ctx: ComposableParseContext<'inp, L, Lang>,
Cmpl: SurfaceIncomplete<'inp, L, Ctx, Lang>,
Angle delimiter pair by delegating to ParseInput::delimited.Source§fn try_delimited<D>(
self,
) -> impl for<'c> FnMut(&mut InputRef<'inp, 'c, L, Ctx, Lang, Cmpl>) -> TryDelimitedOf<'inp, D, L, Ctx, Lang, O>where
Self: Sized,
D: TypedDelimiter<'inp, L, Lang>,
L: Lexer<'inp>,
Ctx: ComposableParseContext<'inp, L, Lang>,
Cmpl: SurfaceIncomplete<'inp, L, Ctx, Lang>,
fn try_delimited<D>(
self,
) -> impl for<'c> FnMut(&mut InputRef<'inp, 'c, L, Ctx, Lang, Cmpl>) -> TryDelimitedOf<'inp, D, L, Ctx, Lang, O>where
Self: Sized,
D: TypedDelimiter<'inp, L, Lang>,
L: Lexer<'inp>,
Ctx: ComposableParseContext<'inp, L, Lang>,
Cmpl: SurfaceIncomplete<'inp, L, Ctx, Lang>,
Source§fn try_delimited_by_parens(
self,
) -> impl for<'c> FnMut(&mut InputRef<'inp, 'c, L, Ctx, Lang, Cmpl>) -> TryDelimitedOf<'inp, Paren<(), (), Lang>, L, Ctx, Lang, O>where
Self: Sized,
Paren<(), (), Lang>: TypedDelimiter<'inp, L, Lang>,
L: Lexer<'inp>,
Ctx: ComposableParseContext<'inp, L, Lang>,
Cmpl: SurfaceIncomplete<'inp, L, Ctx, Lang>,
fn try_delimited_by_parens(
self,
) -> impl for<'c> FnMut(&mut InputRef<'inp, 'c, L, Ctx, Lang, Cmpl>) -> TryDelimitedOf<'inp, Paren<(), (), Lang>, L, Ctx, Lang, O>where
Self: Sized,
Paren<(), (), Lang>: TypedDelimiter<'inp, L, Lang>,
L: Lexer<'inp>,
Ctx: ComposableParseContext<'inp, L, Lang>,
Cmpl: SurfaceIncomplete<'inp, L, Ctx, Lang>,
Paren delimiter pair by delegating to ParseInput::try_delimited. Read moreSource§fn try_delimited_by_braces(
self,
) -> impl for<'c> FnMut(&mut InputRef<'inp, 'c, L, Ctx, Lang, Cmpl>) -> TryDelimitedOf<'inp, Brace<(), (), Lang>, L, Ctx, Lang, O>where
Self: Sized,
Brace<(), (), Lang>: TypedDelimiter<'inp, L, Lang>,
L: Lexer<'inp>,
Ctx: ComposableParseContext<'inp, L, Lang>,
Cmpl: SurfaceIncomplete<'inp, L, Ctx, Lang>,
fn try_delimited_by_braces(
self,
) -> impl for<'c> FnMut(&mut InputRef<'inp, 'c, L, Ctx, Lang, Cmpl>) -> TryDelimitedOf<'inp, Brace<(), (), Lang>, L, Ctx, Lang, O>where
Self: Sized,
Brace<(), (), Lang>: TypedDelimiter<'inp, L, Lang>,
L: Lexer<'inp>,
Ctx: ComposableParseContext<'inp, L, Lang>,
Cmpl: SurfaceIncomplete<'inp, L, Ctx, Lang>,
Brace delimiter pair by delegating to ParseInput::try_delimited. Read moreSource§fn try_delimited_by_brackets(
self,
) -> impl for<'c> FnMut(&mut InputRef<'inp, 'c, L, Ctx, Lang, Cmpl>) -> TryDelimitedOf<'inp, Bracket<(), (), Lang>, L, Ctx, Lang, O>where
Self: Sized,
Bracket<(), (), Lang>: TypedDelimiter<'inp, L, Lang>,
L: Lexer<'inp>,
Ctx: ComposableParseContext<'inp, L, Lang>,
Cmpl: SurfaceIncomplete<'inp, L, Ctx, Lang>,
fn try_delimited_by_brackets(
self,
) -> impl for<'c> FnMut(&mut InputRef<'inp, 'c, L, Ctx, Lang, Cmpl>) -> TryDelimitedOf<'inp, Bracket<(), (), Lang>, L, Ctx, Lang, O>where
Self: Sized,
Bracket<(), (), Lang>: TypedDelimiter<'inp, L, Lang>,
L: Lexer<'inp>,
Ctx: ComposableParseContext<'inp, L, Lang>,
Cmpl: SurfaceIncomplete<'inp, L, Ctx, Lang>,
Bracket delimiter pair by delegating to ParseInput::try_delimited. Read moreSource§fn try_delimited_by_angles(
self,
) -> impl for<'c> FnMut(&mut InputRef<'inp, 'c, L, Ctx, Lang, Cmpl>) -> TryDelimitedOf<'inp, Angle<(), (), Lang>, L, Ctx, Lang, O>where
Self: Sized,
Angle<(), (), Lang>: TypedDelimiter<'inp, L, Lang>,
L: Lexer<'inp>,
Ctx: ComposableParseContext<'inp, L, Lang>,
Cmpl: SurfaceIncomplete<'inp, L, Ctx, Lang>,
fn try_delimited_by_angles(
self,
) -> impl for<'c> FnMut(&mut InputRef<'inp, 'c, L, Ctx, Lang, Cmpl>) -> TryDelimitedOf<'inp, Angle<(), (), Lang>, L, Ctx, Lang, O>where
Self: Sized,
Angle<(), (), Lang>: TypedDelimiter<'inp, L, Lang>,
L: Lexer<'inp>,
Ctx: ComposableParseContext<'inp, L, Lang>,
Cmpl: SurfaceIncomplete<'inp, L, Ctx, Lang>,
Angle delimiter pair by delegating to ParseInput::try_delimited. Read moreSource§fn spanned(self) -> With<PhantomSpan, Self, Cmpl>
fn spanned(self) -> With<PhantomSpan, Self, Cmpl>
Spanned with the span of the parsed input. Read moreSource§fn sliced(self) -> With<PhantomSliced, Self, Cmpl>
fn sliced(self) -> With<PhantomSliced, Self, Cmpl>
Sliced with the source slice of the parsed input. Read moreSource§fn located(self) -> With<PhantomLocated, Self, Cmpl>
fn located(self) -> With<PhantomLocated, Self, Cmpl>
Located with the span and source slice of the parsed input. Read moreSource§fn spanned_trimmed(self) -> With<Trimmed<PhantomSpan>, Self, Cmpl>
fn spanned_trimmed(self) -> With<Trimmed<PhantomSpan>, Self, Cmpl>
Spanned with the trimmed span of the parsed
input: from the start of the first token it consumes to the committed position after it. Read moreSource§fn sliced_trimmed(self) -> With<Trimmed<PhantomSliced>, Self, Cmpl>
fn sliced_trimmed(self) -> With<Trimmed<PhantomSliced>, Self, Cmpl>
Source§fn located_trimmed(self) -> With<Trimmed<PhantomLocated>, Self, Cmpl>
fn located_trimmed(self) -> With<Trimmed<PhantomLocated>, Self, Cmpl>
Source§fn ignored(self) -> Ignore<Self, O, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
Ignore<Self, O, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, (), Ctx, Lang, Cmpl>,
fn ignored(self) -> Ignore<Self, O, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
Ignore<Self, O, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, (), Ctx, Lang, Cmpl>,
Source§fn by_ref(&mut self) -> &mut ByRef<Self>
fn by_ref(&mut self) -> &mut ByRef<Self>
Source§fn fold_while<Condition, Init, Acc, W>(
self,
pred: Condition,
init: Init,
acc: Acc,
) -> FoldWhile<Self, Condition, Init, Acc, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
FoldWhile<Self, Condition, Init, Acc, O, W, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
fn fold_while<Condition, Init, Acc, W>(
self,
pred: Condition,
init: Init,
acc: Acc,
) -> FoldWhile<Self, Condition, Init, Acc, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
FoldWhile<Self, Condition, Init, Acc, O, W, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
fold only.FoldWhile combinator that accumulates results while a condition is met.Source§fn try_fold_while<Condition, Init, Acc, W>(
self,
pred: Condition,
init: Init,
acc: Acc,
) -> TryFoldWhile<Self, Condition, Init, Acc, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Init: FnMut() -> O,
Acc: FnMut(O, O) -> Result<O, <Ctx::Emitter as Emitter<'inp, L, Lang>>::Error>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
TryFoldWhile<Self, Condition, Init, Acc, O, W, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
fn try_fold_while<Condition, Init, Acc, W>(
self,
pred: Condition,
init: Init,
acc: Acc,
) -> TryFoldWhile<Self, Condition, Init, Acc, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Init: FnMut() -> O,
Acc: FnMut(O, O) -> Result<O, <Ctx::Emitter as Emitter<'inp, L, Lang>>::Error>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
TryFoldWhile<Self, Condition, Init, Acc, O, W, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
fold only.TryFoldWhile combinator that accumulates results while a condition is met. Read moreSource§fn try_fold_while_with<Condition, Init, Acc, W>(
self,
pred: Condition,
init: Init,
acc: Acc,
) -> TryFoldWhileWith<Self, Condition, Init, Acc, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Init: FnMut() -> O,
Acc: FnMut(O, O, ParseState<'_, 'inp, '_, L, Ctx, Lang, Cmpl>) -> Result<O, <Ctx::Emitter as Emitter<'inp, L, Lang>>::Error>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
TryFoldWhileWith<Self, Condition, Init, Acc, O, W, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
fn try_fold_while_with<Condition, Init, Acc, W>(
self,
pred: Condition,
init: Init,
acc: Acc,
) -> TryFoldWhileWith<Self, Condition, Init, Acc, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Init: FnMut() -> O,
Acc: FnMut(O, O, ParseState<'_, 'inp, '_, L, Ctx, Lang, Cmpl>) -> Result<O, <Ctx::Emitter as Emitter<'inp, L, Lang>>::Error>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
TryFoldWhileWith<Self, Condition, Init, Acc, O, W, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
fold only.TryFoldWhileWith combinator that accumulates results while a condition is met,
with access to parsing state.Source§fn rfold_while<Condition, Init, Acc, W>(
self,
condition: Condition,
init: Init,
acc: Acc,
) -> RFoldWhile<Self, Condition, Init, Acc, L, O, W, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Init: FnMut() -> O,
Acc: FnMut(O, O) -> O,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
RFoldWhile<Self, Condition, Init, Acc, L, O, W, Ctx, Lang, Cmpl>: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
fn rfold_while<Condition, Init, Acc, W>(
self,
condition: Condition,
init: Init,
acc: Acc,
) -> RFoldWhile<Self, Condition, Init, Acc, L, O, W, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Init: FnMut() -> O,
Acc: FnMut(O, O) -> O,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
RFoldWhile<Self, Condition, Init, Acc, L, O, W, Ctx, Lang, Cmpl>: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
fold and (crate features alloc or std) only.RFoldWhile combinator that applies this parser repeatedly,
while a condition is met, and folds results in reverse order. Read moreSource§fn repeated_while<Condition, W>(
self,
condition: Condition,
) -> RepeatedWhile<Self, Condition, O, W, L, Ctx, Lang, Cmpl>
fn repeated_while<Condition, W>( self, condition: Condition, ) -> RepeatedWhile<Self, Condition, O, W, L, Ctx, Lang, Cmpl>
many only.RepeatedWhile combinator that applies this parser repeatedly, where you
provide the lookahead logic. Read moreSource§fn separated_while<Sep, Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Sep, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
Sep: Punctuator<'inp, L, Lang>,
W: Window,
fn separated_while<Sep, Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Sep, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
Sep: Punctuator<'inp, L, Lang>,
W: Window,
many only.SeparatedWhile combinator that parses separated elements, where you
provide the lookahead logic. Read moreSource§fn separated_by_comma_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Comma<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
fn separated_by_comma_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Comma<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
many only.SeparatedWhile combinator which separates elements by the comma separator and applies this parser repeatedly. Read moreSource§fn separated_by_semicolon_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Semicolon<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
fn separated_by_semicolon_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Semicolon<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
many only.SeparatedWhile combinator which separates elements by the semicolon separator and applies this parser repeatedly. Read moreSource§fn separated_by_dot_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Dot<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
fn separated_by_dot_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Dot<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
many only.SeparatedWhile combinator which separates elements by the dot separator and applies this parser repeatedly. Read moreSource§fn separated_by_colon_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Colon<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
fn separated_by_colon_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Colon<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
many only.SeparatedWhile combinator which separates elements by the colon separator and applies this parser repeatedly. Read moreSource§fn separated_by_pipe_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Pipe<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
fn separated_by_pipe_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Pipe<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
many only.SeparatedWhile combinator which separates elements by the pipe separator and applies this parser repeatedly. Read moreSource§fn separated_by_ampersand_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Ampersand<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
fn separated_by_ampersand_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Ampersand<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
many only.SeparatedWhile combinator which separates elements by the ampersand separator and applies this parser repeatedly. Read moreSource§fn separated_by_hyphen_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Hyphen<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
fn separated_by_hyphen_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Hyphen<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
many only.SeparatedWhile combinator which separates elements by the hyphen separator and applies this parser repeatedly. Read moreSource§fn separated_by_underscore_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Underscore<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
fn separated_by_underscore_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Underscore<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
many only.SeparatedWhile combinator which separates elements by the underscore separator and applies this parser repeatedly. Read moreSource§fn separated_by_double_colon_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, DoubleColon<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
fn separated_by_double_colon_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, DoubleColon<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
many only.SeparatedWhile combinator which separates elements by the double_colon separator and applies this parser repeatedly. Read moreSource§fn separated_by_arrow_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Arrow<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
fn separated_by_arrow_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Arrow<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
many only.SeparatedWhile combinator which separates elements by the arrow separator and applies this parser repeatedly. Read moreSource§fn separated_by_fat_arrow_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, FatArrow<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
fn separated_by_fat_arrow_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, FatArrow<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
many only.SeparatedWhile combinator which separates elements by the fat_arrow separator and applies this parser repeatedly. Read moreSource§fn separated_by_tilde_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Tilde<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
fn separated_by_tilde_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Tilde<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
many only.SeparatedWhile combinator which separates elements by the tilde separator and applies this parser repeatedly. Read moreSource§fn separated_by_slash_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Slash<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
fn separated_by_slash_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Slash<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
many only.SeparatedWhile combinator which separates elements by the slash separator and applies this parser repeatedly. Read moreSource§fn separated_by_backslash_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Backslash<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
fn separated_by_backslash_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Backslash<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
many only.SeparatedWhile combinator which separates elements by the backslash separator and applies this parser repeatedly. Read moreSource§fn separated_by_percent_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Percent<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
fn separated_by_percent_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Percent<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
many only.SeparatedWhile combinator which separates elements by the percent separator and applies this parser repeatedly. Read moreSource§fn separated_by_dollar_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Dollar<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
fn separated_by_dollar_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Dollar<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
many only.SeparatedWhile combinator which separates elements by the dollar separator and applies this parser repeatedly. Read moreSource§fn separated_by_hash_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Hash<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
fn separated_by_hash_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Hash<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
many only.SeparatedWhile combinator which separates elements by the hash separator and applies this parser repeatedly. Read moreSource§fn separated_by_at_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, At<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
fn separated_by_at_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, At<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
many only.SeparatedWhile combinator which separates elements by the at separator and applies this parser repeatedly. Read moreSource§fn labelled(self, name: &'static str) -> Labelled<Self>where
Self: Sized,
fn labelled(self, name: &'static str) -> Labelled<Self>where
Self: Sized,
labelled.Source§fn traced(self, name: &'static str) -> Traced<Self>where
Self: Sized,
fn traced(self, name: &'static str) -> Traced<Self>where
Self: Sized,
trace only.traced.Source§fn list_until<Until>(
self,
until: Until,
) -> impl for<'c> FnMut(&mut InputRef<'inp, 'c, L, Ctx, Lang>) -> ListOf<'inp, L, Ctx, Lang, O>where
Self: Sized + ParseInput<'inp, L, O, Ctx, Lang>,
L: Lexer<'inp>,
Ctx: ComposableParseContext<'inp, L, Lang>,
Until: FnMut(&L::Token) -> bool,
fn list_until<Until>(
self,
until: Until,
) -> impl for<'c> FnMut(&mut InputRef<'inp, 'c, L, Ctx, Lang>) -> ListOf<'inp, L, Ctx, Lang, O>where
Self: Sized + ParseInput<'inp, L, O, Ctx, Lang>,
L: Lexer<'inp>,
Ctx: ComposableParseContext<'inp, L, Lang>,
Until: FnMut(&L::Token) -> bool,
many and (crate features alloc or std) only.Source§fn separated1_by<Sep, Peek>(
self,
peek: Peek,
) -> impl for<'c> FnMut(&mut InputRef<'inp, 'c, L, Ctx, Lang>) -> Separated1Of<'inp, L, Ctx, Lang, O>where
Self: Sized + ParseInput<'inp, L, O, Ctx, Lang>,
L: Lexer<'inp>,
Ctx: ComposableParseContext<'inp, L, Lang>,
Sep: Punctuator<'inp, L, Lang>,
Peek: FnMut(&L::Token) -> bool,
fn separated1_by<Sep, Peek>(
self,
peek: Peek,
) -> impl for<'c> FnMut(&mut InputRef<'inp, 'c, L, Ctx, Lang>) -> Separated1Of<'inp, L, Ctx, Lang, O>where
Self: Sized + ParseInput<'inp, L, O, Ctx, Lang>,
L: Lexer<'inp>,
Ctx: ComposableParseContext<'inp, L, Lang>,
Sep: Punctuator<'inp, L, Lang>,
Peek: FnMut(&L::Token) -> bool,
many and (crate features alloc or std) only.separated1 — the
committed-first “light” list shape, fluent. Read moreSource§fn peek_then<C, W>(self, condition: C) -> PeekThen<Self, C, L::Token, W, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
C: FnMut(Peeked<'_, 'inp, L, W>, EmitterView<'_, 'inp, L, Ctx::Emitter, Lang>) -> Result<(), <Ctx::Emitter as Emitter<'inp, L, Lang>>::Error>,
W: Window,
PeekThen<Self, C, L::Token, W, Cmpl>: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
fn peek_then<C, W>(self, condition: C) -> PeekThen<Self, C, L::Token, W, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
C: FnMut(Peeked<'_, 'inp, L, W>, EmitterView<'_, 'inp, L, Ctx::Emitter, Lang>) -> Result<(), <Ctx::Emitter as Emitter<'inp, L, Lang>>::Error>,
W: Window,
PeekThen<Self, C, L::Token, W, Cmpl>: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
peek only.PeekThen combinator that peeks at most N tokens first from the input before parsing. Read moreSource§fn peek_then_try<C, W>(
self,
condition: C,
) -> PeekThen<Self, C, L::Token, W, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
C: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
PeekThen<Self, C, L::Token, W, Cmpl>: TryParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
fn peek_then_try<C, W>(
self,
condition: C,
) -> PeekThen<Self, C, L::Token, W, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
C: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
PeekThen<Self, C, L::Token, W, Cmpl>: TryParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
peek only.PeekThen combinator that peeks at most N tokens first from the input before parsing. Read moreSource§fn peek_then_head<C>(
self,
condition: C,
) -> PeekThen<Self, impl FnMut(Peeked<'_, 'inp, L, U1>, EmitterView<'_, 'inp, L, Ctx::Emitter, Lang>) -> Result<(), <Ctx::Emitter as Emitter<'inp, L, Lang>>::Error>, L::Token, U1, Cmpl>
fn peek_then_head<C>( self, condition: C, ) -> PeekThen<Self, impl FnMut(Peeked<'_, 'inp, L, U1>, EmitterView<'_, 'inp, L, Ctx::Emitter, Lang>) -> Result<(), <Ctx::Emitter as Emitter<'inp, L, Lang>>::Error>, L::Token, U1, Cmpl>
peek only.Source§fn map<U, F>(self, f: F) -> Map<Self, F, L, Ctx, O, U, Lang, Cmpl>where
Self: Sized,
F: FnMut(O) -> U,
L: Lexer<'inp>,
Map<Self, F, L, Ctx, O, U, Lang, Cmpl>: ParseInput<'inp, L, U, Ctx, Lang, Cmpl>,
fn map<U, F>(self, f: F) -> Map<Self, F, L, Ctx, O, U, Lang, Cmpl>where
Self: Sized,
F: FnMut(O) -> U,
L: Lexer<'inp>,
Map<Self, F, L, Ctx, O, U, Lang, Cmpl>: ParseInput<'inp, L, U, Ctx, Lang, Cmpl>,
map only.Source§fn map_with<U, F>(self, f: F) -> MapWith<Self, F, L, Ctx, O, U, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
F: FnMut(O, ParseState<'_, 'inp, '_, L, Ctx, Lang, Cmpl>) -> U,
MapWith<Self, F, L, Ctx, O, U, Lang, Cmpl>: ParseInput<'inp, L, U, Ctx, Lang, Cmpl>,
fn map_with<U, F>(self, f: F) -> MapWith<Self, F, L, Ctx, O, U, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
F: FnMut(O, ParseState<'_, 'inp, '_, L, Ctx, Lang, Cmpl>) -> U,
MapWith<Self, F, L, Ctx, O, U, Lang, Cmpl>: ParseInput<'inp, L, U, Ctx, Lang, Cmpl>,
map only.Source§fn filter<F>(self, validator: F) -> Filter<Self, F, O, L, Ctx, Lang, Cmpl>
fn filter<F>(self, validator: F) -> Filter<Self, F, O, L, Ctx, Lang, Cmpl>
filter only.Source§fn filter_with<F>(
self,
validator: F,
) -> FilterWith<Self, F, O, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
F: FnMut(&O, ParseState<'_, 'inp, '_, L, Ctx, Lang, Cmpl>) -> Result<(), <Ctx::Emitter as Emitter<'inp, L, Lang>>::Error>,
Ctx: ParseContext<'inp, L, Lang>,
FilterWith<Self, F, O, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
fn filter_with<F>(
self,
validator: F,
) -> FilterWith<Self, F, O, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
F: FnMut(&O, ParseState<'_, 'inp, '_, L, Ctx, Lang, Cmpl>) -> Result<(), <Ctx::Emitter as Emitter<'inp, L, Lang>>::Error>,
Ctx: ParseContext<'inp, L, Lang>,
FilterWith<Self, F, O, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
filter only.Source§fn filter_map<U, F>(
self,
mapper: F,
) -> FilterMap<Self, F, O, U, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
F: FnMut(O) -> Result<U, <Ctx::Emitter as Emitter<'inp, L, Lang>>::Error>,
Ctx: ParseContext<'inp, L, Lang>,
FilterMap<Self, F, O, U, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, U, Ctx, Lang, Cmpl>,
fn filter_map<U, F>(
self,
mapper: F,
) -> FilterMap<Self, F, O, U, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
F: FnMut(O) -> Result<U, <Ctx::Emitter as Emitter<'inp, L, Lang>>::Error>,
Ctx: ParseContext<'inp, L, Lang>,
FilterMap<Self, F, O, U, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, U, Ctx, Lang, Cmpl>,
filter only.Source§fn filter_map_with<U, F>(
self,
mapper: F,
) -> FilterMapWith<Self, F, O, U, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
F: FnMut(O, ParseState<'_, 'inp, '_, L, Ctx, Lang, Cmpl>) -> Result<U, <Ctx::Emitter as Emitter<'inp, L, Lang>>::Error>,
Ctx: ParseContext<'inp, L, Lang>,
FilterMapWith<Self, F, O, U, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, U, Ctx, Lang, Cmpl>,
fn filter_map_with<U, F>(
self,
mapper: F,
) -> FilterMapWith<Self, F, O, U, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
F: FnMut(O, ParseState<'_, 'inp, '_, L, Ctx, Lang, Cmpl>) -> Result<U, <Ctx::Emitter as Emitter<'inp, L, Lang>>::Error>,
Ctx: ParseContext<'inp, L, Lang>,
FilterMapWith<Self, F, O, U, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, U, Ctx, Lang, Cmpl>,
filter only.Source§fn validate<F>(self, validator: F) -> Validate<Self, F, O, L, Ctx, Lang, Cmpl>
fn validate<F>(self, validator: F) -> Validate<Self, F, O, L, Ctx, Lang, Cmpl>
validate only.Source§fn validate_with<F>(
self,
validator: F,
) -> ValidateWith<Self, F, O, L, Ctx, Lang, Cmpl>
fn validate_with<F>( self, validator: F, ) -> ValidateWith<Self, F, O, L, Ctx, Lang, Cmpl>
validate only.Source§fn then_ignore<G, U>(
self,
second: G,
) -> ThenIgnore<Self, G, O, U, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
G: ParseInput<'inp, L, U, Ctx, Lang, Cmpl>,
Ctx: ParseContext<'inp, L, Lang>,
ThenIgnore<Self, G, O, U, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
fn then_ignore<G, U>(
self,
second: G,
) -> ThenIgnore<Self, G, O, U, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
G: ParseInput<'inp, L, U, Ctx, Lang, Cmpl>,
Ctx: ParseContext<'inp, L, Lang>,
ThenIgnore<Self, G, O, U, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
then only.Source§fn then_value<F, U>(
self,
value: F,
) -> ThenValue<Self, F, O, U, L, Ctx, Lang, Cmpl>
fn then_value<F, U>( self, value: F, ) -> ThenValue<Self, F, O, U, L, Ctx, Lang, Cmpl>
then only.Source§fn and_then<T, U>(self, then: T) -> AndThen<Self, T, O, U, L, Ctx, Lang, Cmpl>where
Self: Sized,
T: FnMut(O) -> Result<U, <Ctx::Emitter as Emitter<'inp, L, Lang>>::Error>,
L: Lexer<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
AndThen<Self, T, O, U, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, U, Ctx, Lang, Cmpl>,
fn and_then<T, U>(self, then: T) -> AndThen<Self, T, O, U, L, Ctx, Lang, Cmpl>where
Self: Sized,
T: FnMut(O) -> Result<U, <Ctx::Emitter as Emitter<'inp, L, Lang>>::Error>,
L: Lexer<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
AndThen<Self, T, O, U, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, U, Ctx, Lang, Cmpl>,
then only.Source§fn and_then_with<T, U>(
self,
then: T,
) -> AndThenWith<Self, T, O, U, L, Ctx, Lang, Cmpl>where
Self: Sized,
T: FnMut(O, ParseState<'_, 'inp, '_, L, Ctx, Lang, Cmpl>) -> Result<U, <Ctx::Emitter as Emitter<'inp, L, Lang>>::Error>,
Ctx: ParseContext<'inp, L, Lang>,
L: Lexer<'inp>,
AndThenWith<Self, T, O, U, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, U, Ctx, Lang, Cmpl>,
fn and_then_with<T, U>(
self,
then: T,
) -> AndThenWith<Self, T, O, U, L, Ctx, Lang, Cmpl>where
Self: Sized,
T: FnMut(O, ParseState<'_, 'inp, '_, L, Ctx, Lang, Cmpl>) -> Result<U, <Ctx::Emitter as Emitter<'inp, L, Lang>>::Error>,
Ctx: ParseContext<'inp, L, Lang>,
L: Lexer<'inp>,
AndThenWith<Self, T, O, U, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, U, Ctx, Lang, Cmpl>,
then only.Source§fn then<T, U>(self, then: T) -> Then<Self, T, O, U, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
T: ParseInput<'inp, L, U, Ctx, Lang, Cmpl>,
Ctx: ParseContext<'inp, L, Lang>,
Then<Self, T, O, U, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, (O, U), Ctx, Lang, Cmpl>,
fn then<T, U>(self, then: T) -> Then<Self, T, O, U, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
T: ParseInput<'inp, L, U, Ctx, Lang, Cmpl>,
Ctx: ParseContext<'inp, L, Lang>,
Then<Self, T, O, U, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, (O, U), Ctx, Lang, Cmpl>,
then only.Source§fn ignore_then<G, U>(
self,
second: G,
) -> IgnoreThen<Self, G, O, U, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
G: ParseInput<'inp, L, U, Ctx, Lang, Cmpl>,
IgnoreThen<Self, G, O, U, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, U, Ctx, Lang, Cmpl>,
fn ignore_then<G, U>(
self,
second: G,
) -> IgnoreThen<Self, G, O, U, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
G: ParseInput<'inp, L, U, Ctx, Lang, Cmpl>,
IgnoreThen<Self, G, O, U, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, U, Ctx, Lang, Cmpl>,
then only.Source§fn recover<R>(self, recovery: R) -> Recover<Self, R, O, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
R: RecoverInput<'inp, L, O, Ctx, Lang, Cmpl>,
Ctx: ParseContext<'inp, L, Lang>,
Recover<Self, R, O, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
fn recover<R>(self, recovery: R) -> Recover<Self, R, O, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
R: RecoverInput<'inp, L, O, Ctx, Lang, Cmpl>,
Ctx: ParseContext<'inp, L, Lang>,
Recover<Self, R, O, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
Source§fn inplace_recover<R>(
self,
recovery: R,
) -> InplaceRecover<Self, R, O, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
R: InplaceRecoverInput<'inp, L, O, Ctx, Lang, Cmpl>,
Ctx: ParseContext<'inp, L, Lang>,
InplaceRecover<Self, R, O, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
fn inplace_recover<R>(
self,
recovery: R,
) -> InplaceRecover<Self, R, O, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
R: InplaceRecoverInput<'inp, L, O, Ctx, Lang, Cmpl>,
Ctx: ParseContext<'inp, L, Lang>,
InplaceRecover<Self, R, O, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
Source§fn skip_then_retry<D, F>(
self,
classifier: D,
pred: F,
) -> SkipThenRetry<Self, D, F, O, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
D: DelimClass<<L::Token as Token<'inp>>::Kind>,
F: FnMut(Spanned<&L::Token, &L::Span>) -> bool,
Ctx: ParseContext<'inp, L, Lang>,
SkipThenRetry<Self, D, F, O, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
fn skip_then_retry<D, F>(
self,
classifier: D,
pred: F,
) -> SkipThenRetry<Self, D, F, O, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
D: DelimClass<<L::Token as Token<'inp>>::Kind>,
F: FnMut(Spanned<&L::Token, &L::Span>) -> bool,
Ctx: ParseContext<'inp, L, Lang>,
SkipThenRetry<Self, D, F, O, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
Source§fn padded(self) -> Padded<Self, O, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
Padded<Self, O, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
fn padded(self) -> Padded<Self, O, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
Padded<Self, O, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
Source§fn padded_left(self) -> PaddedLeft<Self, O, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
PaddedLeft<Self, O, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
fn padded_left(self) -> PaddedLeft<Self, O, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
PaddedLeft<Self, O, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
Source§fn padded_right(self) -> PaddedRight<Self, O, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
PaddedRight<Self, O, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
fn padded_right(self) -> PaddedRight<Self, O, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
PaddedRight<Self, O, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
Source§impl<'inp, L, Ctx, Lang: ?Sized, Cmpl> ParseInput<'inp, L, Located<<L as Lexer<'inp>>::Token, <L as Lexer<'inp>>::Span, <<L as Lexer<'inp>>::Source as Source<<L as Lexer<'inp>>::Offset>>::Slice<'inp>>, Ctx, Lang, Cmpl> for With<Any<L, Ctx, Lang>, PhantomLocated>where
L: Lexer<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
<Ctx::Emitter as Emitter<'inp, L, Lang>>::Error: From<UnexpectedEot<L::Offset, Lang>> + From<<L::Token as Token<'inp>>::Error>,
Cmpl: SurfaceIncomplete<'inp, L, Ctx, Lang>,
Available on crate feature any only.
impl<'inp, L, Ctx, Lang: ?Sized, Cmpl> ParseInput<'inp, L, Located<<L as Lexer<'inp>>::Token, <L as Lexer<'inp>>::Span, <<L as Lexer<'inp>>::Source as Source<<L as Lexer<'inp>>::Offset>>::Slice<'inp>>, Ctx, Lang, Cmpl> for With<Any<L, Ctx, Lang>, PhantomLocated>where
L: Lexer<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
<Ctx::Emitter as Emitter<'inp, L, Lang>>::Error: From<UnexpectedEot<L::Offset, Lang>> + From<<L::Token as Token<'inp>>::Error>,
Cmpl: SurfaceIncomplete<'inp, L, Ctx, Lang>,
any only.Source§fn parse_input(
&mut self,
inp: &mut InputRef<'inp, '_, L, Ctx, Lang, Cmpl>,
) -> Result<Located<L::Token, L::Span, <L::Source as Source<L::Offset>>::Slice<'inp>>, <Ctx::Emitter as Emitter<'inp, L, Lang>>::Error>where
Ctx: ParseContext<'inp, L, Lang>,
fn parse_input(
&mut self,
inp: &mut InputRef<'inp, '_, L, Ctx, Lang, Cmpl>,
) -> Result<Located<L::Token, L::Span, <L::Source as Source<L::Offset>>::Slice<'inp>>, <Ctx::Emitter as Emitter<'inp, L, Lang>>::Error>where
Ctx: ParseContext<'inp, L, Lang>,
Source§fn delimited<D>(
self,
) -> impl for<'c> FnMut(&mut InputRef<'inp, 'c, L, Ctx, Lang, Cmpl>) -> DelimitedOf<'inp, D, L, Ctx, Lang, O>where
Self: Sized,
D: TypedDelimiter<'inp, L, Lang>,
L: Lexer<'inp>,
Ctx: ComposableParseContext<'inp, L, Lang>,
Cmpl: SurfaceIncomplete<'inp, L, Ctx, Lang>,
fn delimited<D>(
self,
) -> impl for<'c> FnMut(&mut InputRef<'inp, 'c, L, Ctx, Lang, Cmpl>) -> DelimitedOf<'inp, D, L, Ctx, Lang, O>where
Self: Sized,
D: TypedDelimiter<'inp, L, Lang>,
L: Lexer<'inp>,
Ctx: ComposableParseContext<'inp, L, Lang>,
Cmpl: SurfaceIncomplete<'inp, L, Ctx, Lang>,
Source§fn delimited_by_parens(
self,
) -> impl for<'c> FnMut(&mut InputRef<'inp, 'c, L, Ctx, Lang, Cmpl>) -> DelimitedOf<'inp, Paren<(), (), Lang>, L, Ctx, Lang, O>where
Self: Sized,
Paren<(), (), Lang>: TypedDelimiter<'inp, L, Lang>,
L: Lexer<'inp>,
Ctx: ComposableParseContext<'inp, L, Lang>,
Cmpl: SurfaceIncomplete<'inp, L, Ctx, Lang>,
fn delimited_by_parens(
self,
) -> impl for<'c> FnMut(&mut InputRef<'inp, 'c, L, Ctx, Lang, Cmpl>) -> DelimitedOf<'inp, Paren<(), (), Lang>, L, Ctx, Lang, O>where
Self: Sized,
Paren<(), (), Lang>: TypedDelimiter<'inp, L, Lang>,
L: Lexer<'inp>,
Ctx: ComposableParseContext<'inp, L, Lang>,
Cmpl: SurfaceIncomplete<'inp, L, Ctx, Lang>,
Paren delimiter pair by delegating to ParseInput::delimited.Source§fn delimited_by_braces(
self,
) -> impl for<'c> FnMut(&mut InputRef<'inp, 'c, L, Ctx, Lang, Cmpl>) -> DelimitedOf<'inp, Brace<(), (), Lang>, L, Ctx, Lang, O>where
Self: Sized,
Brace<(), (), Lang>: TypedDelimiter<'inp, L, Lang>,
L: Lexer<'inp>,
Ctx: ComposableParseContext<'inp, L, Lang>,
Cmpl: SurfaceIncomplete<'inp, L, Ctx, Lang>,
fn delimited_by_braces(
self,
) -> impl for<'c> FnMut(&mut InputRef<'inp, 'c, L, Ctx, Lang, Cmpl>) -> DelimitedOf<'inp, Brace<(), (), Lang>, L, Ctx, Lang, O>where
Self: Sized,
Brace<(), (), Lang>: TypedDelimiter<'inp, L, Lang>,
L: Lexer<'inp>,
Ctx: ComposableParseContext<'inp, L, Lang>,
Cmpl: SurfaceIncomplete<'inp, L, Ctx, Lang>,
Brace delimiter pair by delegating to ParseInput::delimited.Source§fn delimited_by_brackets(
self,
) -> impl for<'c> FnMut(&mut InputRef<'inp, 'c, L, Ctx, Lang, Cmpl>) -> DelimitedOf<'inp, Bracket<(), (), Lang>, L, Ctx, Lang, O>where
Self: Sized,
Bracket<(), (), Lang>: TypedDelimiter<'inp, L, Lang>,
L: Lexer<'inp>,
Ctx: ComposableParseContext<'inp, L, Lang>,
Cmpl: SurfaceIncomplete<'inp, L, Ctx, Lang>,
fn delimited_by_brackets(
self,
) -> impl for<'c> FnMut(&mut InputRef<'inp, 'c, L, Ctx, Lang, Cmpl>) -> DelimitedOf<'inp, Bracket<(), (), Lang>, L, Ctx, Lang, O>where
Self: Sized,
Bracket<(), (), Lang>: TypedDelimiter<'inp, L, Lang>,
L: Lexer<'inp>,
Ctx: ComposableParseContext<'inp, L, Lang>,
Cmpl: SurfaceIncomplete<'inp, L, Ctx, Lang>,
Bracket delimiter pair by delegating to ParseInput::delimited.Source§fn delimited_by_angles(
self,
) -> impl for<'c> FnMut(&mut InputRef<'inp, 'c, L, Ctx, Lang, Cmpl>) -> DelimitedOf<'inp, Angle<(), (), Lang>, L, Ctx, Lang, O>where
Self: Sized,
Angle<(), (), Lang>: TypedDelimiter<'inp, L, Lang>,
L: Lexer<'inp>,
Ctx: ComposableParseContext<'inp, L, Lang>,
Cmpl: SurfaceIncomplete<'inp, L, Ctx, Lang>,
fn delimited_by_angles(
self,
) -> impl for<'c> FnMut(&mut InputRef<'inp, 'c, L, Ctx, Lang, Cmpl>) -> DelimitedOf<'inp, Angle<(), (), Lang>, L, Ctx, Lang, O>where
Self: Sized,
Angle<(), (), Lang>: TypedDelimiter<'inp, L, Lang>,
L: Lexer<'inp>,
Ctx: ComposableParseContext<'inp, L, Lang>,
Cmpl: SurfaceIncomplete<'inp, L, Ctx, Lang>,
Angle delimiter pair by delegating to ParseInput::delimited.Source§fn try_delimited<D>(
self,
) -> impl for<'c> FnMut(&mut InputRef<'inp, 'c, L, Ctx, Lang, Cmpl>) -> TryDelimitedOf<'inp, D, L, Ctx, Lang, O>where
Self: Sized,
D: TypedDelimiter<'inp, L, Lang>,
L: Lexer<'inp>,
Ctx: ComposableParseContext<'inp, L, Lang>,
Cmpl: SurfaceIncomplete<'inp, L, Ctx, Lang>,
fn try_delimited<D>(
self,
) -> impl for<'c> FnMut(&mut InputRef<'inp, 'c, L, Ctx, Lang, Cmpl>) -> TryDelimitedOf<'inp, D, L, Ctx, Lang, O>where
Self: Sized,
D: TypedDelimiter<'inp, L, Lang>,
L: Lexer<'inp>,
Ctx: ComposableParseContext<'inp, L, Lang>,
Cmpl: SurfaceIncomplete<'inp, L, Ctx, Lang>,
Source§fn try_delimited_by_parens(
self,
) -> impl for<'c> FnMut(&mut InputRef<'inp, 'c, L, Ctx, Lang, Cmpl>) -> TryDelimitedOf<'inp, Paren<(), (), Lang>, L, Ctx, Lang, O>where
Self: Sized,
Paren<(), (), Lang>: TypedDelimiter<'inp, L, Lang>,
L: Lexer<'inp>,
Ctx: ComposableParseContext<'inp, L, Lang>,
Cmpl: SurfaceIncomplete<'inp, L, Ctx, Lang>,
fn try_delimited_by_parens(
self,
) -> impl for<'c> FnMut(&mut InputRef<'inp, 'c, L, Ctx, Lang, Cmpl>) -> TryDelimitedOf<'inp, Paren<(), (), Lang>, L, Ctx, Lang, O>where
Self: Sized,
Paren<(), (), Lang>: TypedDelimiter<'inp, L, Lang>,
L: Lexer<'inp>,
Ctx: ComposableParseContext<'inp, L, Lang>,
Cmpl: SurfaceIncomplete<'inp, L, Ctx, Lang>,
Paren delimiter pair by delegating to ParseInput::try_delimited. Read moreSource§fn try_delimited_by_braces(
self,
) -> impl for<'c> FnMut(&mut InputRef<'inp, 'c, L, Ctx, Lang, Cmpl>) -> TryDelimitedOf<'inp, Brace<(), (), Lang>, L, Ctx, Lang, O>where
Self: Sized,
Brace<(), (), Lang>: TypedDelimiter<'inp, L, Lang>,
L: Lexer<'inp>,
Ctx: ComposableParseContext<'inp, L, Lang>,
Cmpl: SurfaceIncomplete<'inp, L, Ctx, Lang>,
fn try_delimited_by_braces(
self,
) -> impl for<'c> FnMut(&mut InputRef<'inp, 'c, L, Ctx, Lang, Cmpl>) -> TryDelimitedOf<'inp, Brace<(), (), Lang>, L, Ctx, Lang, O>where
Self: Sized,
Brace<(), (), Lang>: TypedDelimiter<'inp, L, Lang>,
L: Lexer<'inp>,
Ctx: ComposableParseContext<'inp, L, Lang>,
Cmpl: SurfaceIncomplete<'inp, L, Ctx, Lang>,
Brace delimiter pair by delegating to ParseInput::try_delimited. Read moreSource§fn try_delimited_by_brackets(
self,
) -> impl for<'c> FnMut(&mut InputRef<'inp, 'c, L, Ctx, Lang, Cmpl>) -> TryDelimitedOf<'inp, Bracket<(), (), Lang>, L, Ctx, Lang, O>where
Self: Sized,
Bracket<(), (), Lang>: TypedDelimiter<'inp, L, Lang>,
L: Lexer<'inp>,
Ctx: ComposableParseContext<'inp, L, Lang>,
Cmpl: SurfaceIncomplete<'inp, L, Ctx, Lang>,
fn try_delimited_by_brackets(
self,
) -> impl for<'c> FnMut(&mut InputRef<'inp, 'c, L, Ctx, Lang, Cmpl>) -> TryDelimitedOf<'inp, Bracket<(), (), Lang>, L, Ctx, Lang, O>where
Self: Sized,
Bracket<(), (), Lang>: TypedDelimiter<'inp, L, Lang>,
L: Lexer<'inp>,
Ctx: ComposableParseContext<'inp, L, Lang>,
Cmpl: SurfaceIncomplete<'inp, L, Ctx, Lang>,
Bracket delimiter pair by delegating to ParseInput::try_delimited. Read moreSource§fn try_delimited_by_angles(
self,
) -> impl for<'c> FnMut(&mut InputRef<'inp, 'c, L, Ctx, Lang, Cmpl>) -> TryDelimitedOf<'inp, Angle<(), (), Lang>, L, Ctx, Lang, O>where
Self: Sized,
Angle<(), (), Lang>: TypedDelimiter<'inp, L, Lang>,
L: Lexer<'inp>,
Ctx: ComposableParseContext<'inp, L, Lang>,
Cmpl: SurfaceIncomplete<'inp, L, Ctx, Lang>,
fn try_delimited_by_angles(
self,
) -> impl for<'c> FnMut(&mut InputRef<'inp, 'c, L, Ctx, Lang, Cmpl>) -> TryDelimitedOf<'inp, Angle<(), (), Lang>, L, Ctx, Lang, O>where
Self: Sized,
Angle<(), (), Lang>: TypedDelimiter<'inp, L, Lang>,
L: Lexer<'inp>,
Ctx: ComposableParseContext<'inp, L, Lang>,
Cmpl: SurfaceIncomplete<'inp, L, Ctx, Lang>,
Angle delimiter pair by delegating to ParseInput::try_delimited. Read moreSource§fn spanned(self) -> With<PhantomSpan, Self, Cmpl>
fn spanned(self) -> With<PhantomSpan, Self, Cmpl>
Spanned with the span of the parsed input. Read moreSource§fn sliced(self) -> With<PhantomSliced, Self, Cmpl>
fn sliced(self) -> With<PhantomSliced, Self, Cmpl>
Sliced with the source slice of the parsed input. Read moreSource§fn located(self) -> With<PhantomLocated, Self, Cmpl>
fn located(self) -> With<PhantomLocated, Self, Cmpl>
Located with the span and source slice of the parsed input. Read moreSource§fn spanned_trimmed(self) -> With<Trimmed<PhantomSpan>, Self, Cmpl>
fn spanned_trimmed(self) -> With<Trimmed<PhantomSpan>, Self, Cmpl>
Spanned with the trimmed span of the parsed
input: from the start of the first token it consumes to the committed position after it. Read moreSource§fn sliced_trimmed(self) -> With<Trimmed<PhantomSliced>, Self, Cmpl>
fn sliced_trimmed(self) -> With<Trimmed<PhantomSliced>, Self, Cmpl>
Source§fn located_trimmed(self) -> With<Trimmed<PhantomLocated>, Self, Cmpl>
fn located_trimmed(self) -> With<Trimmed<PhantomLocated>, Self, Cmpl>
Source§fn ignored(self) -> Ignore<Self, O, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
Ignore<Self, O, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, (), Ctx, Lang, Cmpl>,
fn ignored(self) -> Ignore<Self, O, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
Ignore<Self, O, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, (), Ctx, Lang, Cmpl>,
Source§fn by_ref(&mut self) -> &mut ByRef<Self>
fn by_ref(&mut self) -> &mut ByRef<Self>
Source§fn fold_while<Condition, Init, Acc, W>(
self,
pred: Condition,
init: Init,
acc: Acc,
) -> FoldWhile<Self, Condition, Init, Acc, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
FoldWhile<Self, Condition, Init, Acc, O, W, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
fn fold_while<Condition, Init, Acc, W>(
self,
pred: Condition,
init: Init,
acc: Acc,
) -> FoldWhile<Self, Condition, Init, Acc, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
FoldWhile<Self, Condition, Init, Acc, O, W, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
fold only.FoldWhile combinator that accumulates results while a condition is met.Source§fn try_fold_while<Condition, Init, Acc, W>(
self,
pred: Condition,
init: Init,
acc: Acc,
) -> TryFoldWhile<Self, Condition, Init, Acc, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Init: FnMut() -> O,
Acc: FnMut(O, O) -> Result<O, <Ctx::Emitter as Emitter<'inp, L, Lang>>::Error>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
TryFoldWhile<Self, Condition, Init, Acc, O, W, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
fn try_fold_while<Condition, Init, Acc, W>(
self,
pred: Condition,
init: Init,
acc: Acc,
) -> TryFoldWhile<Self, Condition, Init, Acc, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Init: FnMut() -> O,
Acc: FnMut(O, O) -> Result<O, <Ctx::Emitter as Emitter<'inp, L, Lang>>::Error>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
TryFoldWhile<Self, Condition, Init, Acc, O, W, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
fold only.TryFoldWhile combinator that accumulates results while a condition is met. Read moreSource§fn try_fold_while_with<Condition, Init, Acc, W>(
self,
pred: Condition,
init: Init,
acc: Acc,
) -> TryFoldWhileWith<Self, Condition, Init, Acc, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Init: FnMut() -> O,
Acc: FnMut(O, O, ParseState<'_, 'inp, '_, L, Ctx, Lang, Cmpl>) -> Result<O, <Ctx::Emitter as Emitter<'inp, L, Lang>>::Error>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
TryFoldWhileWith<Self, Condition, Init, Acc, O, W, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
fn try_fold_while_with<Condition, Init, Acc, W>(
self,
pred: Condition,
init: Init,
acc: Acc,
) -> TryFoldWhileWith<Self, Condition, Init, Acc, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Init: FnMut() -> O,
Acc: FnMut(O, O, ParseState<'_, 'inp, '_, L, Ctx, Lang, Cmpl>) -> Result<O, <Ctx::Emitter as Emitter<'inp, L, Lang>>::Error>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
TryFoldWhileWith<Self, Condition, Init, Acc, O, W, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
fold only.TryFoldWhileWith combinator that accumulates results while a condition is met,
with access to parsing state.Source§fn rfold_while<Condition, Init, Acc, W>(
self,
condition: Condition,
init: Init,
acc: Acc,
) -> RFoldWhile<Self, Condition, Init, Acc, L, O, W, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Init: FnMut() -> O,
Acc: FnMut(O, O) -> O,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
RFoldWhile<Self, Condition, Init, Acc, L, O, W, Ctx, Lang, Cmpl>: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
fn rfold_while<Condition, Init, Acc, W>(
self,
condition: Condition,
init: Init,
acc: Acc,
) -> RFoldWhile<Self, Condition, Init, Acc, L, O, W, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Init: FnMut() -> O,
Acc: FnMut(O, O) -> O,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
RFoldWhile<Self, Condition, Init, Acc, L, O, W, Ctx, Lang, Cmpl>: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
fold and (crate features alloc or std) only.RFoldWhile combinator that applies this parser repeatedly,
while a condition is met, and folds results in reverse order. Read moreSource§fn repeated_while<Condition, W>(
self,
condition: Condition,
) -> RepeatedWhile<Self, Condition, O, W, L, Ctx, Lang, Cmpl>
fn repeated_while<Condition, W>( self, condition: Condition, ) -> RepeatedWhile<Self, Condition, O, W, L, Ctx, Lang, Cmpl>
many only.RepeatedWhile combinator that applies this parser repeatedly, where you
provide the lookahead logic. Read moreSource§fn separated_while<Sep, Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Sep, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
Sep: Punctuator<'inp, L, Lang>,
W: Window,
fn separated_while<Sep, Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Sep, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
Sep: Punctuator<'inp, L, Lang>,
W: Window,
many only.SeparatedWhile combinator that parses separated elements, where you
provide the lookahead logic. Read moreSource§fn separated_by_comma_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Comma<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
fn separated_by_comma_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Comma<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
many only.SeparatedWhile combinator which separates elements by the comma separator and applies this parser repeatedly. Read moreSource§fn separated_by_semicolon_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Semicolon<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
fn separated_by_semicolon_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Semicolon<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
many only.SeparatedWhile combinator which separates elements by the semicolon separator and applies this parser repeatedly. Read moreSource§fn separated_by_dot_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Dot<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
fn separated_by_dot_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Dot<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
many only.SeparatedWhile combinator which separates elements by the dot separator and applies this parser repeatedly. Read moreSource§fn separated_by_colon_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Colon<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
fn separated_by_colon_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Colon<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
many only.SeparatedWhile combinator which separates elements by the colon separator and applies this parser repeatedly. Read moreSource§fn separated_by_pipe_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Pipe<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
fn separated_by_pipe_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Pipe<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
many only.SeparatedWhile combinator which separates elements by the pipe separator and applies this parser repeatedly. Read moreSource§fn separated_by_ampersand_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Ampersand<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
fn separated_by_ampersand_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Ampersand<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
many only.SeparatedWhile combinator which separates elements by the ampersand separator and applies this parser repeatedly. Read moreSource§fn separated_by_hyphen_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Hyphen<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
fn separated_by_hyphen_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Hyphen<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
many only.SeparatedWhile combinator which separates elements by the hyphen separator and applies this parser repeatedly. Read moreSource§fn separated_by_underscore_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Underscore<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
fn separated_by_underscore_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Underscore<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
many only.SeparatedWhile combinator which separates elements by the underscore separator and applies this parser repeatedly. Read moreSource§fn separated_by_double_colon_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, DoubleColon<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
fn separated_by_double_colon_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, DoubleColon<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
many only.SeparatedWhile combinator which separates elements by the double_colon separator and applies this parser repeatedly. Read moreSource§fn separated_by_arrow_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Arrow<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
fn separated_by_arrow_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Arrow<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
many only.SeparatedWhile combinator which separates elements by the arrow separator and applies this parser repeatedly. Read moreSource§fn separated_by_fat_arrow_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, FatArrow<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
fn separated_by_fat_arrow_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, FatArrow<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
many only.SeparatedWhile combinator which separates elements by the fat_arrow separator and applies this parser repeatedly. Read moreSource§fn separated_by_tilde_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Tilde<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
fn separated_by_tilde_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Tilde<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
many only.SeparatedWhile combinator which separates elements by the tilde separator and applies this parser repeatedly. Read moreSource§fn separated_by_slash_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Slash<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
fn separated_by_slash_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Slash<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
many only.SeparatedWhile combinator which separates elements by the slash separator and applies this parser repeatedly. Read moreSource§fn separated_by_backslash_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Backslash<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
fn separated_by_backslash_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Backslash<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
many only.SeparatedWhile combinator which separates elements by the backslash separator and applies this parser repeatedly. Read moreSource§fn separated_by_percent_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Percent<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
fn separated_by_percent_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Percent<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
many only.SeparatedWhile combinator which separates elements by the percent separator and applies this parser repeatedly. Read moreSource§fn separated_by_dollar_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Dollar<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
fn separated_by_dollar_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Dollar<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
many only.SeparatedWhile combinator which separates elements by the dollar separator and applies this parser repeatedly. Read moreSource§fn separated_by_hash_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Hash<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
fn separated_by_hash_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Hash<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
many only.SeparatedWhile combinator which separates elements by the hash separator and applies this parser repeatedly. Read moreSource§fn separated_by_at_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, At<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
fn separated_by_at_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, At<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
many only.SeparatedWhile combinator which separates elements by the at separator and applies this parser repeatedly. Read moreSource§fn labelled(self, name: &'static str) -> Labelled<Self>where
Self: Sized,
fn labelled(self, name: &'static str) -> Labelled<Self>where
Self: Sized,
labelled.Source§fn traced(self, name: &'static str) -> Traced<Self>where
Self: Sized,
fn traced(self, name: &'static str) -> Traced<Self>where
Self: Sized,
trace only.traced.Source§fn list_until<Until>(
self,
until: Until,
) -> impl for<'c> FnMut(&mut InputRef<'inp, 'c, L, Ctx, Lang>) -> ListOf<'inp, L, Ctx, Lang, O>where
Self: Sized + ParseInput<'inp, L, O, Ctx, Lang>,
L: Lexer<'inp>,
Ctx: ComposableParseContext<'inp, L, Lang>,
Until: FnMut(&L::Token) -> bool,
fn list_until<Until>(
self,
until: Until,
) -> impl for<'c> FnMut(&mut InputRef<'inp, 'c, L, Ctx, Lang>) -> ListOf<'inp, L, Ctx, Lang, O>where
Self: Sized + ParseInput<'inp, L, O, Ctx, Lang>,
L: Lexer<'inp>,
Ctx: ComposableParseContext<'inp, L, Lang>,
Until: FnMut(&L::Token) -> bool,
many and (crate features alloc or std) only.Source§fn separated1_by<Sep, Peek>(
self,
peek: Peek,
) -> impl for<'c> FnMut(&mut InputRef<'inp, 'c, L, Ctx, Lang>) -> Separated1Of<'inp, L, Ctx, Lang, O>where
Self: Sized + ParseInput<'inp, L, O, Ctx, Lang>,
L: Lexer<'inp>,
Ctx: ComposableParseContext<'inp, L, Lang>,
Sep: Punctuator<'inp, L, Lang>,
Peek: FnMut(&L::Token) -> bool,
fn separated1_by<Sep, Peek>(
self,
peek: Peek,
) -> impl for<'c> FnMut(&mut InputRef<'inp, 'c, L, Ctx, Lang>) -> Separated1Of<'inp, L, Ctx, Lang, O>where
Self: Sized + ParseInput<'inp, L, O, Ctx, Lang>,
L: Lexer<'inp>,
Ctx: ComposableParseContext<'inp, L, Lang>,
Sep: Punctuator<'inp, L, Lang>,
Peek: FnMut(&L::Token) -> bool,
many and (crate features alloc or std) only.separated1 — the
committed-first “light” list shape, fluent. Read moreSource§fn peek_then<C, W>(self, condition: C) -> PeekThen<Self, C, L::Token, W, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
C: FnMut(Peeked<'_, 'inp, L, W>, EmitterView<'_, 'inp, L, Ctx::Emitter, Lang>) -> Result<(), <Ctx::Emitter as Emitter<'inp, L, Lang>>::Error>,
W: Window,
PeekThen<Self, C, L::Token, W, Cmpl>: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
fn peek_then<C, W>(self, condition: C) -> PeekThen<Self, C, L::Token, W, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
C: FnMut(Peeked<'_, 'inp, L, W>, EmitterView<'_, 'inp, L, Ctx::Emitter, Lang>) -> Result<(), <Ctx::Emitter as Emitter<'inp, L, Lang>>::Error>,
W: Window,
PeekThen<Self, C, L::Token, W, Cmpl>: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
peek only.PeekThen combinator that peeks at most N tokens first from the input before parsing. Read moreSource§fn peek_then_try<C, W>(
self,
condition: C,
) -> PeekThen<Self, C, L::Token, W, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
C: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
PeekThen<Self, C, L::Token, W, Cmpl>: TryParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
fn peek_then_try<C, W>(
self,
condition: C,
) -> PeekThen<Self, C, L::Token, W, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
C: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
PeekThen<Self, C, L::Token, W, Cmpl>: TryParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
peek only.PeekThen combinator that peeks at most N tokens first from the input before parsing. Read moreSource§fn peek_then_head<C>(
self,
condition: C,
) -> PeekThen<Self, impl FnMut(Peeked<'_, 'inp, L, U1>, EmitterView<'_, 'inp, L, Ctx::Emitter, Lang>) -> Result<(), <Ctx::Emitter as Emitter<'inp, L, Lang>>::Error>, L::Token, U1, Cmpl>
fn peek_then_head<C>( self, condition: C, ) -> PeekThen<Self, impl FnMut(Peeked<'_, 'inp, L, U1>, EmitterView<'_, 'inp, L, Ctx::Emitter, Lang>) -> Result<(), <Ctx::Emitter as Emitter<'inp, L, Lang>>::Error>, L::Token, U1, Cmpl>
peek only.Source§fn map<U, F>(self, f: F) -> Map<Self, F, L, Ctx, O, U, Lang, Cmpl>where
Self: Sized,
F: FnMut(O) -> U,
L: Lexer<'inp>,
Map<Self, F, L, Ctx, O, U, Lang, Cmpl>: ParseInput<'inp, L, U, Ctx, Lang, Cmpl>,
fn map<U, F>(self, f: F) -> Map<Self, F, L, Ctx, O, U, Lang, Cmpl>where
Self: Sized,
F: FnMut(O) -> U,
L: Lexer<'inp>,
Map<Self, F, L, Ctx, O, U, Lang, Cmpl>: ParseInput<'inp, L, U, Ctx, Lang, Cmpl>,
map only.Source§fn map_with<U, F>(self, f: F) -> MapWith<Self, F, L, Ctx, O, U, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
F: FnMut(O, ParseState<'_, 'inp, '_, L, Ctx, Lang, Cmpl>) -> U,
MapWith<Self, F, L, Ctx, O, U, Lang, Cmpl>: ParseInput<'inp, L, U, Ctx, Lang, Cmpl>,
fn map_with<U, F>(self, f: F) -> MapWith<Self, F, L, Ctx, O, U, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
F: FnMut(O, ParseState<'_, 'inp, '_, L, Ctx, Lang, Cmpl>) -> U,
MapWith<Self, F, L, Ctx, O, U, Lang, Cmpl>: ParseInput<'inp, L, U, Ctx, Lang, Cmpl>,
map only.Source§fn filter<F>(self, validator: F) -> Filter<Self, F, O, L, Ctx, Lang, Cmpl>
fn filter<F>(self, validator: F) -> Filter<Self, F, O, L, Ctx, Lang, Cmpl>
filter only.Source§fn filter_with<F>(
self,
validator: F,
) -> FilterWith<Self, F, O, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
F: FnMut(&O, ParseState<'_, 'inp, '_, L, Ctx, Lang, Cmpl>) -> Result<(), <Ctx::Emitter as Emitter<'inp, L, Lang>>::Error>,
Ctx: ParseContext<'inp, L, Lang>,
FilterWith<Self, F, O, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
fn filter_with<F>(
self,
validator: F,
) -> FilterWith<Self, F, O, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
F: FnMut(&O, ParseState<'_, 'inp, '_, L, Ctx, Lang, Cmpl>) -> Result<(), <Ctx::Emitter as Emitter<'inp, L, Lang>>::Error>,
Ctx: ParseContext<'inp, L, Lang>,
FilterWith<Self, F, O, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
filter only.Source§fn filter_map<U, F>(
self,
mapper: F,
) -> FilterMap<Self, F, O, U, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
F: FnMut(O) -> Result<U, <Ctx::Emitter as Emitter<'inp, L, Lang>>::Error>,
Ctx: ParseContext<'inp, L, Lang>,
FilterMap<Self, F, O, U, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, U, Ctx, Lang, Cmpl>,
fn filter_map<U, F>(
self,
mapper: F,
) -> FilterMap<Self, F, O, U, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
F: FnMut(O) -> Result<U, <Ctx::Emitter as Emitter<'inp, L, Lang>>::Error>,
Ctx: ParseContext<'inp, L, Lang>,
FilterMap<Self, F, O, U, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, U, Ctx, Lang, Cmpl>,
filter only.Source§fn filter_map_with<U, F>(
self,
mapper: F,
) -> FilterMapWith<Self, F, O, U, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
F: FnMut(O, ParseState<'_, 'inp, '_, L, Ctx, Lang, Cmpl>) -> Result<U, <Ctx::Emitter as Emitter<'inp, L, Lang>>::Error>,
Ctx: ParseContext<'inp, L, Lang>,
FilterMapWith<Self, F, O, U, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, U, Ctx, Lang, Cmpl>,
fn filter_map_with<U, F>(
self,
mapper: F,
) -> FilterMapWith<Self, F, O, U, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
F: FnMut(O, ParseState<'_, 'inp, '_, L, Ctx, Lang, Cmpl>) -> Result<U, <Ctx::Emitter as Emitter<'inp, L, Lang>>::Error>,
Ctx: ParseContext<'inp, L, Lang>,
FilterMapWith<Self, F, O, U, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, U, Ctx, Lang, Cmpl>,
filter only.Source§fn validate<F>(self, validator: F) -> Validate<Self, F, O, L, Ctx, Lang, Cmpl>
fn validate<F>(self, validator: F) -> Validate<Self, F, O, L, Ctx, Lang, Cmpl>
validate only.Source§fn validate_with<F>(
self,
validator: F,
) -> ValidateWith<Self, F, O, L, Ctx, Lang, Cmpl>
fn validate_with<F>( self, validator: F, ) -> ValidateWith<Self, F, O, L, Ctx, Lang, Cmpl>
validate only.Source§fn then_ignore<G, U>(
self,
second: G,
) -> ThenIgnore<Self, G, O, U, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
G: ParseInput<'inp, L, U, Ctx, Lang, Cmpl>,
Ctx: ParseContext<'inp, L, Lang>,
ThenIgnore<Self, G, O, U, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
fn then_ignore<G, U>(
self,
second: G,
) -> ThenIgnore<Self, G, O, U, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
G: ParseInput<'inp, L, U, Ctx, Lang, Cmpl>,
Ctx: ParseContext<'inp, L, Lang>,
ThenIgnore<Self, G, O, U, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
then only.Source§fn then_value<F, U>(
self,
value: F,
) -> ThenValue<Self, F, O, U, L, Ctx, Lang, Cmpl>
fn then_value<F, U>( self, value: F, ) -> ThenValue<Self, F, O, U, L, Ctx, Lang, Cmpl>
then only.Source§fn and_then<T, U>(self, then: T) -> AndThen<Self, T, O, U, L, Ctx, Lang, Cmpl>where
Self: Sized,
T: FnMut(O) -> Result<U, <Ctx::Emitter as Emitter<'inp, L, Lang>>::Error>,
L: Lexer<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
AndThen<Self, T, O, U, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, U, Ctx, Lang, Cmpl>,
fn and_then<T, U>(self, then: T) -> AndThen<Self, T, O, U, L, Ctx, Lang, Cmpl>where
Self: Sized,
T: FnMut(O) -> Result<U, <Ctx::Emitter as Emitter<'inp, L, Lang>>::Error>,
L: Lexer<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
AndThen<Self, T, O, U, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, U, Ctx, Lang, Cmpl>,
then only.Source§fn and_then_with<T, U>(
self,
then: T,
) -> AndThenWith<Self, T, O, U, L, Ctx, Lang, Cmpl>where
Self: Sized,
T: FnMut(O, ParseState<'_, 'inp, '_, L, Ctx, Lang, Cmpl>) -> Result<U, <Ctx::Emitter as Emitter<'inp, L, Lang>>::Error>,
Ctx: ParseContext<'inp, L, Lang>,
L: Lexer<'inp>,
AndThenWith<Self, T, O, U, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, U, Ctx, Lang, Cmpl>,
fn and_then_with<T, U>(
self,
then: T,
) -> AndThenWith<Self, T, O, U, L, Ctx, Lang, Cmpl>where
Self: Sized,
T: FnMut(O, ParseState<'_, 'inp, '_, L, Ctx, Lang, Cmpl>) -> Result<U, <Ctx::Emitter as Emitter<'inp, L, Lang>>::Error>,
Ctx: ParseContext<'inp, L, Lang>,
L: Lexer<'inp>,
AndThenWith<Self, T, O, U, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, U, Ctx, Lang, Cmpl>,
then only.Source§fn then<T, U>(self, then: T) -> Then<Self, T, O, U, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
T: ParseInput<'inp, L, U, Ctx, Lang, Cmpl>,
Ctx: ParseContext<'inp, L, Lang>,
Then<Self, T, O, U, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, (O, U), Ctx, Lang, Cmpl>,
fn then<T, U>(self, then: T) -> Then<Self, T, O, U, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
T: ParseInput<'inp, L, U, Ctx, Lang, Cmpl>,
Ctx: ParseContext<'inp, L, Lang>,
Then<Self, T, O, U, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, (O, U), Ctx, Lang, Cmpl>,
then only.Source§fn ignore_then<G, U>(
self,
second: G,
) -> IgnoreThen<Self, G, O, U, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
G: ParseInput<'inp, L, U, Ctx, Lang, Cmpl>,
IgnoreThen<Self, G, O, U, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, U, Ctx, Lang, Cmpl>,
fn ignore_then<G, U>(
self,
second: G,
) -> IgnoreThen<Self, G, O, U, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
G: ParseInput<'inp, L, U, Ctx, Lang, Cmpl>,
IgnoreThen<Self, G, O, U, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, U, Ctx, Lang, Cmpl>,
then only.Source§fn recover<R>(self, recovery: R) -> Recover<Self, R, O, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
R: RecoverInput<'inp, L, O, Ctx, Lang, Cmpl>,
Ctx: ParseContext<'inp, L, Lang>,
Recover<Self, R, O, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
fn recover<R>(self, recovery: R) -> Recover<Self, R, O, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
R: RecoverInput<'inp, L, O, Ctx, Lang, Cmpl>,
Ctx: ParseContext<'inp, L, Lang>,
Recover<Self, R, O, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
Source§fn inplace_recover<R>(
self,
recovery: R,
) -> InplaceRecover<Self, R, O, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
R: InplaceRecoverInput<'inp, L, O, Ctx, Lang, Cmpl>,
Ctx: ParseContext<'inp, L, Lang>,
InplaceRecover<Self, R, O, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
fn inplace_recover<R>(
self,
recovery: R,
) -> InplaceRecover<Self, R, O, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
R: InplaceRecoverInput<'inp, L, O, Ctx, Lang, Cmpl>,
Ctx: ParseContext<'inp, L, Lang>,
InplaceRecover<Self, R, O, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
Source§fn skip_then_retry<D, F>(
self,
classifier: D,
pred: F,
) -> SkipThenRetry<Self, D, F, O, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
D: DelimClass<<L::Token as Token<'inp>>::Kind>,
F: FnMut(Spanned<&L::Token, &L::Span>) -> bool,
Ctx: ParseContext<'inp, L, Lang>,
SkipThenRetry<Self, D, F, O, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
fn skip_then_retry<D, F>(
self,
classifier: D,
pred: F,
) -> SkipThenRetry<Self, D, F, O, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
D: DelimClass<<L::Token as Token<'inp>>::Kind>,
F: FnMut(Spanned<&L::Token, &L::Span>) -> bool,
Ctx: ParseContext<'inp, L, Lang>,
SkipThenRetry<Self, D, F, O, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
Source§fn padded(self) -> Padded<Self, O, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
Padded<Self, O, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
fn padded(self) -> Padded<Self, O, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
Padded<Self, O, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
Source§fn padded_left(self) -> PaddedLeft<Self, O, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
PaddedLeft<Self, O, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
fn padded_left(self) -> PaddedLeft<Self, O, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
PaddedLeft<Self, O, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
Source§fn padded_right(self) -> PaddedRight<Self, O, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
PaddedRight<Self, O, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
fn padded_right(self) -> PaddedRight<Self, O, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
PaddedRight<Self, O, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
Source§impl<'inp, L, O, Ctx, P, Lang: ?Sized, Cmpl> ParseInput<'inp, L, Located<O, <L as Lexer<'inp>>::Span, <<L as Lexer<'inp>>::Source as Source<<L as Lexer<'inp>>::Offset>>::Slice<'inp>>, Ctx, Lang, Cmpl> for With<PhantomLocated, P, Cmpl>where
P: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
L: Lexer<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Cmpl: Completeness,
impl<'inp, L, O, Ctx, P, Lang: ?Sized, Cmpl> ParseInput<'inp, L, Located<O, <L as Lexer<'inp>>::Span, <<L as Lexer<'inp>>::Source as Source<<L as Lexer<'inp>>::Offset>>::Slice<'inp>>, Ctx, Lang, Cmpl> for With<PhantomLocated, P, Cmpl>where
P: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
L: Lexer<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Cmpl: Completeness,
Source§fn parse_input(
&mut self,
inp: &mut InputRef<'inp, '_, L, Ctx, Lang, Cmpl>,
) -> Result<Located<O, L::Span, <L::Source as Source<L::Offset>>::Slice<'inp>>, <Ctx::Emitter as Emitter<'inp, L, Lang>>::Error>
fn parse_input( &mut self, inp: &mut InputRef<'inp, '_, L, Ctx, Lang, Cmpl>, ) -> Result<Located<O, L::Span, <L::Source as Source<L::Offset>>::Slice<'inp>>, <Ctx::Emitter as Emitter<'inp, L, Lang>>::Error>
Source§fn delimited<D>(
self,
) -> impl for<'c> FnMut(&mut InputRef<'inp, 'c, L, Ctx, Lang, Cmpl>) -> DelimitedOf<'inp, D, L, Ctx, Lang, O>where
Self: Sized,
D: TypedDelimiter<'inp, L, Lang>,
L: Lexer<'inp>,
Ctx: ComposableParseContext<'inp, L, Lang>,
Cmpl: SurfaceIncomplete<'inp, L, Ctx, Lang>,
fn delimited<D>(
self,
) -> impl for<'c> FnMut(&mut InputRef<'inp, 'c, L, Ctx, Lang, Cmpl>) -> DelimitedOf<'inp, D, L, Ctx, Lang, O>where
Self: Sized,
D: TypedDelimiter<'inp, L, Lang>,
L: Lexer<'inp>,
Ctx: ComposableParseContext<'inp, L, Lang>,
Cmpl: SurfaceIncomplete<'inp, L, Ctx, Lang>,
Source§fn delimited_by_parens(
self,
) -> impl for<'c> FnMut(&mut InputRef<'inp, 'c, L, Ctx, Lang, Cmpl>) -> DelimitedOf<'inp, Paren<(), (), Lang>, L, Ctx, Lang, O>where
Self: Sized,
Paren<(), (), Lang>: TypedDelimiter<'inp, L, Lang>,
L: Lexer<'inp>,
Ctx: ComposableParseContext<'inp, L, Lang>,
Cmpl: SurfaceIncomplete<'inp, L, Ctx, Lang>,
fn delimited_by_parens(
self,
) -> impl for<'c> FnMut(&mut InputRef<'inp, 'c, L, Ctx, Lang, Cmpl>) -> DelimitedOf<'inp, Paren<(), (), Lang>, L, Ctx, Lang, O>where
Self: Sized,
Paren<(), (), Lang>: TypedDelimiter<'inp, L, Lang>,
L: Lexer<'inp>,
Ctx: ComposableParseContext<'inp, L, Lang>,
Cmpl: SurfaceIncomplete<'inp, L, Ctx, Lang>,
Paren delimiter pair by delegating to ParseInput::delimited.Source§fn delimited_by_braces(
self,
) -> impl for<'c> FnMut(&mut InputRef<'inp, 'c, L, Ctx, Lang, Cmpl>) -> DelimitedOf<'inp, Brace<(), (), Lang>, L, Ctx, Lang, O>where
Self: Sized,
Brace<(), (), Lang>: TypedDelimiter<'inp, L, Lang>,
L: Lexer<'inp>,
Ctx: ComposableParseContext<'inp, L, Lang>,
Cmpl: SurfaceIncomplete<'inp, L, Ctx, Lang>,
fn delimited_by_braces(
self,
) -> impl for<'c> FnMut(&mut InputRef<'inp, 'c, L, Ctx, Lang, Cmpl>) -> DelimitedOf<'inp, Brace<(), (), Lang>, L, Ctx, Lang, O>where
Self: Sized,
Brace<(), (), Lang>: TypedDelimiter<'inp, L, Lang>,
L: Lexer<'inp>,
Ctx: ComposableParseContext<'inp, L, Lang>,
Cmpl: SurfaceIncomplete<'inp, L, Ctx, Lang>,
Brace delimiter pair by delegating to ParseInput::delimited.Source§fn delimited_by_brackets(
self,
) -> impl for<'c> FnMut(&mut InputRef<'inp, 'c, L, Ctx, Lang, Cmpl>) -> DelimitedOf<'inp, Bracket<(), (), Lang>, L, Ctx, Lang, O>where
Self: Sized,
Bracket<(), (), Lang>: TypedDelimiter<'inp, L, Lang>,
L: Lexer<'inp>,
Ctx: ComposableParseContext<'inp, L, Lang>,
Cmpl: SurfaceIncomplete<'inp, L, Ctx, Lang>,
fn delimited_by_brackets(
self,
) -> impl for<'c> FnMut(&mut InputRef<'inp, 'c, L, Ctx, Lang, Cmpl>) -> DelimitedOf<'inp, Bracket<(), (), Lang>, L, Ctx, Lang, O>where
Self: Sized,
Bracket<(), (), Lang>: TypedDelimiter<'inp, L, Lang>,
L: Lexer<'inp>,
Ctx: ComposableParseContext<'inp, L, Lang>,
Cmpl: SurfaceIncomplete<'inp, L, Ctx, Lang>,
Bracket delimiter pair by delegating to ParseInput::delimited.Source§fn delimited_by_angles(
self,
) -> impl for<'c> FnMut(&mut InputRef<'inp, 'c, L, Ctx, Lang, Cmpl>) -> DelimitedOf<'inp, Angle<(), (), Lang>, L, Ctx, Lang, O>where
Self: Sized,
Angle<(), (), Lang>: TypedDelimiter<'inp, L, Lang>,
L: Lexer<'inp>,
Ctx: ComposableParseContext<'inp, L, Lang>,
Cmpl: SurfaceIncomplete<'inp, L, Ctx, Lang>,
fn delimited_by_angles(
self,
) -> impl for<'c> FnMut(&mut InputRef<'inp, 'c, L, Ctx, Lang, Cmpl>) -> DelimitedOf<'inp, Angle<(), (), Lang>, L, Ctx, Lang, O>where
Self: Sized,
Angle<(), (), Lang>: TypedDelimiter<'inp, L, Lang>,
L: Lexer<'inp>,
Ctx: ComposableParseContext<'inp, L, Lang>,
Cmpl: SurfaceIncomplete<'inp, L, Ctx, Lang>,
Angle delimiter pair by delegating to ParseInput::delimited.Source§fn try_delimited<D>(
self,
) -> impl for<'c> FnMut(&mut InputRef<'inp, 'c, L, Ctx, Lang, Cmpl>) -> TryDelimitedOf<'inp, D, L, Ctx, Lang, O>where
Self: Sized,
D: TypedDelimiter<'inp, L, Lang>,
L: Lexer<'inp>,
Ctx: ComposableParseContext<'inp, L, Lang>,
Cmpl: SurfaceIncomplete<'inp, L, Ctx, Lang>,
fn try_delimited<D>(
self,
) -> impl for<'c> FnMut(&mut InputRef<'inp, 'c, L, Ctx, Lang, Cmpl>) -> TryDelimitedOf<'inp, D, L, Ctx, Lang, O>where
Self: Sized,
D: TypedDelimiter<'inp, L, Lang>,
L: Lexer<'inp>,
Ctx: ComposableParseContext<'inp, L, Lang>,
Cmpl: SurfaceIncomplete<'inp, L, Ctx, Lang>,
Source§fn try_delimited_by_parens(
self,
) -> impl for<'c> FnMut(&mut InputRef<'inp, 'c, L, Ctx, Lang, Cmpl>) -> TryDelimitedOf<'inp, Paren<(), (), Lang>, L, Ctx, Lang, O>where
Self: Sized,
Paren<(), (), Lang>: TypedDelimiter<'inp, L, Lang>,
L: Lexer<'inp>,
Ctx: ComposableParseContext<'inp, L, Lang>,
Cmpl: SurfaceIncomplete<'inp, L, Ctx, Lang>,
fn try_delimited_by_parens(
self,
) -> impl for<'c> FnMut(&mut InputRef<'inp, 'c, L, Ctx, Lang, Cmpl>) -> TryDelimitedOf<'inp, Paren<(), (), Lang>, L, Ctx, Lang, O>where
Self: Sized,
Paren<(), (), Lang>: TypedDelimiter<'inp, L, Lang>,
L: Lexer<'inp>,
Ctx: ComposableParseContext<'inp, L, Lang>,
Cmpl: SurfaceIncomplete<'inp, L, Ctx, Lang>,
Paren delimiter pair by delegating to ParseInput::try_delimited. Read moreSource§fn try_delimited_by_braces(
self,
) -> impl for<'c> FnMut(&mut InputRef<'inp, 'c, L, Ctx, Lang, Cmpl>) -> TryDelimitedOf<'inp, Brace<(), (), Lang>, L, Ctx, Lang, O>where
Self: Sized,
Brace<(), (), Lang>: TypedDelimiter<'inp, L, Lang>,
L: Lexer<'inp>,
Ctx: ComposableParseContext<'inp, L, Lang>,
Cmpl: SurfaceIncomplete<'inp, L, Ctx, Lang>,
fn try_delimited_by_braces(
self,
) -> impl for<'c> FnMut(&mut InputRef<'inp, 'c, L, Ctx, Lang, Cmpl>) -> TryDelimitedOf<'inp, Brace<(), (), Lang>, L, Ctx, Lang, O>where
Self: Sized,
Brace<(), (), Lang>: TypedDelimiter<'inp, L, Lang>,
L: Lexer<'inp>,
Ctx: ComposableParseContext<'inp, L, Lang>,
Cmpl: SurfaceIncomplete<'inp, L, Ctx, Lang>,
Brace delimiter pair by delegating to ParseInput::try_delimited. Read moreSource§fn try_delimited_by_brackets(
self,
) -> impl for<'c> FnMut(&mut InputRef<'inp, 'c, L, Ctx, Lang, Cmpl>) -> TryDelimitedOf<'inp, Bracket<(), (), Lang>, L, Ctx, Lang, O>where
Self: Sized,
Bracket<(), (), Lang>: TypedDelimiter<'inp, L, Lang>,
L: Lexer<'inp>,
Ctx: ComposableParseContext<'inp, L, Lang>,
Cmpl: SurfaceIncomplete<'inp, L, Ctx, Lang>,
fn try_delimited_by_brackets(
self,
) -> impl for<'c> FnMut(&mut InputRef<'inp, 'c, L, Ctx, Lang, Cmpl>) -> TryDelimitedOf<'inp, Bracket<(), (), Lang>, L, Ctx, Lang, O>where
Self: Sized,
Bracket<(), (), Lang>: TypedDelimiter<'inp, L, Lang>,
L: Lexer<'inp>,
Ctx: ComposableParseContext<'inp, L, Lang>,
Cmpl: SurfaceIncomplete<'inp, L, Ctx, Lang>,
Bracket delimiter pair by delegating to ParseInput::try_delimited. Read moreSource§fn try_delimited_by_angles(
self,
) -> impl for<'c> FnMut(&mut InputRef<'inp, 'c, L, Ctx, Lang, Cmpl>) -> TryDelimitedOf<'inp, Angle<(), (), Lang>, L, Ctx, Lang, O>where
Self: Sized,
Angle<(), (), Lang>: TypedDelimiter<'inp, L, Lang>,
L: Lexer<'inp>,
Ctx: ComposableParseContext<'inp, L, Lang>,
Cmpl: SurfaceIncomplete<'inp, L, Ctx, Lang>,
fn try_delimited_by_angles(
self,
) -> impl for<'c> FnMut(&mut InputRef<'inp, 'c, L, Ctx, Lang, Cmpl>) -> TryDelimitedOf<'inp, Angle<(), (), Lang>, L, Ctx, Lang, O>where
Self: Sized,
Angle<(), (), Lang>: TypedDelimiter<'inp, L, Lang>,
L: Lexer<'inp>,
Ctx: ComposableParseContext<'inp, L, Lang>,
Cmpl: SurfaceIncomplete<'inp, L, Ctx, Lang>,
Angle delimiter pair by delegating to ParseInput::try_delimited. Read moreSource§fn spanned(self) -> With<PhantomSpan, Self, Cmpl>
fn spanned(self) -> With<PhantomSpan, Self, Cmpl>
Spanned with the span of the parsed input. Read moreSource§fn sliced(self) -> With<PhantomSliced, Self, Cmpl>
fn sliced(self) -> With<PhantomSliced, Self, Cmpl>
Sliced with the source slice of the parsed input. Read moreSource§fn located(self) -> With<PhantomLocated, Self, Cmpl>
fn located(self) -> With<PhantomLocated, Self, Cmpl>
Located with the span and source slice of the parsed input. Read moreSource§fn spanned_trimmed(self) -> With<Trimmed<PhantomSpan>, Self, Cmpl>
fn spanned_trimmed(self) -> With<Trimmed<PhantomSpan>, Self, Cmpl>
Spanned with the trimmed span of the parsed
input: from the start of the first token it consumes to the committed position after it. Read moreSource§fn sliced_trimmed(self) -> With<Trimmed<PhantomSliced>, Self, Cmpl>
fn sliced_trimmed(self) -> With<Trimmed<PhantomSliced>, Self, Cmpl>
Source§fn located_trimmed(self) -> With<Trimmed<PhantomLocated>, Self, Cmpl>
fn located_trimmed(self) -> With<Trimmed<PhantomLocated>, Self, Cmpl>
Source§fn ignored(self) -> Ignore<Self, O, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
Ignore<Self, O, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, (), Ctx, Lang, Cmpl>,
fn ignored(self) -> Ignore<Self, O, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
Ignore<Self, O, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, (), Ctx, Lang, Cmpl>,
Source§fn by_ref(&mut self) -> &mut ByRef<Self>
fn by_ref(&mut self) -> &mut ByRef<Self>
Source§fn fold_while<Condition, Init, Acc, W>(
self,
pred: Condition,
init: Init,
acc: Acc,
) -> FoldWhile<Self, Condition, Init, Acc, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
FoldWhile<Self, Condition, Init, Acc, O, W, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
fn fold_while<Condition, Init, Acc, W>(
self,
pred: Condition,
init: Init,
acc: Acc,
) -> FoldWhile<Self, Condition, Init, Acc, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
FoldWhile<Self, Condition, Init, Acc, O, W, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
fold only.FoldWhile combinator that accumulates results while a condition is met.Source§fn try_fold_while<Condition, Init, Acc, W>(
self,
pred: Condition,
init: Init,
acc: Acc,
) -> TryFoldWhile<Self, Condition, Init, Acc, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Init: FnMut() -> O,
Acc: FnMut(O, O) -> Result<O, <Ctx::Emitter as Emitter<'inp, L, Lang>>::Error>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
TryFoldWhile<Self, Condition, Init, Acc, O, W, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
fn try_fold_while<Condition, Init, Acc, W>(
self,
pred: Condition,
init: Init,
acc: Acc,
) -> TryFoldWhile<Self, Condition, Init, Acc, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Init: FnMut() -> O,
Acc: FnMut(O, O) -> Result<O, <Ctx::Emitter as Emitter<'inp, L, Lang>>::Error>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
TryFoldWhile<Self, Condition, Init, Acc, O, W, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
fold only.TryFoldWhile combinator that accumulates results while a condition is met. Read moreSource§fn try_fold_while_with<Condition, Init, Acc, W>(
self,
pred: Condition,
init: Init,
acc: Acc,
) -> TryFoldWhileWith<Self, Condition, Init, Acc, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Init: FnMut() -> O,
Acc: FnMut(O, O, ParseState<'_, 'inp, '_, L, Ctx, Lang, Cmpl>) -> Result<O, <Ctx::Emitter as Emitter<'inp, L, Lang>>::Error>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
TryFoldWhileWith<Self, Condition, Init, Acc, O, W, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
fn try_fold_while_with<Condition, Init, Acc, W>(
self,
pred: Condition,
init: Init,
acc: Acc,
) -> TryFoldWhileWith<Self, Condition, Init, Acc, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Init: FnMut() -> O,
Acc: FnMut(O, O, ParseState<'_, 'inp, '_, L, Ctx, Lang, Cmpl>) -> Result<O, <Ctx::Emitter as Emitter<'inp, L, Lang>>::Error>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
TryFoldWhileWith<Self, Condition, Init, Acc, O, W, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
fold only.TryFoldWhileWith combinator that accumulates results while a condition is met,
with access to parsing state.Source§fn rfold_while<Condition, Init, Acc, W>(
self,
condition: Condition,
init: Init,
acc: Acc,
) -> RFoldWhile<Self, Condition, Init, Acc, L, O, W, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Init: FnMut() -> O,
Acc: FnMut(O, O) -> O,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
RFoldWhile<Self, Condition, Init, Acc, L, O, W, Ctx, Lang, Cmpl>: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
fn rfold_while<Condition, Init, Acc, W>(
self,
condition: Condition,
init: Init,
acc: Acc,
) -> RFoldWhile<Self, Condition, Init, Acc, L, O, W, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Init: FnMut() -> O,
Acc: FnMut(O, O) -> O,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
RFoldWhile<Self, Condition, Init, Acc, L, O, W, Ctx, Lang, Cmpl>: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
fold and (crate features alloc or std) only.RFoldWhile combinator that applies this parser repeatedly,
while a condition is met, and folds results in reverse order. Read moreSource§fn repeated_while<Condition, W>(
self,
condition: Condition,
) -> RepeatedWhile<Self, Condition, O, W, L, Ctx, Lang, Cmpl>
fn repeated_while<Condition, W>( self, condition: Condition, ) -> RepeatedWhile<Self, Condition, O, W, L, Ctx, Lang, Cmpl>
many only.RepeatedWhile combinator that applies this parser repeatedly, where you
provide the lookahead logic. Read moreSource§fn separated_while<Sep, Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Sep, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
Sep: Punctuator<'inp, L, Lang>,
W: Window,
fn separated_while<Sep, Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Sep, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
Sep: Punctuator<'inp, L, Lang>,
W: Window,
many only.SeparatedWhile combinator that parses separated elements, where you
provide the lookahead logic. Read moreSource§fn separated_by_comma_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Comma<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
fn separated_by_comma_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Comma<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
many only.SeparatedWhile combinator which separates elements by the comma separator and applies this parser repeatedly. Read moreSource§fn separated_by_semicolon_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Semicolon<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
fn separated_by_semicolon_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Semicolon<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
many only.SeparatedWhile combinator which separates elements by the semicolon separator and applies this parser repeatedly. Read moreSource§fn separated_by_dot_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Dot<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
fn separated_by_dot_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Dot<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
many only.SeparatedWhile combinator which separates elements by the dot separator and applies this parser repeatedly. Read moreSource§fn separated_by_colon_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Colon<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
fn separated_by_colon_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Colon<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
many only.SeparatedWhile combinator which separates elements by the colon separator and applies this parser repeatedly. Read moreSource§fn separated_by_pipe_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Pipe<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
fn separated_by_pipe_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Pipe<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
many only.SeparatedWhile combinator which separates elements by the pipe separator and applies this parser repeatedly. Read moreSource§fn separated_by_ampersand_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Ampersand<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
fn separated_by_ampersand_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Ampersand<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
many only.SeparatedWhile combinator which separates elements by the ampersand separator and applies this parser repeatedly. Read moreSource§fn separated_by_hyphen_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Hyphen<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
fn separated_by_hyphen_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Hyphen<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
many only.SeparatedWhile combinator which separates elements by the hyphen separator and applies this parser repeatedly. Read moreSource§fn separated_by_underscore_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Underscore<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
fn separated_by_underscore_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Underscore<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
many only.SeparatedWhile combinator which separates elements by the underscore separator and applies this parser repeatedly. Read moreSource§fn separated_by_double_colon_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, DoubleColon<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
fn separated_by_double_colon_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, DoubleColon<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
many only.SeparatedWhile combinator which separates elements by the double_colon separator and applies this parser repeatedly. Read moreSource§fn separated_by_arrow_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Arrow<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
fn separated_by_arrow_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Arrow<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
many only.SeparatedWhile combinator which separates elements by the arrow separator and applies this parser repeatedly. Read moreSource§fn separated_by_fat_arrow_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, FatArrow<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
fn separated_by_fat_arrow_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, FatArrow<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
many only.SeparatedWhile combinator which separates elements by the fat_arrow separator and applies this parser repeatedly. Read moreSource§fn separated_by_tilde_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Tilde<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
fn separated_by_tilde_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Tilde<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
many only.SeparatedWhile combinator which separates elements by the tilde separator and applies this parser repeatedly. Read moreSource§fn separated_by_slash_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Slash<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
fn separated_by_slash_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Slash<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
many only.SeparatedWhile combinator which separates elements by the slash separator and applies this parser repeatedly. Read moreSource§fn separated_by_backslash_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Backslash<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
fn separated_by_backslash_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Backslash<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
many only.SeparatedWhile combinator which separates elements by the backslash separator and applies this parser repeatedly. Read moreSource§fn separated_by_percent_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Percent<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
fn separated_by_percent_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Percent<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
many only.SeparatedWhile combinator which separates elements by the percent separator and applies this parser repeatedly. Read moreSource§fn separated_by_dollar_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Dollar<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
fn separated_by_dollar_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Dollar<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
many only.SeparatedWhile combinator which separates elements by the dollar separator and applies this parser repeatedly. Read moreSource§fn separated_by_hash_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Hash<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
fn separated_by_hash_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Hash<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
many only.SeparatedWhile combinator which separates elements by the hash separator and applies this parser repeatedly. Read moreSource§fn separated_by_at_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, At<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
fn separated_by_at_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, At<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
many only.SeparatedWhile combinator which separates elements by the at separator and applies this parser repeatedly. Read moreSource§fn labelled(self, name: &'static str) -> Labelled<Self>where
Self: Sized,
fn labelled(self, name: &'static str) -> Labelled<Self>where
Self: Sized,
labelled.Source§fn traced(self, name: &'static str) -> Traced<Self>where
Self: Sized,
fn traced(self, name: &'static str) -> Traced<Self>where
Self: Sized,
trace only.traced.Source§fn list_until<Until>(
self,
until: Until,
) -> impl for<'c> FnMut(&mut InputRef<'inp, 'c, L, Ctx, Lang>) -> ListOf<'inp, L, Ctx, Lang, O>where
Self: Sized + ParseInput<'inp, L, O, Ctx, Lang>,
L: Lexer<'inp>,
Ctx: ComposableParseContext<'inp, L, Lang>,
Until: FnMut(&L::Token) -> bool,
fn list_until<Until>(
self,
until: Until,
) -> impl for<'c> FnMut(&mut InputRef<'inp, 'c, L, Ctx, Lang>) -> ListOf<'inp, L, Ctx, Lang, O>where
Self: Sized + ParseInput<'inp, L, O, Ctx, Lang>,
L: Lexer<'inp>,
Ctx: ComposableParseContext<'inp, L, Lang>,
Until: FnMut(&L::Token) -> bool,
many and (crate features alloc or std) only.Source§fn separated1_by<Sep, Peek>(
self,
peek: Peek,
) -> impl for<'c> FnMut(&mut InputRef<'inp, 'c, L, Ctx, Lang>) -> Separated1Of<'inp, L, Ctx, Lang, O>where
Self: Sized + ParseInput<'inp, L, O, Ctx, Lang>,
L: Lexer<'inp>,
Ctx: ComposableParseContext<'inp, L, Lang>,
Sep: Punctuator<'inp, L, Lang>,
Peek: FnMut(&L::Token) -> bool,
fn separated1_by<Sep, Peek>(
self,
peek: Peek,
) -> impl for<'c> FnMut(&mut InputRef<'inp, 'c, L, Ctx, Lang>) -> Separated1Of<'inp, L, Ctx, Lang, O>where
Self: Sized + ParseInput<'inp, L, O, Ctx, Lang>,
L: Lexer<'inp>,
Ctx: ComposableParseContext<'inp, L, Lang>,
Sep: Punctuator<'inp, L, Lang>,
Peek: FnMut(&L::Token) -> bool,
many and (crate features alloc or std) only.separated1 — the
committed-first “light” list shape, fluent. Read moreSource§fn peek_then<C, W>(self, condition: C) -> PeekThen<Self, C, L::Token, W, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
C: FnMut(Peeked<'_, 'inp, L, W>, EmitterView<'_, 'inp, L, Ctx::Emitter, Lang>) -> Result<(), <Ctx::Emitter as Emitter<'inp, L, Lang>>::Error>,
W: Window,
PeekThen<Self, C, L::Token, W, Cmpl>: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
fn peek_then<C, W>(self, condition: C) -> PeekThen<Self, C, L::Token, W, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
C: FnMut(Peeked<'_, 'inp, L, W>, EmitterView<'_, 'inp, L, Ctx::Emitter, Lang>) -> Result<(), <Ctx::Emitter as Emitter<'inp, L, Lang>>::Error>,
W: Window,
PeekThen<Self, C, L::Token, W, Cmpl>: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
peek only.PeekThen combinator that peeks at most N tokens first from the input before parsing. Read moreSource§fn peek_then_try<C, W>(
self,
condition: C,
) -> PeekThen<Self, C, L::Token, W, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
C: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
PeekThen<Self, C, L::Token, W, Cmpl>: TryParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
fn peek_then_try<C, W>(
self,
condition: C,
) -> PeekThen<Self, C, L::Token, W, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
C: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
PeekThen<Self, C, L::Token, W, Cmpl>: TryParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
peek only.PeekThen combinator that peeks at most N tokens first from the input before parsing. Read moreSource§fn peek_then_head<C>(
self,
condition: C,
) -> PeekThen<Self, impl FnMut(Peeked<'_, 'inp, L, U1>, EmitterView<'_, 'inp, L, Ctx::Emitter, Lang>) -> Result<(), <Ctx::Emitter as Emitter<'inp, L, Lang>>::Error>, L::Token, U1, Cmpl>
fn peek_then_head<C>( self, condition: C, ) -> PeekThen<Self, impl FnMut(Peeked<'_, 'inp, L, U1>, EmitterView<'_, 'inp, L, Ctx::Emitter, Lang>) -> Result<(), <Ctx::Emitter as Emitter<'inp, L, Lang>>::Error>, L::Token, U1, Cmpl>
peek only.Source§fn map<U, F>(self, f: F) -> Map<Self, F, L, Ctx, O, U, Lang, Cmpl>where
Self: Sized,
F: FnMut(O) -> U,
L: Lexer<'inp>,
Map<Self, F, L, Ctx, O, U, Lang, Cmpl>: ParseInput<'inp, L, U, Ctx, Lang, Cmpl>,
fn map<U, F>(self, f: F) -> Map<Self, F, L, Ctx, O, U, Lang, Cmpl>where
Self: Sized,
F: FnMut(O) -> U,
L: Lexer<'inp>,
Map<Self, F, L, Ctx, O, U, Lang, Cmpl>: ParseInput<'inp, L, U, Ctx, Lang, Cmpl>,
map only.Source§fn map_with<U, F>(self, f: F) -> MapWith<Self, F, L, Ctx, O, U, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
F: FnMut(O, ParseState<'_, 'inp, '_, L, Ctx, Lang, Cmpl>) -> U,
MapWith<Self, F, L, Ctx, O, U, Lang, Cmpl>: ParseInput<'inp, L, U, Ctx, Lang, Cmpl>,
fn map_with<U, F>(self, f: F) -> MapWith<Self, F, L, Ctx, O, U, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
F: FnMut(O, ParseState<'_, 'inp, '_, L, Ctx, Lang, Cmpl>) -> U,
MapWith<Self, F, L, Ctx, O, U, Lang, Cmpl>: ParseInput<'inp, L, U, Ctx, Lang, Cmpl>,
map only.Source§fn filter<F>(self, validator: F) -> Filter<Self, F, O, L, Ctx, Lang, Cmpl>
fn filter<F>(self, validator: F) -> Filter<Self, F, O, L, Ctx, Lang, Cmpl>
filter only.Source§fn filter_with<F>(
self,
validator: F,
) -> FilterWith<Self, F, O, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
F: FnMut(&O, ParseState<'_, 'inp, '_, L, Ctx, Lang, Cmpl>) -> Result<(), <Ctx::Emitter as Emitter<'inp, L, Lang>>::Error>,
Ctx: ParseContext<'inp, L, Lang>,
FilterWith<Self, F, O, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
fn filter_with<F>(
self,
validator: F,
) -> FilterWith<Self, F, O, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
F: FnMut(&O, ParseState<'_, 'inp, '_, L, Ctx, Lang, Cmpl>) -> Result<(), <Ctx::Emitter as Emitter<'inp, L, Lang>>::Error>,
Ctx: ParseContext<'inp, L, Lang>,
FilterWith<Self, F, O, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
filter only.Source§fn filter_map<U, F>(
self,
mapper: F,
) -> FilterMap<Self, F, O, U, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
F: FnMut(O) -> Result<U, <Ctx::Emitter as Emitter<'inp, L, Lang>>::Error>,
Ctx: ParseContext<'inp, L, Lang>,
FilterMap<Self, F, O, U, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, U, Ctx, Lang, Cmpl>,
fn filter_map<U, F>(
self,
mapper: F,
) -> FilterMap<Self, F, O, U, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
F: FnMut(O) -> Result<U, <Ctx::Emitter as Emitter<'inp, L, Lang>>::Error>,
Ctx: ParseContext<'inp, L, Lang>,
FilterMap<Self, F, O, U, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, U, Ctx, Lang, Cmpl>,
filter only.Source§fn filter_map_with<U, F>(
self,
mapper: F,
) -> FilterMapWith<Self, F, O, U, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
F: FnMut(O, ParseState<'_, 'inp, '_, L, Ctx, Lang, Cmpl>) -> Result<U, <Ctx::Emitter as Emitter<'inp, L, Lang>>::Error>,
Ctx: ParseContext<'inp, L, Lang>,
FilterMapWith<Self, F, O, U, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, U, Ctx, Lang, Cmpl>,
fn filter_map_with<U, F>(
self,
mapper: F,
) -> FilterMapWith<Self, F, O, U, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
F: FnMut(O, ParseState<'_, 'inp, '_, L, Ctx, Lang, Cmpl>) -> Result<U, <Ctx::Emitter as Emitter<'inp, L, Lang>>::Error>,
Ctx: ParseContext<'inp, L, Lang>,
FilterMapWith<Self, F, O, U, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, U, Ctx, Lang, Cmpl>,
filter only.Source§fn validate<F>(self, validator: F) -> Validate<Self, F, O, L, Ctx, Lang, Cmpl>
fn validate<F>(self, validator: F) -> Validate<Self, F, O, L, Ctx, Lang, Cmpl>
validate only.Source§fn validate_with<F>(
self,
validator: F,
) -> ValidateWith<Self, F, O, L, Ctx, Lang, Cmpl>
fn validate_with<F>( self, validator: F, ) -> ValidateWith<Self, F, O, L, Ctx, Lang, Cmpl>
validate only.Source§fn then_ignore<G, U>(
self,
second: G,
) -> ThenIgnore<Self, G, O, U, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
G: ParseInput<'inp, L, U, Ctx, Lang, Cmpl>,
Ctx: ParseContext<'inp, L, Lang>,
ThenIgnore<Self, G, O, U, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
fn then_ignore<G, U>(
self,
second: G,
) -> ThenIgnore<Self, G, O, U, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
G: ParseInput<'inp, L, U, Ctx, Lang, Cmpl>,
Ctx: ParseContext<'inp, L, Lang>,
ThenIgnore<Self, G, O, U, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
then only.Source§fn then_value<F, U>(
self,
value: F,
) -> ThenValue<Self, F, O, U, L, Ctx, Lang, Cmpl>
fn then_value<F, U>( self, value: F, ) -> ThenValue<Self, F, O, U, L, Ctx, Lang, Cmpl>
then only.Source§fn and_then<T, U>(self, then: T) -> AndThen<Self, T, O, U, L, Ctx, Lang, Cmpl>where
Self: Sized,
T: FnMut(O) -> Result<U, <Ctx::Emitter as Emitter<'inp, L, Lang>>::Error>,
L: Lexer<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
AndThen<Self, T, O, U, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, U, Ctx, Lang, Cmpl>,
fn and_then<T, U>(self, then: T) -> AndThen<Self, T, O, U, L, Ctx, Lang, Cmpl>where
Self: Sized,
T: FnMut(O) -> Result<U, <Ctx::Emitter as Emitter<'inp, L, Lang>>::Error>,
L: Lexer<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
AndThen<Self, T, O, U, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, U, Ctx, Lang, Cmpl>,
then only.Source§fn and_then_with<T, U>(
self,
then: T,
) -> AndThenWith<Self, T, O, U, L, Ctx, Lang, Cmpl>where
Self: Sized,
T: FnMut(O, ParseState<'_, 'inp, '_, L, Ctx, Lang, Cmpl>) -> Result<U, <Ctx::Emitter as Emitter<'inp, L, Lang>>::Error>,
Ctx: ParseContext<'inp, L, Lang>,
L: Lexer<'inp>,
AndThenWith<Self, T, O, U, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, U, Ctx, Lang, Cmpl>,
fn and_then_with<T, U>(
self,
then: T,
) -> AndThenWith<Self, T, O, U, L, Ctx, Lang, Cmpl>where
Self: Sized,
T: FnMut(O, ParseState<'_, 'inp, '_, L, Ctx, Lang, Cmpl>) -> Result<U, <Ctx::Emitter as Emitter<'inp, L, Lang>>::Error>,
Ctx: ParseContext<'inp, L, Lang>,
L: Lexer<'inp>,
AndThenWith<Self, T, O, U, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, U, Ctx, Lang, Cmpl>,
then only.Source§fn then<T, U>(self, then: T) -> Then<Self, T, O, U, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
T: ParseInput<'inp, L, U, Ctx, Lang, Cmpl>,
Ctx: ParseContext<'inp, L, Lang>,
Then<Self, T, O, U, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, (O, U), Ctx, Lang, Cmpl>,
fn then<T, U>(self, then: T) -> Then<Self, T, O, U, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
T: ParseInput<'inp, L, U, Ctx, Lang, Cmpl>,
Ctx: ParseContext<'inp, L, Lang>,
Then<Self, T, O, U, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, (O, U), Ctx, Lang, Cmpl>,
then only.Source§fn ignore_then<G, U>(
self,
second: G,
) -> IgnoreThen<Self, G, O, U, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
G: ParseInput<'inp, L, U, Ctx, Lang, Cmpl>,
IgnoreThen<Self, G, O, U, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, U, Ctx, Lang, Cmpl>,
fn ignore_then<G, U>(
self,
second: G,
) -> IgnoreThen<Self, G, O, U, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
G: ParseInput<'inp, L, U, Ctx, Lang, Cmpl>,
IgnoreThen<Self, G, O, U, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, U, Ctx, Lang, Cmpl>,
then only.Source§fn recover<R>(self, recovery: R) -> Recover<Self, R, O, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
R: RecoverInput<'inp, L, O, Ctx, Lang, Cmpl>,
Ctx: ParseContext<'inp, L, Lang>,
Recover<Self, R, O, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
fn recover<R>(self, recovery: R) -> Recover<Self, R, O, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
R: RecoverInput<'inp, L, O, Ctx, Lang, Cmpl>,
Ctx: ParseContext<'inp, L, Lang>,
Recover<Self, R, O, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
Source§fn inplace_recover<R>(
self,
recovery: R,
) -> InplaceRecover<Self, R, O, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
R: InplaceRecoverInput<'inp, L, O, Ctx, Lang, Cmpl>,
Ctx: ParseContext<'inp, L, Lang>,
InplaceRecover<Self, R, O, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
fn inplace_recover<R>(
self,
recovery: R,
) -> InplaceRecover<Self, R, O, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
R: InplaceRecoverInput<'inp, L, O, Ctx, Lang, Cmpl>,
Ctx: ParseContext<'inp, L, Lang>,
InplaceRecover<Self, R, O, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
Source§fn skip_then_retry<D, F>(
self,
classifier: D,
pred: F,
) -> SkipThenRetry<Self, D, F, O, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
D: DelimClass<<L::Token as Token<'inp>>::Kind>,
F: FnMut(Spanned<&L::Token, &L::Span>) -> bool,
Ctx: ParseContext<'inp, L, Lang>,
SkipThenRetry<Self, D, F, O, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
fn skip_then_retry<D, F>(
self,
classifier: D,
pred: F,
) -> SkipThenRetry<Self, D, F, O, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
D: DelimClass<<L::Token as Token<'inp>>::Kind>,
F: FnMut(Spanned<&L::Token, &L::Span>) -> bool,
Ctx: ParseContext<'inp, L, Lang>,
SkipThenRetry<Self, D, F, O, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
Source§fn padded(self) -> Padded<Self, O, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
Padded<Self, O, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
fn padded(self) -> Padded<Self, O, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
Padded<Self, O, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
Source§fn padded_left(self) -> PaddedLeft<Self, O, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
PaddedLeft<Self, O, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
fn padded_left(self) -> PaddedLeft<Self, O, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
PaddedLeft<Self, O, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
Source§fn padded_right(self) -> PaddedRight<Self, O, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
PaddedRight<Self, O, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
fn padded_right(self) -> PaddedRight<Self, O, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
PaddedRight<Self, O, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
Source§impl<'inp, L, O, Ctx, P, Lang: ?Sized, Cmpl> ParseInput<'inp, L, Located<O, <L as Lexer<'inp>>::Span, <<L as Lexer<'inp>>::Source as Source<<L as Lexer<'inp>>::Offset>>::Slice<'inp>>, Ctx, Lang, Cmpl> for With<Trimmed<PhantomLocated>, P, Cmpl>where
P: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
L: Lexer<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Cmpl: Completeness,
impl<'inp, L, O, Ctx, P, Lang: ?Sized, Cmpl> ParseInput<'inp, L, Located<O, <L as Lexer<'inp>>::Span, <<L as Lexer<'inp>>::Source as Source<<L as Lexer<'inp>>::Offset>>::Slice<'inp>>, Ctx, Lang, Cmpl> for With<Trimmed<PhantomLocated>, P, Cmpl>where
P: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
L: Lexer<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Cmpl: Completeness,
Source§fn parse_input(
&mut self,
inp: &mut InputRef<'inp, '_, L, Ctx, Lang, Cmpl>,
) -> Result<Located<O, L::Span, <L::Source as Source<L::Offset>>::Slice<'inp>>, <Ctx::Emitter as Emitter<'inp, L, Lang>>::Error>
fn parse_input( &mut self, inp: &mut InputRef<'inp, '_, L, Ctx, Lang, Cmpl>, ) -> Result<Located<O, L::Span, <L::Source as Source<L::Offset>>::Slice<'inp>>, <Ctx::Emitter as Emitter<'inp, L, Lang>>::Error>
Source§fn delimited<D>(
self,
) -> impl for<'c> FnMut(&mut InputRef<'inp, 'c, L, Ctx, Lang, Cmpl>) -> DelimitedOf<'inp, D, L, Ctx, Lang, O>where
Self: Sized,
D: TypedDelimiter<'inp, L, Lang>,
L: Lexer<'inp>,
Ctx: ComposableParseContext<'inp, L, Lang>,
Cmpl: SurfaceIncomplete<'inp, L, Ctx, Lang>,
fn delimited<D>(
self,
) -> impl for<'c> FnMut(&mut InputRef<'inp, 'c, L, Ctx, Lang, Cmpl>) -> DelimitedOf<'inp, D, L, Ctx, Lang, O>where
Self: Sized,
D: TypedDelimiter<'inp, L, Lang>,
L: Lexer<'inp>,
Ctx: ComposableParseContext<'inp, L, Lang>,
Cmpl: SurfaceIncomplete<'inp, L, Ctx, Lang>,
Source§fn delimited_by_parens(
self,
) -> impl for<'c> FnMut(&mut InputRef<'inp, 'c, L, Ctx, Lang, Cmpl>) -> DelimitedOf<'inp, Paren<(), (), Lang>, L, Ctx, Lang, O>where
Self: Sized,
Paren<(), (), Lang>: TypedDelimiter<'inp, L, Lang>,
L: Lexer<'inp>,
Ctx: ComposableParseContext<'inp, L, Lang>,
Cmpl: SurfaceIncomplete<'inp, L, Ctx, Lang>,
fn delimited_by_parens(
self,
) -> impl for<'c> FnMut(&mut InputRef<'inp, 'c, L, Ctx, Lang, Cmpl>) -> DelimitedOf<'inp, Paren<(), (), Lang>, L, Ctx, Lang, O>where
Self: Sized,
Paren<(), (), Lang>: TypedDelimiter<'inp, L, Lang>,
L: Lexer<'inp>,
Ctx: ComposableParseContext<'inp, L, Lang>,
Cmpl: SurfaceIncomplete<'inp, L, Ctx, Lang>,
Paren delimiter pair by delegating to ParseInput::delimited.Source§fn delimited_by_braces(
self,
) -> impl for<'c> FnMut(&mut InputRef<'inp, 'c, L, Ctx, Lang, Cmpl>) -> DelimitedOf<'inp, Brace<(), (), Lang>, L, Ctx, Lang, O>where
Self: Sized,
Brace<(), (), Lang>: TypedDelimiter<'inp, L, Lang>,
L: Lexer<'inp>,
Ctx: ComposableParseContext<'inp, L, Lang>,
Cmpl: SurfaceIncomplete<'inp, L, Ctx, Lang>,
fn delimited_by_braces(
self,
) -> impl for<'c> FnMut(&mut InputRef<'inp, 'c, L, Ctx, Lang, Cmpl>) -> DelimitedOf<'inp, Brace<(), (), Lang>, L, Ctx, Lang, O>where
Self: Sized,
Brace<(), (), Lang>: TypedDelimiter<'inp, L, Lang>,
L: Lexer<'inp>,
Ctx: ComposableParseContext<'inp, L, Lang>,
Cmpl: SurfaceIncomplete<'inp, L, Ctx, Lang>,
Brace delimiter pair by delegating to ParseInput::delimited.Source§fn delimited_by_brackets(
self,
) -> impl for<'c> FnMut(&mut InputRef<'inp, 'c, L, Ctx, Lang, Cmpl>) -> DelimitedOf<'inp, Bracket<(), (), Lang>, L, Ctx, Lang, O>where
Self: Sized,
Bracket<(), (), Lang>: TypedDelimiter<'inp, L, Lang>,
L: Lexer<'inp>,
Ctx: ComposableParseContext<'inp, L, Lang>,
Cmpl: SurfaceIncomplete<'inp, L, Ctx, Lang>,
fn delimited_by_brackets(
self,
) -> impl for<'c> FnMut(&mut InputRef<'inp, 'c, L, Ctx, Lang, Cmpl>) -> DelimitedOf<'inp, Bracket<(), (), Lang>, L, Ctx, Lang, O>where
Self: Sized,
Bracket<(), (), Lang>: TypedDelimiter<'inp, L, Lang>,
L: Lexer<'inp>,
Ctx: ComposableParseContext<'inp, L, Lang>,
Cmpl: SurfaceIncomplete<'inp, L, Ctx, Lang>,
Bracket delimiter pair by delegating to ParseInput::delimited.Source§fn delimited_by_angles(
self,
) -> impl for<'c> FnMut(&mut InputRef<'inp, 'c, L, Ctx, Lang, Cmpl>) -> DelimitedOf<'inp, Angle<(), (), Lang>, L, Ctx, Lang, O>where
Self: Sized,
Angle<(), (), Lang>: TypedDelimiter<'inp, L, Lang>,
L: Lexer<'inp>,
Ctx: ComposableParseContext<'inp, L, Lang>,
Cmpl: SurfaceIncomplete<'inp, L, Ctx, Lang>,
fn delimited_by_angles(
self,
) -> impl for<'c> FnMut(&mut InputRef<'inp, 'c, L, Ctx, Lang, Cmpl>) -> DelimitedOf<'inp, Angle<(), (), Lang>, L, Ctx, Lang, O>where
Self: Sized,
Angle<(), (), Lang>: TypedDelimiter<'inp, L, Lang>,
L: Lexer<'inp>,
Ctx: ComposableParseContext<'inp, L, Lang>,
Cmpl: SurfaceIncomplete<'inp, L, Ctx, Lang>,
Angle delimiter pair by delegating to ParseInput::delimited.Source§fn try_delimited<D>(
self,
) -> impl for<'c> FnMut(&mut InputRef<'inp, 'c, L, Ctx, Lang, Cmpl>) -> TryDelimitedOf<'inp, D, L, Ctx, Lang, O>where
Self: Sized,
D: TypedDelimiter<'inp, L, Lang>,
L: Lexer<'inp>,
Ctx: ComposableParseContext<'inp, L, Lang>,
Cmpl: SurfaceIncomplete<'inp, L, Ctx, Lang>,
fn try_delimited<D>(
self,
) -> impl for<'c> FnMut(&mut InputRef<'inp, 'c, L, Ctx, Lang, Cmpl>) -> TryDelimitedOf<'inp, D, L, Ctx, Lang, O>where
Self: Sized,
D: TypedDelimiter<'inp, L, Lang>,
L: Lexer<'inp>,
Ctx: ComposableParseContext<'inp, L, Lang>,
Cmpl: SurfaceIncomplete<'inp, L, Ctx, Lang>,
Source§fn try_delimited_by_parens(
self,
) -> impl for<'c> FnMut(&mut InputRef<'inp, 'c, L, Ctx, Lang, Cmpl>) -> TryDelimitedOf<'inp, Paren<(), (), Lang>, L, Ctx, Lang, O>where
Self: Sized,
Paren<(), (), Lang>: TypedDelimiter<'inp, L, Lang>,
L: Lexer<'inp>,
Ctx: ComposableParseContext<'inp, L, Lang>,
Cmpl: SurfaceIncomplete<'inp, L, Ctx, Lang>,
fn try_delimited_by_parens(
self,
) -> impl for<'c> FnMut(&mut InputRef<'inp, 'c, L, Ctx, Lang, Cmpl>) -> TryDelimitedOf<'inp, Paren<(), (), Lang>, L, Ctx, Lang, O>where
Self: Sized,
Paren<(), (), Lang>: TypedDelimiter<'inp, L, Lang>,
L: Lexer<'inp>,
Ctx: ComposableParseContext<'inp, L, Lang>,
Cmpl: SurfaceIncomplete<'inp, L, Ctx, Lang>,
Paren delimiter pair by delegating to ParseInput::try_delimited. Read moreSource§fn try_delimited_by_braces(
self,
) -> impl for<'c> FnMut(&mut InputRef<'inp, 'c, L, Ctx, Lang, Cmpl>) -> TryDelimitedOf<'inp, Brace<(), (), Lang>, L, Ctx, Lang, O>where
Self: Sized,
Brace<(), (), Lang>: TypedDelimiter<'inp, L, Lang>,
L: Lexer<'inp>,
Ctx: ComposableParseContext<'inp, L, Lang>,
Cmpl: SurfaceIncomplete<'inp, L, Ctx, Lang>,
fn try_delimited_by_braces(
self,
) -> impl for<'c> FnMut(&mut InputRef<'inp, 'c, L, Ctx, Lang, Cmpl>) -> TryDelimitedOf<'inp, Brace<(), (), Lang>, L, Ctx, Lang, O>where
Self: Sized,
Brace<(), (), Lang>: TypedDelimiter<'inp, L, Lang>,
L: Lexer<'inp>,
Ctx: ComposableParseContext<'inp, L, Lang>,
Cmpl: SurfaceIncomplete<'inp, L, Ctx, Lang>,
Brace delimiter pair by delegating to ParseInput::try_delimited. Read moreSource§fn try_delimited_by_brackets(
self,
) -> impl for<'c> FnMut(&mut InputRef<'inp, 'c, L, Ctx, Lang, Cmpl>) -> TryDelimitedOf<'inp, Bracket<(), (), Lang>, L, Ctx, Lang, O>where
Self: Sized,
Bracket<(), (), Lang>: TypedDelimiter<'inp, L, Lang>,
L: Lexer<'inp>,
Ctx: ComposableParseContext<'inp, L, Lang>,
Cmpl: SurfaceIncomplete<'inp, L, Ctx, Lang>,
fn try_delimited_by_brackets(
self,
) -> impl for<'c> FnMut(&mut InputRef<'inp, 'c, L, Ctx, Lang, Cmpl>) -> TryDelimitedOf<'inp, Bracket<(), (), Lang>, L, Ctx, Lang, O>where
Self: Sized,
Bracket<(), (), Lang>: TypedDelimiter<'inp, L, Lang>,
L: Lexer<'inp>,
Ctx: ComposableParseContext<'inp, L, Lang>,
Cmpl: SurfaceIncomplete<'inp, L, Ctx, Lang>,
Bracket delimiter pair by delegating to ParseInput::try_delimited. Read moreSource§fn try_delimited_by_angles(
self,
) -> impl for<'c> FnMut(&mut InputRef<'inp, 'c, L, Ctx, Lang, Cmpl>) -> TryDelimitedOf<'inp, Angle<(), (), Lang>, L, Ctx, Lang, O>where
Self: Sized,
Angle<(), (), Lang>: TypedDelimiter<'inp, L, Lang>,
L: Lexer<'inp>,
Ctx: ComposableParseContext<'inp, L, Lang>,
Cmpl: SurfaceIncomplete<'inp, L, Ctx, Lang>,
fn try_delimited_by_angles(
self,
) -> impl for<'c> FnMut(&mut InputRef<'inp, 'c, L, Ctx, Lang, Cmpl>) -> TryDelimitedOf<'inp, Angle<(), (), Lang>, L, Ctx, Lang, O>where
Self: Sized,
Angle<(), (), Lang>: TypedDelimiter<'inp, L, Lang>,
L: Lexer<'inp>,
Ctx: ComposableParseContext<'inp, L, Lang>,
Cmpl: SurfaceIncomplete<'inp, L, Ctx, Lang>,
Angle delimiter pair by delegating to ParseInput::try_delimited. Read moreSource§fn spanned(self) -> With<PhantomSpan, Self, Cmpl>
fn spanned(self) -> With<PhantomSpan, Self, Cmpl>
Spanned with the span of the parsed input. Read moreSource§fn sliced(self) -> With<PhantomSliced, Self, Cmpl>
fn sliced(self) -> With<PhantomSliced, Self, Cmpl>
Sliced with the source slice of the parsed input. Read moreSource§fn located(self) -> With<PhantomLocated, Self, Cmpl>
fn located(self) -> With<PhantomLocated, Self, Cmpl>
Located with the span and source slice of the parsed input. Read moreSource§fn spanned_trimmed(self) -> With<Trimmed<PhantomSpan>, Self, Cmpl>
fn spanned_trimmed(self) -> With<Trimmed<PhantomSpan>, Self, Cmpl>
Spanned with the trimmed span of the parsed
input: from the start of the first token it consumes to the committed position after it. Read moreSource§fn sliced_trimmed(self) -> With<Trimmed<PhantomSliced>, Self, Cmpl>
fn sliced_trimmed(self) -> With<Trimmed<PhantomSliced>, Self, Cmpl>
Source§fn located_trimmed(self) -> With<Trimmed<PhantomLocated>, Self, Cmpl>
fn located_trimmed(self) -> With<Trimmed<PhantomLocated>, Self, Cmpl>
Source§fn ignored(self) -> Ignore<Self, O, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
Ignore<Self, O, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, (), Ctx, Lang, Cmpl>,
fn ignored(self) -> Ignore<Self, O, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
Ignore<Self, O, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, (), Ctx, Lang, Cmpl>,
Source§fn by_ref(&mut self) -> &mut ByRef<Self>
fn by_ref(&mut self) -> &mut ByRef<Self>
Source§fn fold_while<Condition, Init, Acc, W>(
self,
pred: Condition,
init: Init,
acc: Acc,
) -> FoldWhile<Self, Condition, Init, Acc, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
FoldWhile<Self, Condition, Init, Acc, O, W, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
fn fold_while<Condition, Init, Acc, W>(
self,
pred: Condition,
init: Init,
acc: Acc,
) -> FoldWhile<Self, Condition, Init, Acc, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
FoldWhile<Self, Condition, Init, Acc, O, W, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
fold only.FoldWhile combinator that accumulates results while a condition is met.Source§fn try_fold_while<Condition, Init, Acc, W>(
self,
pred: Condition,
init: Init,
acc: Acc,
) -> TryFoldWhile<Self, Condition, Init, Acc, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Init: FnMut() -> O,
Acc: FnMut(O, O) -> Result<O, <Ctx::Emitter as Emitter<'inp, L, Lang>>::Error>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
TryFoldWhile<Self, Condition, Init, Acc, O, W, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
fn try_fold_while<Condition, Init, Acc, W>(
self,
pred: Condition,
init: Init,
acc: Acc,
) -> TryFoldWhile<Self, Condition, Init, Acc, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Init: FnMut() -> O,
Acc: FnMut(O, O) -> Result<O, <Ctx::Emitter as Emitter<'inp, L, Lang>>::Error>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
TryFoldWhile<Self, Condition, Init, Acc, O, W, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
fold only.TryFoldWhile combinator that accumulates results while a condition is met. Read moreSource§fn try_fold_while_with<Condition, Init, Acc, W>(
self,
pred: Condition,
init: Init,
acc: Acc,
) -> TryFoldWhileWith<Self, Condition, Init, Acc, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Init: FnMut() -> O,
Acc: FnMut(O, O, ParseState<'_, 'inp, '_, L, Ctx, Lang, Cmpl>) -> Result<O, <Ctx::Emitter as Emitter<'inp, L, Lang>>::Error>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
TryFoldWhileWith<Self, Condition, Init, Acc, O, W, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
fn try_fold_while_with<Condition, Init, Acc, W>(
self,
pred: Condition,
init: Init,
acc: Acc,
) -> TryFoldWhileWith<Self, Condition, Init, Acc, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Init: FnMut() -> O,
Acc: FnMut(O, O, ParseState<'_, 'inp, '_, L, Ctx, Lang, Cmpl>) -> Result<O, <Ctx::Emitter as Emitter<'inp, L, Lang>>::Error>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
TryFoldWhileWith<Self, Condition, Init, Acc, O, W, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
fold only.TryFoldWhileWith combinator that accumulates results while a condition is met,
with access to parsing state.Source§fn rfold_while<Condition, Init, Acc, W>(
self,
condition: Condition,
init: Init,
acc: Acc,
) -> RFoldWhile<Self, Condition, Init, Acc, L, O, W, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Init: FnMut() -> O,
Acc: FnMut(O, O) -> O,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
RFoldWhile<Self, Condition, Init, Acc, L, O, W, Ctx, Lang, Cmpl>: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
fn rfold_while<Condition, Init, Acc, W>(
self,
condition: Condition,
init: Init,
acc: Acc,
) -> RFoldWhile<Self, Condition, Init, Acc, L, O, W, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Init: FnMut() -> O,
Acc: FnMut(O, O) -> O,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
RFoldWhile<Self, Condition, Init, Acc, L, O, W, Ctx, Lang, Cmpl>: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
fold and (crate features alloc or std) only.RFoldWhile combinator that applies this parser repeatedly,
while a condition is met, and folds results in reverse order. Read moreSource§fn repeated_while<Condition, W>(
self,
condition: Condition,
) -> RepeatedWhile<Self, Condition, O, W, L, Ctx, Lang, Cmpl>
fn repeated_while<Condition, W>( self, condition: Condition, ) -> RepeatedWhile<Self, Condition, O, W, L, Ctx, Lang, Cmpl>
many only.RepeatedWhile combinator that applies this parser repeatedly, where you
provide the lookahead logic. Read moreSource§fn separated_while<Sep, Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Sep, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
Sep: Punctuator<'inp, L, Lang>,
W: Window,
fn separated_while<Sep, Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Sep, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
Sep: Punctuator<'inp, L, Lang>,
W: Window,
many only.SeparatedWhile combinator that parses separated elements, where you
provide the lookahead logic. Read moreSource§fn separated_by_comma_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Comma<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
fn separated_by_comma_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Comma<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
many only.SeparatedWhile combinator which separates elements by the comma separator and applies this parser repeatedly. Read moreSource§fn separated_by_semicolon_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Semicolon<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
fn separated_by_semicolon_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Semicolon<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
many only.SeparatedWhile combinator which separates elements by the semicolon separator and applies this parser repeatedly. Read moreSource§fn separated_by_dot_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Dot<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
fn separated_by_dot_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Dot<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
many only.SeparatedWhile combinator which separates elements by the dot separator and applies this parser repeatedly. Read moreSource§fn separated_by_colon_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Colon<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
fn separated_by_colon_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Colon<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
many only.SeparatedWhile combinator which separates elements by the colon separator and applies this parser repeatedly. Read moreSource§fn separated_by_pipe_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Pipe<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
fn separated_by_pipe_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Pipe<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
many only.SeparatedWhile combinator which separates elements by the pipe separator and applies this parser repeatedly. Read moreSource§fn separated_by_ampersand_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Ampersand<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
fn separated_by_ampersand_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Ampersand<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
many only.SeparatedWhile combinator which separates elements by the ampersand separator and applies this parser repeatedly. Read moreSource§fn separated_by_hyphen_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Hyphen<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
fn separated_by_hyphen_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Hyphen<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
many only.SeparatedWhile combinator which separates elements by the hyphen separator and applies this parser repeatedly. Read moreSource§fn separated_by_underscore_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Underscore<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
fn separated_by_underscore_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Underscore<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
many only.SeparatedWhile combinator which separates elements by the underscore separator and applies this parser repeatedly. Read moreSource§fn separated_by_double_colon_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, DoubleColon<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
fn separated_by_double_colon_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, DoubleColon<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
many only.SeparatedWhile combinator which separates elements by the double_colon separator and applies this parser repeatedly. Read moreSource§fn separated_by_arrow_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Arrow<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
fn separated_by_arrow_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Arrow<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
many only.SeparatedWhile combinator which separates elements by the arrow separator and applies this parser repeatedly. Read moreSource§fn separated_by_fat_arrow_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, FatArrow<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
fn separated_by_fat_arrow_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, FatArrow<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
many only.SeparatedWhile combinator which separates elements by the fat_arrow separator and applies this parser repeatedly. Read moreSource§fn separated_by_tilde_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Tilde<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
fn separated_by_tilde_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Tilde<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
many only.SeparatedWhile combinator which separates elements by the tilde separator and applies this parser repeatedly. Read moreSource§fn separated_by_slash_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Slash<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
fn separated_by_slash_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Slash<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
many only.SeparatedWhile combinator which separates elements by the slash separator and applies this parser repeatedly. Read moreSource§fn separated_by_backslash_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Backslash<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
fn separated_by_backslash_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Backslash<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
many only.SeparatedWhile combinator which separates elements by the backslash separator and applies this parser repeatedly. Read moreSource§fn separated_by_percent_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Percent<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
fn separated_by_percent_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Percent<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
many only.SeparatedWhile combinator which separates elements by the percent separator and applies this parser repeatedly. Read moreSource§fn separated_by_dollar_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Dollar<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
fn separated_by_dollar_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Dollar<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
many only.SeparatedWhile combinator which separates elements by the dollar separator and applies this parser repeatedly. Read moreSource§fn separated_by_hash_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Hash<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
fn separated_by_hash_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, Hash<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
many only.SeparatedWhile combinator which separates elements by the hash separator and applies this parser repeatedly. Read moreSource§fn separated_by_at_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, At<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
fn separated_by_at_while<Condition, W>(
self,
condition: Condition,
) -> SeparatedWhile<Self, At<(), (), Lang>, Condition, O, W, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Condition: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
many only.SeparatedWhile combinator which separates elements by the at separator and applies this parser repeatedly. Read moreSource§fn labelled(self, name: &'static str) -> Labelled<Self>where
Self: Sized,
fn labelled(self, name: &'static str) -> Labelled<Self>where
Self: Sized,
labelled.Source§fn traced(self, name: &'static str) -> Traced<Self>where
Self: Sized,
fn traced(self, name: &'static str) -> Traced<Self>where
Self: Sized,
trace only.traced.Source§fn list_until<Until>(
self,
until: Until,
) -> impl for<'c> FnMut(&mut InputRef<'inp, 'c, L, Ctx, Lang>) -> ListOf<'inp, L, Ctx, Lang, O>where
Self: Sized + ParseInput<'inp, L, O, Ctx, Lang>,
L: Lexer<'inp>,
Ctx: ComposableParseContext<'inp, L, Lang>,
Until: FnMut(&L::Token) -> bool,
fn list_until<Until>(
self,
until: Until,
) -> impl for<'c> FnMut(&mut InputRef<'inp, 'c, L, Ctx, Lang>) -> ListOf<'inp, L, Ctx, Lang, O>where
Self: Sized + ParseInput<'inp, L, O, Ctx, Lang>,
L: Lexer<'inp>,
Ctx: ComposableParseContext<'inp, L, Lang>,
Until: FnMut(&L::Token) -> bool,
many and (crate features alloc or std) only.Source§fn separated1_by<Sep, Peek>(
self,
peek: Peek,
) -> impl for<'c> FnMut(&mut InputRef<'inp, 'c, L, Ctx, Lang>) -> Separated1Of<'inp, L, Ctx, Lang, O>where
Self: Sized + ParseInput<'inp, L, O, Ctx, Lang>,
L: Lexer<'inp>,
Ctx: ComposableParseContext<'inp, L, Lang>,
Sep: Punctuator<'inp, L, Lang>,
Peek: FnMut(&L::Token) -> bool,
fn separated1_by<Sep, Peek>(
self,
peek: Peek,
) -> impl for<'c> FnMut(&mut InputRef<'inp, 'c, L, Ctx, Lang>) -> Separated1Of<'inp, L, Ctx, Lang, O>where
Self: Sized + ParseInput<'inp, L, O, Ctx, Lang>,
L: Lexer<'inp>,
Ctx: ComposableParseContext<'inp, L, Lang>,
Sep: Punctuator<'inp, L, Lang>,
Peek: FnMut(&L::Token) -> bool,
many and (crate features alloc or std) only.separated1 — the
committed-first “light” list shape, fluent. Read moreSource§fn peek_then<C, W>(self, condition: C) -> PeekThen<Self, C, L::Token, W, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
C: FnMut(Peeked<'_, 'inp, L, W>, EmitterView<'_, 'inp, L, Ctx::Emitter, Lang>) -> Result<(), <Ctx::Emitter as Emitter<'inp, L, Lang>>::Error>,
W: Window,
PeekThen<Self, C, L::Token, W, Cmpl>: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
fn peek_then<C, W>(self, condition: C) -> PeekThen<Self, C, L::Token, W, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
C: FnMut(Peeked<'_, 'inp, L, W>, EmitterView<'_, 'inp, L, Ctx::Emitter, Lang>) -> Result<(), <Ctx::Emitter as Emitter<'inp, L, Lang>>::Error>,
W: Window,
PeekThen<Self, C, L::Token, W, Cmpl>: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
peek only.PeekThen combinator that peeks at most N tokens first from the input before parsing. Read moreSource§fn peek_then_try<C, W>(
self,
condition: C,
) -> PeekThen<Self, C, L::Token, W, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
C: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
PeekThen<Self, C, L::Token, W, Cmpl>: TryParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
fn peek_then_try<C, W>(
self,
condition: C,
) -> PeekThen<Self, C, L::Token, W, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
C: Decision<'inp, L, Ctx::Emitter, W, Lang>,
W: Window,
PeekThen<Self, C, L::Token, W, Cmpl>: TryParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
peek only.PeekThen combinator that peeks at most N tokens first from the input before parsing. Read moreSource§fn peek_then_head<C>(
self,
condition: C,
) -> PeekThen<Self, impl FnMut(Peeked<'_, 'inp, L, U1>, EmitterView<'_, 'inp, L, Ctx::Emitter, Lang>) -> Result<(), <Ctx::Emitter as Emitter<'inp, L, Lang>>::Error>, L::Token, U1, Cmpl>
fn peek_then_head<C>( self, condition: C, ) -> PeekThen<Self, impl FnMut(Peeked<'_, 'inp, L, U1>, EmitterView<'_, 'inp, L, Ctx::Emitter, Lang>) -> Result<(), <Ctx::Emitter as Emitter<'inp, L, Lang>>::Error>, L::Token, U1, Cmpl>
peek only.Source§fn map<U, F>(self, f: F) -> Map<Self, F, L, Ctx, O, U, Lang, Cmpl>where
Self: Sized,
F: FnMut(O) -> U,
L: Lexer<'inp>,
Map<Self, F, L, Ctx, O, U, Lang, Cmpl>: ParseInput<'inp, L, U, Ctx, Lang, Cmpl>,
fn map<U, F>(self, f: F) -> Map<Self, F, L, Ctx, O, U, Lang, Cmpl>where
Self: Sized,
F: FnMut(O) -> U,
L: Lexer<'inp>,
Map<Self, F, L, Ctx, O, U, Lang, Cmpl>: ParseInput<'inp, L, U, Ctx, Lang, Cmpl>,
map only.Source§fn map_with<U, F>(self, f: F) -> MapWith<Self, F, L, Ctx, O, U, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
F: FnMut(O, ParseState<'_, 'inp, '_, L, Ctx, Lang, Cmpl>) -> U,
MapWith<Self, F, L, Ctx, O, U, Lang, Cmpl>: ParseInput<'inp, L, U, Ctx, Lang, Cmpl>,
fn map_with<U, F>(self, f: F) -> MapWith<Self, F, L, Ctx, O, U, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
F: FnMut(O, ParseState<'_, 'inp, '_, L, Ctx, Lang, Cmpl>) -> U,
MapWith<Self, F, L, Ctx, O, U, Lang, Cmpl>: ParseInput<'inp, L, U, Ctx, Lang, Cmpl>,
map only.Source§fn filter<F>(self, validator: F) -> Filter<Self, F, O, L, Ctx, Lang, Cmpl>
fn filter<F>(self, validator: F) -> Filter<Self, F, O, L, Ctx, Lang, Cmpl>
filter only.Source§fn filter_with<F>(
self,
validator: F,
) -> FilterWith<Self, F, O, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
F: FnMut(&O, ParseState<'_, 'inp, '_, L, Ctx, Lang, Cmpl>) -> Result<(), <Ctx::Emitter as Emitter<'inp, L, Lang>>::Error>,
Ctx: ParseContext<'inp, L, Lang>,
FilterWith<Self, F, O, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
fn filter_with<F>(
self,
validator: F,
) -> FilterWith<Self, F, O, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
F: FnMut(&O, ParseState<'_, 'inp, '_, L, Ctx, Lang, Cmpl>) -> Result<(), <Ctx::Emitter as Emitter<'inp, L, Lang>>::Error>,
Ctx: ParseContext<'inp, L, Lang>,
FilterWith<Self, F, O, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
filter only.Source§fn filter_map<U, F>(
self,
mapper: F,
) -> FilterMap<Self, F, O, U, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
F: FnMut(O) -> Result<U, <Ctx::Emitter as Emitter<'inp, L, Lang>>::Error>,
Ctx: ParseContext<'inp, L, Lang>,
FilterMap<Self, F, O, U, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, U, Ctx, Lang, Cmpl>,
fn filter_map<U, F>(
self,
mapper: F,
) -> FilterMap<Self, F, O, U, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
F: FnMut(O) -> Result<U, <Ctx::Emitter as Emitter<'inp, L, Lang>>::Error>,
Ctx: ParseContext<'inp, L, Lang>,
FilterMap<Self, F, O, U, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, U, Ctx, Lang, Cmpl>,
filter only.Source§fn filter_map_with<U, F>(
self,
mapper: F,
) -> FilterMapWith<Self, F, O, U, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
F: FnMut(O, ParseState<'_, 'inp, '_, L, Ctx, Lang, Cmpl>) -> Result<U, <Ctx::Emitter as Emitter<'inp, L, Lang>>::Error>,
Ctx: ParseContext<'inp, L, Lang>,
FilterMapWith<Self, F, O, U, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, U, Ctx, Lang, Cmpl>,
fn filter_map_with<U, F>(
self,
mapper: F,
) -> FilterMapWith<Self, F, O, U, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
F: FnMut(O, ParseState<'_, 'inp, '_, L, Ctx, Lang, Cmpl>) -> Result<U, <Ctx::Emitter as Emitter<'inp, L, Lang>>::Error>,
Ctx: ParseContext<'inp, L, Lang>,
FilterMapWith<Self, F, O, U, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, U, Ctx, Lang, Cmpl>,
filter only.Source§fn validate<F>(self, validator: F) -> Validate<Self, F, O, L, Ctx, Lang, Cmpl>
fn validate<F>(self, validator: F) -> Validate<Self, F, O, L, Ctx, Lang, Cmpl>
validate only.Source§fn validate_with<F>(
self,
validator: F,
) -> ValidateWith<Self, F, O, L, Ctx, Lang, Cmpl>
fn validate_with<F>( self, validator: F, ) -> ValidateWith<Self, F, O, L, Ctx, Lang, Cmpl>
validate only.Source§fn then_ignore<G, U>(
self,
second: G,
) -> ThenIgnore<Self, G, O, U, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
G: ParseInput<'inp, L, U, Ctx, Lang, Cmpl>,
Ctx: ParseContext<'inp, L, Lang>,
ThenIgnore<Self, G, O, U, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
fn then_ignore<G, U>(
self,
second: G,
) -> ThenIgnore<Self, G, O, U, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
G: ParseInput<'inp, L, U, Ctx, Lang, Cmpl>,
Ctx: ParseContext<'inp, L, Lang>,
ThenIgnore<Self, G, O, U, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
then only.Source§fn then_value<F, U>(
self,
value: F,
) -> ThenValue<Self, F, O, U, L, Ctx, Lang, Cmpl>
fn then_value<F, U>( self, value: F, ) -> ThenValue<Self, F, O, U, L, Ctx, Lang, Cmpl>
then only.Source§fn and_then<T, U>(self, then: T) -> AndThen<Self, T, O, U, L, Ctx, Lang, Cmpl>where
Self: Sized,
T: FnMut(O) -> Result<U, <Ctx::Emitter as Emitter<'inp, L, Lang>>::Error>,
L: Lexer<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
AndThen<Self, T, O, U, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, U, Ctx, Lang, Cmpl>,
fn and_then<T, U>(self, then: T) -> AndThen<Self, T, O, U, L, Ctx, Lang, Cmpl>where
Self: Sized,
T: FnMut(O) -> Result<U, <Ctx::Emitter as Emitter<'inp, L, Lang>>::Error>,
L: Lexer<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
AndThen<Self, T, O, U, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, U, Ctx, Lang, Cmpl>,
then only.Source§fn and_then_with<T, U>(
self,
then: T,
) -> AndThenWith<Self, T, O, U, L, Ctx, Lang, Cmpl>where
Self: Sized,
T: FnMut(O, ParseState<'_, 'inp, '_, L, Ctx, Lang, Cmpl>) -> Result<U, <Ctx::Emitter as Emitter<'inp, L, Lang>>::Error>,
Ctx: ParseContext<'inp, L, Lang>,
L: Lexer<'inp>,
AndThenWith<Self, T, O, U, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, U, Ctx, Lang, Cmpl>,
fn and_then_with<T, U>(
self,
then: T,
) -> AndThenWith<Self, T, O, U, L, Ctx, Lang, Cmpl>where
Self: Sized,
T: FnMut(O, ParseState<'_, 'inp, '_, L, Ctx, Lang, Cmpl>) -> Result<U, <Ctx::Emitter as Emitter<'inp, L, Lang>>::Error>,
Ctx: ParseContext<'inp, L, Lang>,
L: Lexer<'inp>,
AndThenWith<Self, T, O, U, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, U, Ctx, Lang, Cmpl>,
then only.Source§fn then<T, U>(self, then: T) -> Then<Self, T, O, U, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
T: ParseInput<'inp, L, U, Ctx, Lang, Cmpl>,
Ctx: ParseContext<'inp, L, Lang>,
Then<Self, T, O, U, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, (O, U), Ctx, Lang, Cmpl>,
fn then<T, U>(self, then: T) -> Then<Self, T, O, U, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
T: ParseInput<'inp, L, U, Ctx, Lang, Cmpl>,
Ctx: ParseContext<'inp, L, Lang>,
Then<Self, T, O, U, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, (O, U), Ctx, Lang, Cmpl>,
then only.Source§fn ignore_then<G, U>(
self,
second: G,
) -> IgnoreThen<Self, G, O, U, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
G: ParseInput<'inp, L, U, Ctx, Lang, Cmpl>,
IgnoreThen<Self, G, O, U, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, U, Ctx, Lang, Cmpl>,
fn ignore_then<G, U>(
self,
second: G,
) -> IgnoreThen<Self, G, O, U, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
G: ParseInput<'inp, L, U, Ctx, Lang, Cmpl>,
IgnoreThen<Self, G, O, U, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, U, Ctx, Lang, Cmpl>,
then only.Source§fn recover<R>(self, recovery: R) -> Recover<Self, R, O, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
R: RecoverInput<'inp, L, O, Ctx, Lang, Cmpl>,
Ctx: ParseContext<'inp, L, Lang>,
Recover<Self, R, O, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
fn recover<R>(self, recovery: R) -> Recover<Self, R, O, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
R: RecoverInput<'inp, L, O, Ctx, Lang, Cmpl>,
Ctx: ParseContext<'inp, L, Lang>,
Recover<Self, R, O, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
Source§fn inplace_recover<R>(
self,
recovery: R,
) -> InplaceRecover<Self, R, O, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
R: InplaceRecoverInput<'inp, L, O, Ctx, Lang, Cmpl>,
Ctx: ParseContext<'inp, L, Lang>,
InplaceRecover<Self, R, O, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
fn inplace_recover<R>(
self,
recovery: R,
) -> InplaceRecover<Self, R, O, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
R: InplaceRecoverInput<'inp, L, O, Ctx, Lang, Cmpl>,
Ctx: ParseContext<'inp, L, Lang>,
InplaceRecover<Self, R, O, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
Source§fn skip_then_retry<D, F>(
self,
classifier: D,
pred: F,
) -> SkipThenRetry<Self, D, F, O, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
D: DelimClass<<L::Token as Token<'inp>>::Kind>,
F: FnMut(Spanned<&L::Token, &L::Span>) -> bool,
Ctx: ParseContext<'inp, L, Lang>,
SkipThenRetry<Self, D, F, O, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
fn skip_then_retry<D, F>(
self,
classifier: D,
pred: F,
) -> SkipThenRetry<Self, D, F, O, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
D: DelimClass<<L::Token as Token<'inp>>::Kind>,
F: FnMut(Spanned<&L::Token, &L::Span>) -> bool,
Ctx: ParseContext<'inp, L, Lang>,
SkipThenRetry<Self, D, F, O, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
Source§fn padded(self) -> Padded<Self, O, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
Padded<Self, O, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
fn padded(self) -> Padded<Self, O, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
Padded<Self, O, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
Source§fn padded_left(self) -> PaddedLeft<Self, O, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
PaddedLeft<Self, O, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
fn padded_left(self) -> PaddedLeft<Self, O, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
PaddedLeft<Self, O, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
Source§fn padded_right(self) -> PaddedRight<Self, O, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
PaddedRight<Self, O, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
fn padded_right(self) -> PaddedRight<Self, O, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
PaddedRight<Self, O, L, Ctx, Lang, Cmpl>: ParseInput<'inp, L, O, Ctx, Lang, Cmpl>,
Source§impl<D: PartialOrd, Sp: PartialOrd, Sl: PartialOrd> PartialOrd for Located<D, Sp, Sl>
impl<D: PartialOrd, Sp: PartialOrd, Sl: PartialOrd> PartialOrd for Located<D, Sp, Sl>
impl<D: PartialEq, Sp: PartialEq, Sl: PartialEq> StructuralPartialEq for Located<D, Sp, Sl>
Source§impl<'inp, L, Ctx, Classifier, Lang: ?Sized, Cmpl> TryParseInput<'inp, L, Located<<L as Lexer<'inp>>::Token, <L as Lexer<'inp>>::Span, <<L as Lexer<'inp>>::Source as Source<<L as Lexer<'inp>>::Offset>>::Slice<'inp>>, Ctx, Lang, Cmpl> for With<Expect<Classifier, Ctx, Lang>, PhantomLocated>where
L: Lexer<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Classifier: Check<L::Token>,
Cmpl: SurfaceIncomplete<'inp, L, Ctx, Lang>,
<Ctx::Emitter as Emitter<'inp, L, Lang>>::Error: From<UnexpectedEot<L::Offset, Lang>>,
impl<'inp, L, Ctx, Classifier, Lang: ?Sized, Cmpl> TryParseInput<'inp, L, Located<<L as Lexer<'inp>>::Token, <L as Lexer<'inp>>::Span, <<L as Lexer<'inp>>::Source as Source<<L as Lexer<'inp>>::Offset>>::Slice<'inp>>, Ctx, Lang, Cmpl> for With<Expect<Classifier, Ctx, Lang>, PhantomLocated>where
L: Lexer<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Classifier: Check<L::Token>,
Cmpl: SurfaceIncomplete<'inp, L, Ctx, Lang>,
<Ctx::Emitter as Emitter<'inp, L, Lang>>::Error: From<UnexpectedEot<L::Offset, Lang>>,
Source§fn try_parse_input(
&mut self,
inp: &mut InputRef<'inp, '_, L, Ctx, Lang, Cmpl>,
) -> Result<ParseAttempt<Located<L::Token, L::Span, <L::Source as Source<L::Offset>>::Slice<'inp>>>, <Ctx::Emitter as Emitter<'inp, L, Lang>>::Error>
fn try_parse_input( &mut self, inp: &mut InputRef<'inp, '_, L, Ctx, Lang, Cmpl>, ) -> Result<ParseAttempt<Located<L::Token, L::Span, <L::Source as Source<L::Offset>>::Slice<'inp>>>, <Ctx::Emitter as Emitter<'inp, L, Lang>>::Error>
O from the input without committing. Read moreSource§fn accepted(self) -> Accepted<Self, L, O, Ctx, Lang, Cmpl>
fn accepted(self) -> Accepted<Self, L, O, Ctx, Lang, Cmpl>
ParseAttempt::Accept.Source§fn opt(
self,
) -> impl for<'c> FnMut(&mut InputRef<'inp, 'c, L, Ctx, Lang, Cmpl>) -> OptOf<'inp, L, Ctx, Lang, O>
fn opt( self, ) -> impl for<'c> FnMut(&mut InputRef<'inp, 'c, L, Ctx, Lang, Cmpl>) -> OptOf<'inp, L, Ctx, Lang, O>
opt — a committed parser over
Option<O>: Accept(v) → Some(v), Decline → None.Source§fn by_ref(&mut self) -> &mut ByRef<Self>
fn by_ref(&mut self) -> &mut ByRef<Self>
Source§fn repeated(self) -> Repeated<Self, O, L, Ctx, Lang, Cmpl>
fn repeated(self) -> Repeated<Self, O, L, Ctx, Lang, Cmpl>
many only.Repeated combinator that applies this parser repeatedly until it signals completion. Read moreSource§fn fold<Init, Acc>(
self,
init: Init,
acc: Acc,
) -> Fold<Self, Init, Acc, L, O, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Init: FnMut() -> O,
Acc: FnMut(O, O) -> O,
fn fold<Init, Acc>(
self,
init: Init,
acc: Acc,
) -> Fold<Self, Init, Acc, L, O, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Init: FnMut() -> O,
Acc: FnMut(O, O) -> O,
fold only.Fold combinator that accumulates results using the provided initializer and accumulator. Read moreSource§fn try_fold<Init, Acc>(
self,
init: Init,
acc: Acc,
) -> TryFold<Self, Init, Acc, L, O, Ctx, Lang, Cmpl>
fn try_fold<Init, Acc>( self, init: Init, acc: Acc, ) -> TryFold<Self, Init, Acc, L, O, Ctx, Lang, Cmpl>
fold only.TryFold combinator that accumulates results using the provided initializer and fallible accumulator. Read moreSource§fn try_fold_with<Init, Acc>(
self,
init: Init,
acc: Acc,
) -> TryFoldWith<Self, Init, Acc, L, O, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Init: FnMut() -> O,
Acc: FnMut(O, O, ParseState<'_, 'inp, '_, L, Ctx, Lang, Cmpl>) -> Result<O, <Ctx::Emitter as Emitter<'inp, L, Lang>>::Error>,
fn try_fold_with<Init, Acc>(
self,
init: Init,
acc: Acc,
) -> TryFoldWith<Self, Init, Acc, L, O, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Init: FnMut() -> O,
Acc: FnMut(O, O, ParseState<'_, 'inp, '_, L, Ctx, Lang, Cmpl>) -> Result<O, <Ctx::Emitter as Emitter<'inp, L, Lang>>::Error>,
fold only.TryFoldWith combinator that accumulates results using the provided initializer,
fallible accumulator, and parsing state. Read moreSource§fn rfold<Init, Acc>(
self,
init: Init,
acc: Acc,
) -> RFold<Self, Init, Acc, L, O, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Init: FnMut() -> O,
Acc: FnMut(O, O) -> O,
fn rfold<Init, Acc>(
self,
init: Init,
acc: Acc,
) -> RFold<Self, Init, Acc, L, O, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Init: FnMut() -> O,
Acc: FnMut(O, O) -> O,
fold and (crate features alloc or std) only.RFold combinator that accumulates results in reverse order using the provided
initializer and accumulator. Read moreSource§fn separated<Sep>(self) -> Separated<Self, Sep, O, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Sep: Punctuator<'inp, L, Lang>,
fn separated<Sep>(self) -> Separated<Self, Sep, O, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
Sep: Punctuator<'inp, L, Lang>,
many only.Separated combinator that parses separated elements, where this parser
handles the lookahead. Read moreSource§fn separated_by_comma(
self,
) -> Separated<Self, Comma<(), (), Lang>, O, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
fn separated_by_comma(
self,
) -> Separated<Self, Comma<(), (), Lang>, O, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
many only.Separated combinator which separates elements by the comma separator and applies this parser repeatedly. Read moreSource§fn separated_by_semicolon(
self,
) -> Separated<Self, Semicolon<(), (), Lang>, O, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
fn separated_by_semicolon(
self,
) -> Separated<Self, Semicolon<(), (), Lang>, O, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
many only.Separated combinator which separates elements by the semicolon separator and applies this parser repeatedly. Read moreSource§fn separated_by_dot(
self,
) -> Separated<Self, Dot<(), (), Lang>, O, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
fn separated_by_dot(
self,
) -> Separated<Self, Dot<(), (), Lang>, O, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
many only.Separated combinator which separates elements by the dot separator and applies this parser repeatedly. Read moreSource§fn separated_by_colon(
self,
) -> Separated<Self, Colon<(), (), Lang>, O, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
fn separated_by_colon(
self,
) -> Separated<Self, Colon<(), (), Lang>, O, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
many only.Separated combinator which separates elements by the colon separator and applies this parser repeatedly. Read moreSource§fn separated_by_pipe(
self,
) -> Separated<Self, Pipe<(), (), Lang>, O, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
fn separated_by_pipe(
self,
) -> Separated<Self, Pipe<(), (), Lang>, O, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
many only.Separated combinator which separates elements by the pipe separator and applies this parser repeatedly. Read moreSource§fn separated_by_ampersand(
self,
) -> Separated<Self, Ampersand<(), (), Lang>, O, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
fn separated_by_ampersand(
self,
) -> Separated<Self, Ampersand<(), (), Lang>, O, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
many only.Separated combinator which separates elements by the ampersand separator and applies this parser repeatedly. Read moreSource§fn separated_by_hyphen(
self,
) -> Separated<Self, Hyphen<(), (), Lang>, O, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
fn separated_by_hyphen(
self,
) -> Separated<Self, Hyphen<(), (), Lang>, O, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
many only.Separated combinator which separates elements by the hyphen separator and applies this parser repeatedly. Read moreSource§fn separated_by_underscore(
self,
) -> Separated<Self, Underscore<(), (), Lang>, O, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
fn separated_by_underscore(
self,
) -> Separated<Self, Underscore<(), (), Lang>, O, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
many only.Separated combinator which separates elements by the underscore separator and applies this parser repeatedly. Read moreSource§fn separated_by_double_colon(
self,
) -> Separated<Self, DoubleColon<(), (), Lang>, O, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
fn separated_by_double_colon(
self,
) -> Separated<Self, DoubleColon<(), (), Lang>, O, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
many only.Separated combinator which separates elements by the double_colon separator and applies this parser repeatedly. Read moreSource§fn separated_by_arrow(
self,
) -> Separated<Self, Arrow<(), (), Lang>, O, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
fn separated_by_arrow(
self,
) -> Separated<Self, Arrow<(), (), Lang>, O, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
many only.Separated combinator which separates elements by the arrow separator and applies this parser repeatedly. Read moreSource§fn separated_by_fat_arrow(
self,
) -> Separated<Self, FatArrow<(), (), Lang>, O, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
fn separated_by_fat_arrow(
self,
) -> Separated<Self, FatArrow<(), (), Lang>, O, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
many only.Separated combinator which separates elements by the fat_arrow separator and applies this parser repeatedly. Read moreSource§fn separated_by_tilde(
self,
) -> Separated<Self, Tilde<(), (), Lang>, O, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
fn separated_by_tilde(
self,
) -> Separated<Self, Tilde<(), (), Lang>, O, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
many only.Separated combinator which separates elements by the tilde separator and applies this parser repeatedly. Read moreSource§fn separated_by_slash(
self,
) -> Separated<Self, Slash<(), (), Lang>, O, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
fn separated_by_slash(
self,
) -> Separated<Self, Slash<(), (), Lang>, O, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
many only.Separated combinator which separates elements by the slash separator and applies this parser repeatedly. Read moreSource§fn separated_by_backslash(
self,
) -> Separated<Self, Backslash<(), (), Lang>, O, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
fn separated_by_backslash(
self,
) -> Separated<Self, Backslash<(), (), Lang>, O, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
many only.Separated combinator which separates elements by the backslash separator and applies this parser repeatedly. Read moreSource§fn separated_by_percent(
self,
) -> Separated<Self, Percent<(), (), Lang>, O, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
fn separated_by_percent(
self,
) -> Separated<Self, Percent<(), (), Lang>, O, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
many only.Separated combinator which separates elements by the percent separator and applies this parser repeatedly. Read moreSource§fn separated_by_dollar(
self,
) -> Separated<Self, Dollar<(), (), Lang>, O, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
fn separated_by_dollar(
self,
) -> Separated<Self, Dollar<(), (), Lang>, O, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
many only.Separated combinator which separates elements by the dollar separator and applies this parser repeatedly. Read moreSource§fn separated_by_hash(
self,
) -> Separated<Self, Hash<(), (), Lang>, O, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
fn separated_by_hash(
self,
) -> Separated<Self, Hash<(), (), Lang>, O, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
many only.Separated combinator which separates elements by the hash separator and applies this parser repeatedly. Read moreSource§fn separated_by_at(
self,
) -> Separated<Self, At<(), (), Lang>, O, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
fn separated_by_at(
self,
) -> Separated<Self, At<(), (), Lang>, O, L, Ctx, Lang, Cmpl>where
Self: Sized,
L: Lexer<'inp>,
L::Token: PunctuatorToken<'inp>,
Ctx: ParseContext<'inp, L, Lang>,
many only.Separated combinator which separates elements by the at separator and applies this parser repeatedly. Read moreAuto Trait Implementations§
impl<D, Sp, Sl> Forget for Located<D, Sp, Sl>
impl<D, Sp, Sl> Freeze for Located<D, Sp, Sl>
impl<D, Sp, Sl> Move for Located<D, Sp, Sl>
impl<D, Sp, Sl> RefUnwindSafe for Located<D, Sp, Sl>
impl<D, Sp, Sl> Send for Located<D, Sp, Sl>
impl<D, Sp, Sl> Sync for Located<D, Sp, Sl>
impl<D, Sp, Sl> Unpin for Located<D, Sp, Sl>
impl<D, Sp, Sl> UnsafeUnpin for Located<D, Sp, Sl>
impl<D, Sp, Sl> UnwindSafe for Located<D, Sp, Sl>
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<T> Source for T
impl<T> Source for T
Source§type Slice<'a> = <<T as Deref>::Target as Source>::Slice<'a>where
T: 'a,
type Slice<'a> = <<T as Deref>::Target as Source>::Slice<'a>where
T: 'a,
Source can be sliced into.Source§fn read<'a, Chunk>(&'a self, offset: usize) -> Option<Chunk>where
Chunk: Chunk<'a>,
fn read<'a, Chunk>(&'a self, offset: usize) -> Option<Chunk>where
Chunk: Chunk<'a>,
None when reading
out of bounds would occur. Read moreSource§fn slice(&self, range: Range<usize>) -> Option<<T as Source>::Slice<'_>>
fn slice(&self, range: Range<usize>) -> Option<<T as Source>::Slice<'_>>
slice::get(range). Read moreSource§unsafe fn slice_unchecked(
&self,
range: Range<usize>,
) -> <T as Source>::Slice<'_>
unsafe fn slice_unchecked( &self, range: Range<usize>, ) -> <T as Source>::Slice<'_>
forbid_unsafe only.slice::get_unchecked(range). Read more