replaced (int, long) with six.integer_types