summaryrefslogtreecommitdiff
path: root/Examples/test-suite/director_exception_nothrow.i
diff options
context:
space:
mode:
Diffstat (limited to 'Examples/test-suite/director_exception_nothrow.i')
-rw-r--r--Examples/test-suite/director_exception_nothrow.i28
1 files changed, 28 insertions, 0 deletions
diff --git a/Examples/test-suite/director_exception_nothrow.i b/Examples/test-suite/director_exception_nothrow.i
new file mode 100644
index 000000000..8a072617f
--- /dev/null
+++ b/Examples/test-suite/director_exception_nothrow.i
@@ -0,0 +1,28 @@
+%module(directors="1") director_exception_nothrow
+
+%include "std_string.i"
+
+%feature("director") Bar;
+
+%{
+#if defined(_MSC_VER)
+ #pragma warning(disable: 4290) // C++ exception specification ignored except to indicate a function is not __declspec(nothrow)
+#endif
+%}
+
+%inline %{
+#include <string>
+
+class Base
+{
+public:
+ virtual ~Base() throw() {}
+};
+
+
+class Bar : public Base
+{
+public:
+ virtual std::string pang() throw() { return "Bar::pang()"; }
+};
+%}