1. Pypy
  2. Untitled project
  3. pypy

Commits

Carl Friedrich Bolz  committed 6f53326

add a paragraph about coroutine death

  • Participants
  • Parent commits b3a8d16
  • Branches documentation-cleanup

Comments (0)

Files changed (1)

File pypy/doc/stackless.rst

View file
  • Ignore whitespace
     will come from any call to ``coro.switch()`` and can be caught. If the
     exception isn't caught, it will be propagated to the parent coroutine.
 
+When a coroutine is garbage-collected, it gets the ``.kill()`` method sent to
+it. This happens at the point the next ``.switch`` method is called, so the
+target coroutine of this call will be executed only after the ``.kill`` has
+finished.
+
 Example
 ~~~~~~~