2
0
mirror of https://github.com/m-labs/artiq.git synced 2024-12-24 10:54:02 +08:00

wrpll/thls: stop at return statement

This commit is contained in:
Sebastien Bourdeauducq 2019-07-19 16:27:29 +08:00
parent 34222b3f38
commit 831b3514d3

View File

@ -286,6 +286,8 @@ def compile(processor, function):
arg_r = astcompiler.input(arg)
for node in body:
astcompiler.emit(node)
if isinstance(node, ast.Return):
break
scheduler = Scheduler(processor, len(astcompiler.data), astcompiler.program)
scheduler.schedule()