refactored type variables