A name the repository does not declare: missing inside one of its * namespaces, else external. */
| 629 | /* A name the repository does not declare: missing inside one of its |
| 630 | * namespaces, else external. */ |
| 631 | static pr_res_t pr_absent(const pr_ctx_t *c, const char *fqn, size_t len) { |
| 632 | const char *bs = memchr(fqn, '\\', len); |
| 633 | char key[PR_NAME_MAX]; |
| 634 | size_t rl = bs ? (size_t)(bs - fqn) : 0; |
| 635 | if (!rl || rl >= sizeof(key)) { |
| 636 | return pr_mk(PR_EXTERNAL); |
| 637 | } |
| 638 | pr_lower_into(key, fqn, rl); |
| 639 | return pr_mk(cbm_ht_get(c->ix->roots, key) ? PR_MISSING : PR_EXTERNAL); |
| 640 | } |
| 641 | |
| 642 | /* True when the first segment of `name` is a class-use alias. */ |
| 643 | static bool pr_aliased(const pr_ctx_t *c, const char *name, size_t len) { |
no test coverage detected