Add ConvertConstantToIntType() to unify all constant handling