anchor.diff:      String joiner = ', ',
       DiagnosticLevel minLevel = DiagnosticLevel.debug,
     }) {
  -    RenderObject? debugPreviousActiveLayout;
  -    assert(() {
  -      debugPreviousActiveLayout = _debugActiveLayout;
  -      _debugActiveLayout = null;
  -      return true;
  -    }());
  -    final String result = super.toStringShallow(joiner: joiner, minLevel: minLevel);
  -    assert(() {
  -      _debugActiveLayout = debugPreviousActiveLayout;
  -      return true;
  -    }());
  -    return result;
  +    return _withDebugActiveLayoutCleared(() => super.toStringShallow(joiner: joiner, minLevel: minLevel));
     }
   
     @protected
  
positive.code:     String? prefixOtherLines = '',
      DiagnosticLevel minLevel = DiagnosticLevel.debug,
    }) {
      RenderObject? debugPreviousActiveLayout;
      assert(() {
        debugPreviousActiveLayout = _debugActiveLayout;
        _debugActiveLayout = null;
        return true;
      }());
      final String result = super.toStringDeep(
        prefixLineOne: prefixLineOne,
        prefixOtherLines: prefixOtherLines,
        minLevel: minLevel,
      );
      assert(() {
        _debugActiveLayout = debugPreviousActiveLayout;
        return true;
      }());
      return result;
    }
  
    /// Returns a one-line detailed description of the render object.
  
negative.code:   /// null.
    static RenderObject? get debugActiveLayout => _debugActiveLayout;
    static RenderObject? _debugActiveLayout;
  
    /// Set [debugActiveLayout] to null when [inner] callback is called.
    /// This is useful when you have to temporarily clear that variable to
    /// disable some false-positive checks, such as when computing toStringDeep
    /// or using custom trees.
    @pragma('vm:prefer-inline')
    static T _withDebugActiveLayoutCleared<T>(T Function() inner) {
      RenderObject? debugPreviousActiveLayout;
      assert(() {
        debugPreviousActiveLayout = _debugActiveLayout;
        _debugActiveLayout = null;
        return true;
      }());
      final T result = inner();
      assert(() {
        _debugActiveLayout = debugPreviousActiveLayout;
        return true;
      }());
      return result;
    }
  
    /// Whether the parent render object is permitted to use this render object's
    /// size.
  