fixed duplicate syntax error reporting