`prefixVar + "/route"` (Go's idiomatic configurable-base-path pattern): recover the literal suffix. A right side that is not itself a literal is left unresolved rather than guessed (issue #1249).
| 2779 | // recover the literal suffix. A right side that is not itself a literal is |
| 2780 | // left unresolved rather than guessed (issue #1249). |
| 2781 | static const char *extract_binary_concat_suffix(CBMExtractCtx *ctx, TSNode node) { |
| 2782 | TSNode op_node = ts_node_child_by_field_name(node, TS_FIELD("operator")); |
| 2783 | if (!ts_node_is_null(op_node)) { |
| 2784 | char *op = cbm_node_text(ctx->arena, op_node, ctx->source); |
| 2785 | if (!op || strcmp(op, "+") != 0) { |
| 2786 | return NULL; |
| 2787 | } |
| 2788 | } |
| 2789 | TSNode rhs = ts_node_child_by_field_name(node, TS_FIELD("right")); |
| 2790 | if (ts_node_is_null(rhs) || !is_string_like(ts_node_type(rhs))) { |
| 2791 | return NULL; |
| 2792 | } |
| 2793 | return strip_and_validate_string_arg(ctx->arena, cbm_node_text(ctx->arena, rhs, ctx->source)); |
| 2794 | } |
| 2795 | |
| 2796 | // Try to extract URL/topic from a positional argument (string or constant). |
| 2797 | /* Swift names its call arguments, so each one is a value_argument that may lead |
no test coverage detected