| 1502 | } |
| 1503 | |
| 1504 | static void gc_const_value(const gc_scope_t *sc, const char *dir, const char *name, int depth, |
| 1505 | gc_val_t *out) { |
| 1506 | CBMHashTable *t = gc_consts(sc->g, dir); |
| 1507 | const char *expr = t ? cbm_ht_get(t, name) : NULL; |
| 1508 | if (!expr) { |
| 1509 | out->known = false; |
| 1510 | return; |
| 1511 | } |
| 1512 | gc_scope_t inner = {sc->g, sc->text, dir, NULL, NULL, NULL, NULL}; |
| 1513 | gc_eval(&inner, expr, strlen(expr), depth + SKIP_ONE, out); |
| 1514 | } |
| 1515 | |
| 1516 | static void gc_eval(const gc_scope_t *sc, const char *s, size_t n, int depth, gc_val_t *out) { |
| 1517 | *out = (gc_val_t){.known = false}; |
no test coverage detected