From: Robert Bradshaw Date: Thu, 16 Apr 2009 07:51:59 +0000 (-0700) Subject: Modify test for T158 as warnings, not errors, are raised. X-Git-Tag: 0.11.1 X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=c068048868b837b8646fd6590548c5104c173b59;p=cython.git Modify test for T158 as warnings, not errors, are raised. --- diff --git a/tests/compile/cpp_exceptions.h b/tests/compile/cpp_exceptions.h new file mode 100644 index 00000000..c9ec834e --- /dev/null +++ b/tests/compile/cpp_exceptions.h @@ -0,0 +1,3 @@ +extern int generic_error(void); +extern int specified_error(void); +extern int dynamic_error(void); diff --git a/tests/compile/cpp_exceptions_T265.pyx b/tests/compile/cpp_exceptions_T265.pyx index 3c2bd6d0..de7003e5 100644 --- a/tests/compile/cpp_exceptions_T265.pyx +++ b/tests/compile/cpp_exceptions_T265.pyx @@ -1,7 +1,7 @@ cdef void raise_py_error(): pass -cdef extern from "foo.h": +cdef extern from "cpp_exceptions.h": cdef int generic_error() except + cdef int specified_error() except +MemoryError cdef int dynamic_error() except +raise_py_error diff --git a/tests/errors/declareafteruse_T158.pyx b/tests/errors/declareafteruse_T158.pyx index 73c0f4d6..de75ce62 100644 --- a/tests/errors/declareafteruse_T158.pyx +++ b/tests/errors/declareafteruse_T158.pyx @@ -49,8 +49,8 @@ cdef int *baz print var[0][0] cdef unsigned long long var[100][100] - -_ERRORS = u""" +# in 0.11.1 these are warnings +FUTURE_ERRORS = u""" 4:13: cdef variable 's' declared after it is used 4:16: cdef variable 'vv' declared after it is used 9:14: cdef variable 'i' declared after it is used @@ -63,3 +63,12 @@ _ERRORS = u""" 47:10: cdef variable 'baz' declared after it is used 50:24: cdef variable 'var' declared after it is used """ + +syntax error + +_ERRORS = u""" +40:17: cdef variable 't' declared after it is used +47:10: cdef variable 'baz' declared after it is used +50:24: cdef variable 'var' declared after it is used +67:7: Syntax error in simple statement list +"""