| 4756 | #endif |
| 4757 | |
| 4758 | static void py_bind_module_class(PyLSPContext *ctx, TSNode class_node) { |
| 4759 | if (!ctx || ts_node_is_null(class_node) || !ctx->module_qn) |
| 4760 | return; |
| 4761 | TSNode name_node = ts_node_child_by_field_name(class_node, "name", 4); |
| 4762 | char *name = py_node_text(ctx, name_node); |
| 4763 | if (!name || !name[0]) { |
| 4764 | py_disable_callable_value_proof(ctx); |
| 4765 | return; |
| 4766 | } |
| 4767 | const char *qn = cbm_arena_sprintf(ctx->arena, "%s.%s", ctx->module_qn, name); |
| 4768 | if (!qn) { |
| 4769 | py_disable_callable_value_proof(ctx); |
| 4770 | py_scope_bind(ctx, name, cbm_type_unknown()); |
| 4771 | return; |
| 4772 | } |
| 4773 | const CBMRegisteredType *type = cbm_registry_lookup_type(ctx->registry, qn); |
| 4774 | py_scope_bind(ctx, name, |
| 4775 | type ? cbm_type_named(ctx->arena, type->qualified_name) : cbm_type_unknown()); |
| 4776 | } |
| 4777 | |
| 4778 | /* Preserve the historical registry fallback for an unshadowed function: it |
| 4779 | * keeps ordinary direct-call resolution stable. When a definition actually |
no test coverage detected