Add the strip encoder patch from Anatoly Techtonik #2130016
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@10896 626c5289-ae23-0410-ae9c-e8d60b6d4f22
This commit is contained in:
parent
f2c11f74f9
commit
a604f46593
5 changed files with 69 additions and 0 deletions
|
|
@ -260,6 +260,7 @@ CPP_TEST_CASES += \
|
|||
rename3 \
|
||||
rename4 \
|
||||
rename_scope \
|
||||
rename_strip_encoder \
|
||||
restrict_cplusplus \
|
||||
return_const_value \
|
||||
return_value_scope \
|
||||
|
|
|
|||
6
Examples/test-suite/python/rename_strip_encoder_runme.py
Normal file
6
Examples/test-suite/python/rename_strip_encoder_runme.py
Normal file
|
|
@ -0,0 +1,6 @@
|
|||
from rename_strip_encoder import *
|
||||
|
||||
s = SomeWidget()
|
||||
a = AnotherWidget()
|
||||
a.DoSomething()
|
||||
|
||||
16
Examples/test-suite/rename_strip_encoder.i
Normal file
16
Examples/test-suite/rename_strip_encoder.i
Normal file
|
|
@ -0,0 +1,16 @@
|
|||
%module rename_strip_encoder
|
||||
|
||||
// strip the wx prefix from all identifiers
|
||||
%rename("%(strip:[wx])s") "";
|
||||
|
||||
%inline %{
|
||||
|
||||
class wxSomeWidget {
|
||||
};
|
||||
|
||||
struct wxAnotherWidget {
|
||||
void wxDoSomething() {}
|
||||
};
|
||||
|
||||
|
||||
%}
|
||||
Loading…
Add table
Add a link
Reference in a new issue