Enter one level of recursive descent. Returns false when the cap is hit, in * which case the caller must return NULL without recursing. */
| 457 | /* Enter one level of recursive descent. Returns false when the cap is hit, in |
| 458 | * which case the caller must return NULL without recursing. */ |
| 459 | static bool parse_depth_enter(parser_t *p) { |
| 460 | if (p->depth >= CYPHER_MAX_PARSE_DEPTH) { |
| 461 | snprintf(p->error, sizeof(p->error), "expression nested deeper than %d levels", |
| 462 | CYPHER_MAX_PARSE_DEPTH); |
| 463 | return false; |
| 464 | } |
| 465 | p->depth++; |
| 466 | return true; |
| 467 | } |
| 468 | |
| 469 | static void parse_depth_leave(parser_t *p) { |
| 470 | p->depth--; |
no outgoing calls
no test coverage detected