diff options
| author | 2024-01-27 13:26:11 +0800 | |
|---|---|---|
| committer | 2024-01-27 13:26:11 +0800 | |
| commit | 26c56c456764baffbefa804fd5e80be2fb5a936d (patch) | |
| tree | f3c32ee5b22a770e9393c290d6dcf6f0e2ee22b2 /src | |
| parent | c367c9490021d28ea18adc6b5c7ac344d9129437 (diff) | |
| download | infini-26c56c456764baffbefa804fd5e80be2fb5a936d.tar.gz infini-26c56c456764baffbefa804fd5e80be2fb5a936d.zip | |
:construction: to(yield): add todo for iterator supports
Diffstat (limited to 'src')
| -rw-r--r-- | src/infini/handler.py | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/infini/handler.py b/src/infini/handler.py index ae3561f8..dd6c7fd7 100644 --- a/src/infini/handler.py +++ b/src/infini/handler.py @@ -14,6 +14,10 @@ class Handler: return while not queue.is_empty(): output = queue.pop()(input) + # TODO 允许 Handler 函数为迭代器 + # if isinstance(output, GeneratorType): + # for o in output: + # yield o yield output if output.block: return |
