7 ms·
I use them for reading large files that need to be parsed. A token might require a complex decode, so the generator fires once per token, but keeps the state o
by sbf501 4y ago
I use them for reading large files that need to be parsed.
A token might require a complex decode, so the generator fires once per token, but keeps the state of the file structure and the parser.
It greatly simplifies the code.