docs: private void checkAndUpdate(DurationFieldType type, int[] values, int newValue) {
          int index = indexOf(type);
          if (index == -1) {
              if (newValue != 0) {
                  throw new IllegalArgumentException(
                      "Period does not support field '" + type.getName() + "'");
              }
          } else {
              values[index] = newValue;
          }
      }