RegEx Patterns -------------- Jangle uses a variety of regular expressions for validating and parsing language tags. All rules from the `RFC 5646 ABNF syntax definition `_ have now been implemented! .. note:: Some patterns are case-sensitive, which is incompliant with `RFC 5646 section 2.1 `_. `RULES` are compiled with the `I` flag -- always pass this flag if you are compiling elsewhere. Language-Tag: :regexp:`(?P(?Part\\-lojban|cel\\-gaulish|no\\-bok|no\\-nyn|zh\\-guoyo|zh\\-hakka|zh\\-min|zh\\-min\\-nan|zh\\-xiang)|(?Pen\\-GB\\-oed|i\\-(?:ami|bnn|default|enochian|hak|klingon|lux|mingo|navajo|tao|tay|tsu)|sgn\\-(?:BE\\-FR|BE\\-NL|CH\\-DE)))|(?Px(?:\\-[A-Za-z\\d]{1,8})+)|(?P(?P[A-Za-z]{2,3})(?:\\-(?P(?P[A-Za-z]{3})(?P(?:\\-[A-Za-z]{3}){0,2})))?(?![^\\-\\s])(?:\\-(?P