more valuewrapper cases
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@6380 626c5289-ae23-0410-ae9c-e8d60b6d4f22
This commit is contained in:
parent
0bff053cd3
commit
ae673f007b
2 changed files with 17 additions and 3 deletions
|
|
@ -28,6 +28,15 @@ public:
|
|||
%feature("novaluewrapper") B;
|
||||
class B;
|
||||
|
||||
/*
|
||||
* Force swig to use the value wrapper, even when the class
|
||||
* has a default constructor, in case you want to save a
|
||||
* instance construction.
|
||||
*
|
||||
*/
|
||||
%feature("valuewrapper") D;
|
||||
class D;
|
||||
|
||||
|
||||
%inline %{
|
||||
|
||||
|
|
@ -37,6 +46,8 @@ public:
|
|||
A(int){}
|
||||
};
|
||||
|
||||
class D {};
|
||||
|
||||
class Klass {};
|
||||
|
||||
|
||||
|
|
@ -90,6 +101,10 @@ auto_ptr<A> getPtrA(auto_ptr<A> a) {
|
|||
B getB(B a) {
|
||||
return a;
|
||||
}
|
||||
|
||||
D getD(D a) {
|
||||
return a;
|
||||
}
|
||||
|
||||
%}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue