This implementation follow some RFCs:
The last means we can parse something like:
A Group(Some people) :Chris Jones <c@(Chris's host.)public.example>, firstname.lastname@example.org, John <email@example.com> (my dear friend); (the end of the group)"
For a general purpose, it's not needed and is close e-mail purpose.
Then, for domain part (explained on RFC 5321 - SMTP protocol), we handle this kind of domain:
The parser of
IPv* is done by Ipaddr.
As a old specification, we handle multiple-domains like:
Obviously, we handle (nested) comments:
All parsers are binded with a comment which explain where you can find the ABNF description and some notes about implementation. All was check by hands.
If you think it's easy to parse an e-mail address, you should look tests.