1 /* This interface file checks whether the SWIG parses the throw
2    directive in combination with the const directive.  Bug reported by
3    Scott B. Drummonds, 08 June 2001.
4 */
5 
6 %module cplusplus_throw
7 
8 // throw is invalid in C++17 and later, only SWIG to use it
9 #define TESTCASE_THROW1(T1) throw(T1)
10 %{
11 #define TESTCASE_THROW1(T1)
12 %}
13 
14 %nodefaultctor;
15 
16 %inline %{
17 
18 class Foo { };
19 
20 class Bar {
21 public:
baz()22   void baz() const { };
foo()23   void foo() TESTCASE_THROW1(Foo) { };
bazfoo()24   void bazfoo() const TESTCASE_THROW1(int) { };
25 };
26 
27 %}
28 
29