911f3a8012
Related issue: #49301 We have an invariant to make sure stubs aren't created across other libraries but really the invariant should test for other components, as it's valid to have two libraries call each other's factories. Similarly, stubs need to be added to the class before we clone the body, as the body may mutually recurse. Tests are changed to reflect this. Change-Id: I529b682f107a55791a52fa79f082cc8ef5fce1f3 Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/249546 Reviewed-by: Riley Porter <rileyporter@google.com>