diff options
author | William S Fulton <wsf@fultondesigns.co.uk> | 2004-11-09 21:27:02 +0000 |
---|---|---|
committer | William S Fulton <wsf@fultondesigns.co.uk> | 2004-11-09 21:27:02 +0000 |
commit | 0b150a96bb33355ae558b3cf5ce50627679db198 (patch) | |
tree | 60355fb9de65156afad43577cd369d0608fd9e71 | |
parent | e893bb526f58dfd90106e0ca8178ba76e8c0e1ac (diff) | |
download | swig-0b150a96bb33355ae558b3cf5ce50627679db198.tar.gz |
more %rename/%ignore tests
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@6706 626c5289-ae23-0410-ae9c-e8d60b6d4f22
-rw-r--r-- | SWIG/Examples/test-suite/csharp/default_args_runme.cs | 3 | ||||
-rw-r--r-- | SWIG/Examples/test-suite/default_args.i | 7 | ||||
-rw-r--r-- | SWIG/Examples/test-suite/perl5/default_args_runme.pl | 3 |
3 files changed, 13 insertions, 0 deletions
diff --git a/SWIG/Examples/test-suite/csharp/default_args_runme.cs b/SWIG/Examples/test-suite/csharp/default_args_runme.cs index d9c9f60d8..68ea0e854 100644 --- a/SWIG/Examples/test-suite/csharp/default_args_runme.cs +++ b/SWIG/Examples/test-suite/csharp/default_args_runme.cs @@ -55,6 +55,9 @@ public class runme Foo foo = new Foo(); foo.newname(); foo.newname(10); + foo.renamed3arg(10, 10.0); + foo.renamed2arg(10); + foo.renamed1arg(); // exception specifications try { diff --git a/SWIG/Examples/test-suite/default_args.i b/SWIG/Examples/test-suite/default_args.i index fb2141c1a..f299394bb 100644 --- a/SWIG/Examples/test-suite/default_args.i +++ b/SWIG/Examples/test-suite/default_args.i @@ -76,6 +76,10 @@ %rename(bar2) Foo::bar; %rename(newname) Foo::oldname(int x = 1234); %ignore Foo::Foo(int x, int y = 0, int z = 0); +%ignore Foo::meth(int x, int y = 0, int z = 0); +%rename(renamed3arg) Foo::renameme(int x, double d) const; +%rename(renamed2arg) Foo::renameme(int x) const; +%rename(renamed1arg) Foo::renameme() const; %inline %{ @@ -88,6 +92,8 @@ Foo(){} Foo(int x, int y = 0, int z = 0){} + + void meth(int x, int y = 0, int z = 0){} // Use a renamed member as a default argument. SWIG has to resolve // bar to Foo::bar and not Foo::spam. SWIG-1.3.11 got this wrong. @@ -99,6 +105,7 @@ // test the method itself being renamed void oldname(int x = 1234) {} + void renameme(int x = 1234, double d=123.4) const {} }; int Foo::bar = 1; int Foo::spam = 2; diff --git a/SWIG/Examples/test-suite/perl5/default_args_runme.pl b/SWIG/Examples/test-suite/perl5/default_args_runme.pl index c0fb7acad..397f25f8a 100644 --- a/SWIG/Examples/test-suite/perl5/default_args_runme.pl +++ b/SWIG/Examples/test-suite/perl5/default_args_runme.pl @@ -70,6 +70,9 @@ if (default_args::reftest2() != "hello") { $foo = new default_args::Foo(); $foo->newname(); $foo->newname(10); +$foo->renamed3arg(10, 10.0); +$foo->renamed2arg(10); +$foo->renamed1arg(); # exception specifications eval { default_args::exceptionspec() }; |