Add a test case for the regex encoder inside %rename.

Simple unit test checking that %rename("%(regex:...)") works as expected.

git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@12171 626c5289-ae23-0410-ae9c-e8d60b6d4f22
This commit is contained in:
Vadim Zeitlin 2010-07-22 17:00:59 +00:00
commit 0b2561f300
3 changed files with 30 additions and 0 deletions

View file

@ -0,0 +1,21 @@
%module rename_pcre_encoder
// strip the wx prefix from all identifiers except those starting with wxEVT
%rename("%(regex:/wx(?!EVT)(.*)/\\1/)s") "";
%inline %{
class wxSomeWidget {
};
struct wxAnotherWidget {
void wxDoSomething() {}
};
class wxEVTSomeEvent {
};
class xUnchangedName {
};
%}