Type checking enhancement