Returns a fresh empty list handle owned by the guest.
()
| 557 | |
| 558 | /// Returns a fresh empty list handle owned by the guest. |
| 559 | pub fn new_list() -> Result<Handle> { |
| 560 | let mut out: u32 = 0; |
| 561 | let r = unsafe { |
| 562 | edge_op(op::NEW_LIST, 0, core::ptr::null(), 0, core::ptr::null(), 0, &mut out as *mut u32) |
| 563 | }; |
| 564 | if r != 0 { return Err(last_error()); } |
| 565 | Ok(Handle::from_raw(out)) |
| 566 | } |
| 567 | |
| 568 | /// Construct a tuple from item handles in one host call. |
| 569 | pub fn new_tuple(items: &[u32]) -> Result<Handle> { Self::new_composite(op::NEW_TUPLE, items) } |
nothing calls this directly
no test coverage detected