Skip to main content

spawn_tree_uninitialized

Function spawn_tree_uninitialized 

Source
pub fn spawn_tree_uninitialized(
    ce: &MaterializedCE,
    world: &mut World,
    emit: &mut dyn SignalEmitter,
) -> Result<ComponentId, String>
Expand description

Like spawn_tree, but does not attach to a parent and does not run init_component_tree. The resulting subtree exists in the World’s component slotmap as a detached, uninitialised tree, addressable by the returned ComponentId.

Used by HostCallKind::Register so that let x = CE can produce a live ComponentId without committing the tree to the live world graph yet. A later Attach HostCall (or splice as a CeChild::Attach inside another CE body) places it and runs init.