Test, validate and match regular expressions
Validates email addresses per RFC 5322 local-part rules, allowing alphanumeric characters plus special symbols like !#$%&'*+-/=?^_`{|}~ with optional dot-separated segments. The domain requires one or more dot-separated labels that begin and end with alphanumerics, with hyphens permitted in between. This is the pattern used by the Yii PHP framework's built-in email validator. Note it doesn't enforce a minimum TLD length or overall size limits.