anchor.diff:          if AvlTree.isEmpty stream then
               input
           else
  +            #if DEBUG
  +            /// The minimum possible number of elements in the resulting set.
  +            let minPossibleResultCount =
  +                let inputCount = count measurer input
  +                let streamCount = count measurer stream
  +
  +                if inputCount > streamCount then
  +                    inputCount - streamCount
  +                else 0
  +            #endif
  +
               let head, stream = AvlTree.extractMin measurer stream
               let result, _, _ = diff' input (Some head) stream
  +
  +            #if DEBUG
  +            let resultCount = count measurer result
  +            Debug.Assert (
  +                resultCount >= minPossibleResultCount,
  +                sprintf "The result set should not contain fewer than %i elements, but it contains only %i elements."
  +                    minPossibleResultCount resultCount)
  +            #endif
  +
               result
   
       /// Comparison function for DIETs.
  
positive.code:         else
              Range (minValue, maxValue)
              |> AvlTree.singleton
  
      //
      let rec private addRec (measurer : IMeasurer<_>) p (tree : Diet<'T>) cont : Diet<_> =
  
negative.code:             folder p state
  
          AvlTree.foldBack rangeFolder tree state
  
      /// Returns the number of intervals in the set.
      let intervalCount (t : Diet<'T>) =
  