No, groupoids breaks the group operation and thus behaves like neither of the groups. Do type systems allow operations between union types? If not then it is just a simple interface in OO. If they do then you are no longer working with pure functions.