expr/irc-message — pull request #14 by welwood08 (2014-10-14 07:09:42+00:00)
Title: A message must have a non-empty command

I'm not sure how strict this parser is intended to be, but I have a light wrapper around it to make a transform stream and was writing tests when I encountered a few unexpected failures.

According to the pseudo BNF in RFC1459, the command part of a message is required and must be at least 1 character (1+ letters or exactly 3 digits, but that's a separate issue if it's wanted). This change makes the parser treat empty string and things like ": " as malformed in the same way that it already treats ":".