diff options
author | Swati Sharma <itawswati@gmail.com> | 2012-08-10 19:11:50 +0000 |
---|---|---|
committer | Swati Sharma <itawswati@gmail.com> | 2012-08-10 19:11:50 +0000 |
commit | 4109d2507fd9206cf1774847e71093e344813647 (patch) | |
tree | e51b53e76d62bfc1a1a7bb32270655b92ce3aca0 | |
parent | be202c2178d7bc5f747cd7eb30c11f536403bb4f (diff) | |
download | swig-4109d2507fd9206cf1774847e71093e344813647.tar.gz |
Added and Fixed some typemaps.
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/branches/gsoc2012-objc@13590 626c5289-ae23-0410-ae9c-e8d60b6d4f22
-rw-r--r-- | Lib/objc/objc.swg | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/Lib/objc/objc.swg b/Lib/objc/objc.swg index f244f39b2..4106c377d 100644 --- a/Lib/objc/objc.swg +++ b/Lib/objc/objc.swg @@ -187,7 +187,7 @@ %{ $1 = ($1_ltype)$input; %} %typemap(in) SWIGTYPE *const& ($*1_ltype temp = 0) -%{ temp = ($*1_ltype)$input; +%{ temp = *($1_ltype)&$input; $1 = ($1_ltype)&temp; %} // Array conversion typemap @@ -201,6 +201,9 @@ %typemap(in) SWIGTYPE ((*)(ANY)) %{ $1 = ($1_ltype)$input; %} +%typemap(in) SWIGTYPE *& ($*1_ltype temp = 0) +%{ temp = *($1_ltype)&$input; + $1 = &temp; %} /* * OUT TYPEMAPS: Used for return-type type conversions: C++ to ObjectiveC++ @@ -299,6 +302,9 @@ %typemap(out) SWIGTYPE ((*)(ANY)) %{ $result = (void*)$1; %} +%typemap(out) SWIGTYPE *& +%{ $result = (void*)*$1; %} + /* * OBJCTYPE TYPEMAPS: Represents the ObjectiveC(proxy) type corresponding to each ObjectiveC++ type in the intermediate(wrapper) layer. */ @@ -369,7 +375,7 @@ // References to non-primitive types %typemap(objctype) SWIGTYPE & "$objcclassname*" -%typemap(objctype) SWIGTYPE *const& "$*objcclassname" +%typemap(objctype) SWIGTYPE *const& "$objcclassname*" // Function pointers %typemap(objctype) SWIGTYPE ((*)(ANY)) "$objcclassname*" |