time/parsing/combinator/rfc/rfc2234.rs
//! Rules defined in [RFC 2234].
//!
//! [RFC 2234]: https://datatracker.ietf.org/doc/html/rfc2234
use crate::parsing::ParsedItem;
/// Consume exactly one space or tab.
pub(crate) const fn wsp(input: &[u8]) -> Option<ParsedItem<'_, ()>> {
match input {
[b' ' | b'\t', rest @ ..] => Some(ParsedItem(rest, ())),
_ => None,
}
}