Commit da1a7d09 authored by Stefan Behnel's avatar Stefan Behnel

Check for warnings in some C++ tests.

parent 82b3d74b
# tag: cpp
# mode: compile # mode: compile
# tag: cpp, warnings
cdef extern from "templates.h": cdef extern from "templates.h":
cdef cppclass TemplateTest1[T]: cdef cppclass TemplateTest1[T]:
......
# tag: cpp # mode: run
# tag: cpp, warnings
# This gives a warning, but should not give an error. # This gives a warning about the previous .pxd definition, but should not give an error.
cdef cppclass Foo: cdef cppclass Foo:
int _foo int _foo
int get_foo(): int get_foo():
...@@ -20,3 +21,8 @@ def test_Foo(n): ...@@ -20,3 +21,8 @@ def test_Foo(n):
return foo.get_foo() return foo.get_foo()
finally: finally:
del foo del foo
_WARNINGS = """
5:5: 'Foo' already defined (ignoring second definition)
"""
# tag: cpp # mode: run
# tag: cpp, warnings
cimport cython cimport cython
from libcpp.pair cimport pair from libcpp.pair cimport pair
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment