Add range check.