aboutsummaryrefslogtreecommitdiff
path: root/src/assert.c
AgeCommit message (Collapse)AuthorFiles
2022-01-12Update copyright yearsSergey Poznyakoff1
2021-01-06Update copyright yearsSergey Poznyakoff1
2019-06-06BugfixSergey Poznyakoff1
* src/assert.c (grecs_assert_node_value_type): Fix return value.
2019-06-05Fix syntax checking of compound vs. scalar statements. Add assertion functions.Sergey Poznyakoff1
Up to now the parser incorrectly accepted the use of compound statement keyword in scalar context, unless the keyword description had non NULL value in the callback field. This change fixes it. It also defines several assertion functions for use inm callbacks. * src/tree.c (grecs_value_type_string): New function. (find_keyword): Take into account node type. (nodeproc,reduceproc): Leave error reporting to find_keyword. * tests/set.at: Change expected error string. * include/grecs/tree.h (grecs_assert_value_type) (grecs_assert_scalar_stmt) (grecs_assert_node_value_type): New protos. * include/grecs/value.h (grecs_value_type_string): New proto. * src/Make.am: Add assert.c * src/assert.c: New file. * src/format.c (grecs_data_type_string): Add i18n markers to the returned strings.

Return to:

Send suggestions and report system problems to the System administrator.