avoid using of temporal value for wrapping type user + const reference argument
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk/SWIG@6895 626c5289-ae23-0410-ae9c-e8d60b6d4f22
This commit is contained in:
parent
544f24441e
commit
7cb488e057
2 changed files with 31 additions and 2 deletions
|
|
@ -52,3 +52,23 @@
|
|||
|
||||
%template(templatedfunction) templatedfunction<int>;
|
||||
|
||||
|
||||
// Deafult args with references
|
||||
%inline
|
||||
%{
|
||||
|
||||
typedef int size_type;
|
||||
|
||||
struct Hello
|
||||
{
|
||||
static const size_type hello = 3;
|
||||
};
|
||||
|
||||
|
||||
|
||||
int rfoo( const size_type& x = Hello::hello, const Hello& y = Hello() )
|
||||
{
|
||||
return x;
|
||||
}
|
||||
|
||||
%}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue