Commit 25cad09
codegen: emit Rust type aliases for scalar RPC result schemas
The Rust codegen only emitted a named type for result schemas that were an
enum, array, map, or object. A method whose result is an inline primitive
(e.g. {"type":"integer"}) produced a reference to a type that was never
defined, so the generated crate failed to compile with E0425.
No RPC method had a primitive result until session.cancelAllBackgroundAgents
was added, so this latent gap only surfaces on a schema update. Add
rustScalarType()/emitRustScalarAlias() so scalar results emit a plain type
alias alongside the existing shapes.
This is a no-op against the current pinned schema and prevents the next
dependency bump from hitting the same build break.
Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
Copilot-Session: e615d062-bcb7-431e-aa9c-d3e47405723a1 parent 6563591 commit 25cad09
1 file changed
Lines changed: 43 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
575 | 575 | | |
576 | 576 | | |
577 | 577 | | |
| 578 | + | |
| 579 | + | |
| 580 | + | |
| 581 | + | |
| 582 | + | |
| 583 | + | |
| 584 | + | |
| 585 | + | |
| 586 | + | |
| 587 | + | |
| 588 | + | |
| 589 | + | |
| 590 | + | |
| 591 | + | |
| 592 | + | |
| 593 | + | |
| 594 | + | |
| 595 | + | |
| 596 | + | |
| 597 | + | |
| 598 | + | |
| 599 | + | |
| 600 | + | |
| 601 | + | |
| 602 | + | |
| 603 | + | |
| 604 | + | |
| 605 | + | |
| 606 | + | |
| 607 | + | |
| 608 | + | |
| 609 | + | |
| 610 | + | |
| 611 | + | |
| 612 | + | |
| 613 | + | |
| 614 | + | |
| 615 | + | |
| 616 | + | |
578 | 617 | | |
579 | 618 | | |
580 | 619 | | |
| |||
1527 | 1566 | | |
1528 | 1567 | | |
1529 | 1568 | | |
| 1569 | + | |
| 1570 | + | |
1530 | 1571 | | |
1531 | 1572 | | |
1532 | 1573 | | |
| |||
1576 | 1617 | | |
1577 | 1618 | | |
1578 | 1619 | | |
| 1620 | + | |
| 1621 | + | |
1579 | 1622 | | |
1580 | 1623 | | |
1581 | 1624 | | |
| |||
0 commit comments