mirror of
https://github.com/Gnucash/gnucash.git
synced 2026-09-03 20:53:02 -05:00
Clean up expression parser and calculation code.
Add in extra error handling for expression parser. git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@2829 57a11ea4-9604-0410-9ed3-97b8803252fd
This commit is contained in:
@@ -366,7 +366,7 @@ gnc_exp_parser_parse (const char * expression, double *value_p,
|
||||
|
||||
exit_parser (pe);
|
||||
|
||||
return (error_loc == NULL);
|
||||
return last_error == PARSER_NO_ERROR;
|
||||
}
|
||||
|
||||
const char *
|
||||
@@ -387,5 +387,7 @@ gnc_exp_parser_error_string (void)
|
||||
return PARSER_UNDEFINED_CHARACTER;
|
||||
case NOT_A_VARIABLE:
|
||||
return PARSER_NOT_A_VARIABLE;
|
||||
case PARSER_OUT_OF_MEMORY:
|
||||
return PARSER_OUT_OF_MEMORY_STR;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user