Regex bug fixes, expanded doc comment, formatting and typo in the readme.