Primary
''generator iterator'' ⚬|Definition|1st|20260605182851-00-⌔
Glossary — Python 3.14.2 documentation#term-generator-iterator
generator iterator
An object created by a generator function or a generator expression.
Each
yieldtemporarily suspends processing, remembering the execution state (including local variables and pending try-statements). When the generator iterator resumes, it picks up where it left off (in contrast to functions which start fresh on every invocation).Generator iterators also implement the
send()method to send a value into the suspended generator, and thethrow()method to raise an exception at the point where the generator was paused. See Generator-iterator methods.Printed 2026-06-28.
(echo:: @ ᯤ)
Link to original
Secondary
• • •