Guard against undefined range