Typically, drivers will use a lambda that captures this when using static_callable. When the object is moved, this points to invalid memory. The move constructor should do the work of reestablishing the interrupt to point to the new location. At this moment, this operation is not trivial and must be done manually for each platform driver that utilizes interrupts/static callable, unfortunately.
Typically, drivers will use a lambda that captures
this
when usingstatic_callable
. When the object is moved,this
points to invalid memory. The move constructor should do the work of reestablishing the interrupt to point to the new location. At this moment, this operation is not trivial and must be done manually for each platform driver that utilizes interrupts/static callable, unfortunately.https://en.cppreference.com/w/cpp/types/is_move_constructible https://en.cppreference.com/w/cpp/types/is_move_assignable