diff options
-rw-r--r-- | src/parse/css21.c | 2 | ||||
-rw-r--r-- | test/parse.c | 15 |
2 files changed, 14 insertions, 3 deletions
diff --git a/src/parse/css21.c b/src/parse/css21.c index caaacd3..a1f3516 100644 --- a/src/parse/css21.c +++ b/src/parse/css21.c @@ -289,8 +289,6 @@ css_error handleStartAtRule(css_css21 *c, const parserutils_vector *vector) parserutils_error perror; context_entry entry = { CSS_PARSER_START_ATRULE, NULL }; - UNUSED(vector); - assert(c != NULL); /* vector contains: ATKEYWORD ws any0 */ diff --git a/test/parse.c b/test/parse.c index dff11a1..25d1759 100644 --- a/test/parse.c +++ b/test/parse.c @@ -11,6 +11,19 @@ #include "testutils.h" +static const char *event_names[] = { + "START_STYLESHEET", + "END_STYLESHEET", + "START_RULESET", + "END_RULESET", + "START_ATRULE", + "END_ATRULE", + "START_BLOCK", + "END_BLOCK", + "BLOCK_CONTENT", + "DECLARATION" +}; + static void *myrealloc(void *ptr, size_t len, void *pw) { UNUSED(pw); @@ -31,7 +44,7 @@ static css_error event_handler(css_parser_event type, UNUSED(pw); - printf("%s%d", tokens != NULL ? " " : "", type); + printf("%s%s", tokens != NULL ? " " : "", event_names[type]); if (tokens == NULL) { printf("\n"); |