runtime tests for templated functions with default args in namespace
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk/SWIG@6455 626c5289-ae23-0410-ae9c-e8d60b6d4f22
This commit is contained in:
parent
1800d7914f
commit
2c5f8a09d2
1 changed files with 29 additions and 0 deletions
|
|
@ -111,3 +111,32 @@ if (overload() != 50):
|
|||
raise RuntimeError, ("overload(const char *)")
|
||||
|
||||
|
||||
# everything put in a namespace
|
||||
if (nsoverload("hi") != 1000):
|
||||
raise RuntimeError, ("nsoverload()")
|
||||
|
||||
if (nsoverload(1) != 1010):
|
||||
raise RuntimeError, ("nsoverload(int t)")
|
||||
|
||||
if (nsoverload(1, 1) != 1020):
|
||||
raise RuntimeError, ("nsoverload(int t, const int &)")
|
||||
|
||||
if (nsoverload(1, "hello") != 1030):
|
||||
raise RuntimeError, ("nsoverload(int t, const char *)")
|
||||
|
||||
if (nsoverload(k) != 1010):
|
||||
raise RuntimeError, ("nsoverload(Klass t)")
|
||||
|
||||
if (nsoverload(k, k) != 1020):
|
||||
raise RuntimeError, ("nsoverload(Klass t, const Klass &)")
|
||||
|
||||
if (nsoverload(k, "hello") != 1030):
|
||||
raise RuntimeError, ("nsoverload(Klass t, const char *)")
|
||||
|
||||
if (nsoverload(10.0, "hi") != 1040):
|
||||
raise RuntimeError, ("nsoverload(double t, const char *)")
|
||||
|
||||
if (nsoverload() != 1050):
|
||||
raise RuntimeError, ("nsoverload(const char *)")
|
||||
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue