Function nom::character::is_newline

source ·
pub fn is_newline(chr: u8) -> bool
Expand description

Tests if byte is ASCII newline: \n

Example

assert_eq!(is_newline(b'\n'), true);
assert_eq!(is_newline(b'\r'), false);
assert_eq!(is_newline(b' '), false);
assert_eq!(is_newline(b'\t'), false);