Function pretty_regex::whitespace

source ·
pub fn whitespace() -> PrettyRegex<CharClass<Standart>>
Expand description

Matches whitespace character class (\s).

Example

assert!(whitespace().to_regex_or_panic().is_match("\n"));
assert!(whitespace().to_regex_or_panic().is_match(" "));
assert!(!whitespace().to_regex_or_panic().is_match("a"));