Add an iterator `foreach_action_slot_use_with_references(ID, callback)` that provides references to the found `bAction` pointer and slot handle. That way the callback can assign another Action or slot when it sees fit, without having to know exactly what the source of this info is (could be a direct assignment, but also an NLA strip or Action Constraint). Ref: #127844 Pull Request: https://projects.blender.org/blender/blender/pulls/127871