Skip to main content

borrowed_str

Function borrowed_str 

Source
pub fn borrowed_str(out: &mut CodeValue, s: &'static CStr)
Expand description

Write a Str into out, borrowing s for 'static (a string literal or otherwise permanently-alive buffer) rather than copying it — matching code_str’s own borrowing contract. Use owned_str for a value built at runtime that needs its own heap block.