Improve error reporting in Parser Library