pub type RawMessageDeserializeFn = unsafe extern "C" fn(buffer: *const u8, buffer_size: usize, msg: *mut c_void) -> i32;Expand description
phase-417 W5.a โ the deserialiser half of the TYPED C subscription path.
Writes the CDR bytes at buffer[..buffer_size] into msg, which is storage
the CALLER owns and whose type only the caller knows. Returns 0 on success
and non-zero on failure; the executor treats any non-zero as
TransportError::DeserializationError and does NOT dispatch the callback.
This is the erased form of the generated <Msg>_deserialize, which already
has exactly this contract โ it writes into caller storage and returns
0/-1. There is no allocator on this path and none is needed: caller-owned
storage is the whole mechanism, which is also how rclc delivers a typed
message without one.
ยงSafety
msg must point to writable storage of the type this deserialiser was
generated for; buffer is valid for buffer_size bytes during the call.