From 83323b2d5196389e7b50add47c9d395443c86a0d Mon Sep 17 00:00:00 2001 From: Robert Bradshaw Date: Fri, 3 Apr 2009 15:57:01 -0700 Subject: [PATCH] Test for cpp exception handling --- tests/compile/cpp_exceptions_T265.pyx | 12 ++++++++++++ 1 file changed, 12 insertions(+) create mode 100644 tests/compile/cpp_exceptions_T265.pyx diff --git a/tests/compile/cpp_exceptions_T265.pyx b/tests/compile/cpp_exceptions_T265.pyx new file mode 100644 index 00000000..3c2bd6d0 --- /dev/null +++ b/tests/compile/cpp_exceptions_T265.pyx @@ -0,0 +1,12 @@ +cdef void raise_py_error(): + pass + +cdef extern from "foo.h": + cdef int generic_error() except + + cdef int specified_error() except +MemoryError + cdef int dynamic_error() except +raise_py_error + +def test_it(): + generic_error() + specified_error() + dynamic_error() -- 2.26.2