On several occasions I’ve had this need to implement a Protocol for all modules implementing one other particular Protocol e.g.
defimpl Viewable, for: Doable do
..
end
One could argue to merge the two protocols into one, but in those few particular cases it is not applicable over the separation of concerns, as the protocols themselves are defined in two completely separate parts of the application and their respective implementations are more like two different behavioral aspects than just the protocols (i.e. they are not just wrapping the function calls to the structure modules but providing some additional behavior as well).
Any thoughts?