A stage that failed without writing a message gets the stage's own. */
| 2041 | |
| 2042 | /* A stage that failed without writing a message gets the stage's own. */ |
| 2043 | static void parse_error_default(parser_t *p, const char *msg) { |
| 2044 | if (!p->error[0]) { |
| 2045 | snprintf(p->error, sizeof(p->error), "%s", msg); |
| 2046 | } |
| 2047 | } |
| 2048 | |
| 2049 | /* One MATCH ... RETURN block: the whole query, or one branch of a UNION. On |
| 2050 | * failure p->error holds the message and *out stays NULL. */ |