diff --git a/artiq/compiler/embedding.py b/artiq/compiler/embedding.py index 424468bc1..cfeff698f 100644 --- a/artiq/compiler/embedding.py +++ b/artiq/compiler/embedding.py @@ -504,7 +504,7 @@ class Stitcher: syscall=None) def _quote(self, value, loc): - if inspect.isfunction(value): + if inspect.isfunction(value) or inspect.ismethod(value): # It's a function. We need to translate the function and insert # a reference to it. function_name = self._quote_function(value, loc)