Destroying an object with running coroutine

Say you have the following two classes:

public class A : MonoBehavior {
  public IEnumerator HandleEvent(...) {...}
}

public class B : MonoBehavior {
  private A _a = new A();

  public Sample(...) {
    StartCoroutine( _a.HandleEvent(...));
    Destroy(_a);
  }
}

What would happen to the coroutine if you called Sampel()?

After testing this with an object that logs something to the console every frame via a coroutine and then destroying it shortly after the scene was loaded, i can say that coroutines that run in script attached the the destroyed object will stop when the object is destroyed.

I think it would stop, because a coroutine is not a seperate process or threat.

But this is only an idea