2015-10-09 06:37:28 +08:00
|
|
|
# RUN: env ARTIQ_DUMP_IR=1 %python -m artiq.compiler.testbench.embedding +compile %s 2>%t
|
|
|
|
# RUN: OutputCheck %s --file-to-check=%t
|
|
|
|
|
|
|
|
from artiq.language.core import *
|
|
|
|
from artiq.language.types import *
|
|
|
|
|
2015-12-02 21:48:14 +08:00
|
|
|
# CHECK-L: call ()->NoneType %local.testbench.entrypoint ; calls testbench.entrypoint
|
2015-10-09 06:37:28 +08:00
|
|
|
|
|
|
|
@kernel
|
|
|
|
def baz():
|
|
|
|
pass
|
|
|
|
|
|
|
|
class foo:
|
|
|
|
@kernel
|
|
|
|
def bar(self):
|
|
|
|
# CHECK-L: call ()->NoneType %local.testbench.baz ; calls testbench.baz
|
|
|
|
baz()
|
|
|
|
x = foo()
|
|
|
|
|
|
|
|
@kernel
|
|
|
|
def entrypoint():
|
|
|
|
x.bar()
|