Any benefits of using publish(object), over publish(unique_ptr)?
According to Intra-Process Communication Tutorial, Unique Pointers must be used when publishing to achieve zero-copy transport of messages.
However, most packages out there don't publish unique pointers, but publish an object, which from my understanding disallows intra-process communication.
I'm trying to compose nodes from 3rd party packages, but I'm having to modify the publish calls in the packages to use unique_ptrs.
Is there a reason that the "standard" isn't to use Unique Pointers? What's the benefit of not using unique pointers... (readability maybe?)
Asked by ijnek on 2021-08-09 23:47:15 UTC
Comments