Added capabilities for re.search and re.match

In addition, improved test coverage and error handling