Calling add_action on a filter hook?

add_action() and add_filter() are essentially the same thing, hooks, and they both call the same functions under the hood. If you look you’ll see WP_Hook::do_action() basically just calls WP_Hook::apply_filters().

An action is essentially just a filter that doesn’t return a value. If your callback function was supposed to modify the value of $role then that part wouldn’t work, because add_action() won’t pass the value through, but the callback will still run, as you’ve seen.