docs: public <T extends CharSequence> T validIndex(final T chars, final int index, final String message) {
          notNull(chars);
          if (index < 0 || index >= chars.length()) {
              failIndexOutOfBounds(message);
          }
          return chars;
      }