/tags/rel-1-3-25/SWIG/Examples/test-suite/name.i
Swig | 28 lines | 20 code | 5 blank | 3 comment | 0 complexity | 5f434739cd503e1571a6ed21a1c8c8a3 MD5 | raw file
Possible License(s): LGPL-2.1, Cube, GPL-3.0, 0BSD, GPL-2.0
- /* This interface file tests whether SWIG/Guile handle the %rename and
- %name directives, which was not the case in 1.3a5.
- */
- %module name
- #pragma SWIG nowarn=121 // %name is deprecated. Use %rename instead.
- #ifdef SWIGGUILE
- %rename foo_1 "foo-2";
- #else
- %rename foo_1 "foo_2";
- #endif
- %inline %{
- void foo_1() {}
- %}
- #ifdef SWIGGUILE
- %name("bar-2")
- #else
- %name("bar_2")
- #endif
- %inline %{
- int bar_1 = 17;
- %}
- %name("Baz_2")
- %constant int Baz_1 = 47;