boolean shouldReformatPreviouslyLocatedDependentSpacing(WhiteSpace space) {
    final TextRange changed = space.getTextRange();
    final SortedMap<TextRange, LeafBlockWrapper> sortedHeadMap = myPreviousDependencies.tailMap(changed);

    for (final Map.Entry<TextRange, LeafBlockWrapper> entry : sortedHeadMap.entrySet()) {
      final TextRange textRange = entry.getKey();

      if (textRange.contains(changed)) {
        final LeafBlockWrapper currentBlock = entry.getValue();
        if (!(currentBlock.getSpaceProperty() instanceof DependantSpacingImpl spacing) ||
            spacing.isDependentRegionLinefeedStatusChanged(myIteration)) {
          continue;
        }

        final boolean containedLineFeeds = spacing.getMinLineFeeds() > 0;
        final boolean containsLineFeeds = myBlockRangesMap.containsLineFeedsOrTooLong(textRange);

        if (containedLineFeeds != containsLineFeeds) {
          if (!spacing.isDependantSpacingChangedAtLeastOnce()) {
            spacing.setDependentRegionLinefeedStatusChanged(myIteration);
            return true;
          }
          else if (containsLineFeeds) {
            spacing.setDependentRegionLinefeedStatusChanged(myIteration);
            myLeafBlocksToReformat.add(currentBlock);
            return false;
          }
        }
      }
    }

    return false;
  }
boolean shouldReformatPreviouslyLocatedDependentSpacing(WhiteSpace space)