Skip to main content

name_slots

Function name_slots 

Source
pub(crate) unsafe fn name_slots<T: TypedExternal>(prot: SEXP)
Expand description

Names prot’s slots after T’s Sidecar fields. A save then keeps the names, so the version that reads it finds each field by name (saved_slot), whatever fields it added, removed or reordered since. The names vector is the type’s own, built once; this allocates only the attribute’s cell.

§Safety

On R’s main thread, with prot a rooted protection list built for a T.