The superclass of type ti, as a type of the index. */
| 658 | |
| 659 | /* The superclass of type ti, as a type of the index. */ |
| 660 | static pr_res_t pr_parent(const pr_ctx_t *c, int ti) { |
| 661 | const pr_type_t *t = &c->ix->types[ti]; |
| 662 | for (int i = 0; i < t->nbases; i++) { |
| 663 | if (t->bases[i].rel == 'e' && t->bases[i].fqn) { |
| 664 | pr_res_t r = pr_find_type(c, t->bases[i].fqn, strlen(t->bases[i].fqn)); |
| 665 | return r.kind == PR_NONE ? pr_mk(PR_EXTERNAL) : r; |
| 666 | } |
| 667 | } |
| 668 | return pr_mk(PR_MISSING); |
| 669 | } |
| 670 | |
| 671 | /* The type a reference's type part names. */ |
| 672 | static pr_res_t pr_type_of(const pr_ctx_t *c, const pr_ref_t *r) { |
no test coverage detected