Implementation of Outside-In(Type equalities + type families + type classes)