summaryrefslogtreecommitdiff
path: root/tests/compile/complex_decorators.pyx
diff options
context:
space:
mode:
Diffstat (limited to 'tests/compile/complex_decorators.pyx')
-rw-r--r--tests/compile/complex_decorators.pyx10
1 files changed, 10 insertions, 0 deletions
diff --git a/tests/compile/complex_decorators.pyx b/tests/compile/complex_decorators.pyx
new file mode 100644
index 000000000..e8d65244d
--- /dev/null
+++ b/tests/compile/complex_decorators.pyx
@@ -0,0 +1,10 @@
+# mode: compile
+
+cimport cython
+
+# Complex numbers defined in "cython.locals" weren't having their utility code imported directly
+# leading to compile-errors that the type wasn't defined. The test is intentionally minimal since
+# anything more thorough ends up creating the utility code
+@cython.locals(x=complex)
+cdef f(x):
+ pass