yml: add line/column info to every node

This commit is contained in:
Daniel Eklöf 2019-01-11 23:20:06 +01:00
parent 3f578d30eb
commit d922bc572f
2 changed files with 28 additions and 5 deletions

3
yml.h
View file

@ -39,5 +39,8 @@ const char *yml_value_as_string(const struct yml_node *value);
long yml_value_as_int(const struct yml_node *value);
bool yml_value_as_bool(const struct yml_node *value);
size_t yml_source_line(const struct yml_node *node);
size_t yml_source_column(const struct yml_node *node);
/* For debugging, prints on stdout */
void print_node(const struct yml_node *n);