mod newline;
mod number;
mod token;
mod whitespace;
mod unicode_identifier;
use crate::{
Character,
TextInput
};
use pups_core::{
Input,
Parser,
};
use newline::Newline;
use number::Number;
use token::Token;
use whitespace::Whitespace;
use crate::parsers::unicode_identifier::UnicodeIdentifier;
pub const fn newline<'a, C, I>() -> impl Parser<'a, I, Output = (), Error = (), Message = ()>
where
C: Character,
I: Input<'a, Item = C> + TextInput,
{ Newline }
pub const fn number<'a, C, I>(
) -> impl Parser<'a, I, Output = I::Slice, Error = (), Message = ()>
where
C: Character,
I: Input<'a, Item = C> + TextInput,
{ Number }
pub const fn token<'a, I>(
lexeme: &'static str
) -> impl Parser<'a, I, Output = &'static str, Error = (), Message = ()>
where
I: Input<'a> + TextInput,
{ Token (lexeme) }
pub const fn unicode_identifier<'a, C, I>(
) -> impl Parser<'a, I, Output = I::Slice, Error = (), Message = ()>
where
C: Character,
I: Input<'a, Item = C> + TextInput,
{ UnicodeIdentifier }
pub const fn whitespace<'a, C, I>(
) -> impl Parser<'a, I, Output = I::Slice, Error = (), Message = ()>
where
C: Character,
I: Input<'a, Item = C> + TextInput,
{ Whitespace }