The dissolve algorithm, if this is correct, handles inner rings.
Reversing the direction from right to left changes the traversal
from clockwise to counterclockwise without changing the logic.
Almost magical.