mirror of https://github.com/vitalif/openscad
bugfix: parser errors wasn't treated correctly, causing cmd-line tools to return without an error code, as well as error highlighting in the editor being broken
parent
3b6f16605c
commit
fa9811c0f3
|
@ -566,11 +566,11 @@ Module *parse(const char *text, const char *path, int debug)
|
||||||
// PRINTB_NOCACHE("New module: %s %p", "root" % rootmodule);
|
// PRINTB_NOCACHE("New module: %s %p", "root" % rootmodule);
|
||||||
|
|
||||||
parserdebug = debug;
|
parserdebug = debug;
|
||||||
parserparse();
|
int parserretval = parserparse();
|
||||||
lexerdestroy();
|
lexerdestroy();
|
||||||
lexerlex_destroy();
|
lexerlex_destroy();
|
||||||
|
|
||||||
if (!rootmodule) return NULL;
|
if (parserretval != 0) return NULL;
|
||||||
|
|
||||||
parser_error_pos = -1;
|
parser_error_pos = -1;
|
||||||
return rootmodule;
|
return rootmodule;
|
||||||
|
|
Loading…
Reference in New Issue