OpenCyphal-Garage/libcyphal

HeatbeatProducer and Node are moved on creation

Opened this issue · 0 comments

There are several problems leading to multiple HeartbeatProducer and Node move constructor invocations on startup. The first is returning instances for functions returning variants. Instead the cetl::pf17::in_place_type constructors should be used (e.g. node.hpp:60). After this, the heartbeat producer is moved again into the node immediately after it was created. This triggers setting up then tearing down nodes in the AVL graph (i.e. this is not trivial). We need a way to instantiate a node without move-constructing the producers used.