1. override
void adoptChild(RenderObject child)

Called by subclasses when they decide a render object is a child.

Only for use by subclasses when changing their child lists. Calling this in other cases will lead to an inconsistent tree and probably cause crashes.

Source

@override
void adoptChild(RenderObject child) {
  // Make sure to call super first to setup the parent data
  super.adoptChild(child);
  final AutoLayoutParentData childParentData = child.parentData;
  childParentData._addImplicitConstraints();
  assert(child.parentData == childParentData);
}