You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
@@ -178,7 +179,7 @@ The behavior of the ``publish()`` function varies depending on the message type
178
179
- Ownership is moved from publisher to the first subscriber
179
180
- This is the recommended approach for intra-process communication
180
181
181
-
**Raw messages (both ``msg`` and ``std::move(msg)``):**
182
+
**Raw messages** (both ``msg`` and ``std::move(msg)``):
182
183
- Both result in copying
183
184
- No zero-copy benefits are obtained
184
185
- Use ``const &`` for subscription callbacks with raw messages
@@ -398,7 +399,7 @@ When a ``unique_ptr`` message is published and there are multiple intra-process
398
399
- This applies regardless of whether subscribers use ``unique_ptr`` or ``shared_ptr`` callbacks
399
400
400
401
Note that the image view nodes are not subscribed with ``unique_ptr`` callbacks.
401
-
Instead they are subscribed with ``const shared_ptr``s.
402
+
Instead they are subscribed with ``const shared_ptr``s.
402
403
This means the system delivers the original message to the first callback and copies to subsequent callbacks.
403
404
When the first intraprocess subscription is handled, the internally stored ``unique_ptr`` is promoted to a ``shared_ptr`` for delivery to multiple subscribers.
0 commit comments