Skip to main content

jit_arc_string_retain

Function jit_arc_string_retain 

Source
#[unsafe(no_mangle)]
pub extern "C" fn jit_arc_string_retain(bits: u64)
Expand description

Retain (clone) an Arc<String> strong-count share. Bumps the standard Rust Arc refcount at offset -16 of the Arc::into_raw pointer via Arc::increment_strong_count::<String> — NOT the W-series UnifiedValue<T> refcount at offset 4 (jit_arc_retain’s shape).

SAFETY: bits must be Arc::into_raw(Arc<String>) as u64 produced by the MirConstant::Str / MirConstant::StringId lowering in mir_compiler/ownership.rs::compile_constant, or by the VM-side KindedSlot::from_string_arc producer. Null is silently no-op’d (mirror of Round 7A’s jit_arc_result_retain null-bits safety).