Bugfix for last introduced feature, improve syntax error reporting