refactoring of detection of unspecified limit.