km: replace boost integer traits with numeric_limits.