Open kfabian opened 9 months ago
Hm, the fact that none of them implement it means the API should probably be deprecated and removed. I think this was part of an early attempt to be able to send preallocated messages, but never got implemented. @mjcarroll can you comment here?
I think that is the origin of it. I think that the loaned message APIs came after and superceded this concept. I think we can safely deprecate and remove the existing APIS.
Second, I think that the idea of working on a message instance may work as well. The Sequence__bound
structure was intended to provide bounds for unbounded sequence fields so that allocation size could be correctly computed.
Feature request
Feature description
I noticed that none of the major rmw implementations implements
rmw_get_serialized_message_size
. I wonder if that is the case because it works on therosidl_runtime_c__Sequence__bound
struct and not an actual instance of a message. I could not really grasp how therosidl_runtime_c__Sequence__bound
should be used and to what structure* data
should be pointing to.Implementation considerations
Maybe it would be helpful to add a function interface that works on an actual instance of a message, that should be more straightforward to implement, e.g. for cyclonedds similar to this code.