Copy stack slots from the callee into the caller.
(func: &mut ir::Function, callee: &ir::Function)
| 1551 | |
| 1552 | /// Copy stack slots from the callee into the caller. |
| 1553 | fn create_stack_slots(func: &mut ir::Function, callee: &ir::Function) -> u32 { |
| 1554 | let offset = func.sized_stack_slots.len(); |
| 1555 | let offset = u32::try_from(offset).unwrap(); |
| 1556 | |
| 1557 | func.sized_stack_slots |
| 1558 | .reserve(callee.sized_stack_slots.len()); |
| 1559 | for slot in callee.sized_stack_slots.values() { |
| 1560 | func.sized_stack_slots.push(slot.clone()); |
| 1561 | } |
| 1562 | |
| 1563 | offset |
| 1564 | } |
| 1565 | |
| 1566 | /// Copy dynamic types from the callee into the caller. |
| 1567 | fn create_dynamic_types( |