Constant MAX

const MAX: char = '\u{10ffff}'

The highest valid code point a char can have, '\u{10FFFF}'. Use char::MAX instead.