Fix #17067 by making data family type constructors actually injective