Variable type checker utility