Fix in Perl out-typemap for std::vector (thanks to Josh Cherry)

git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@5980 626c5289-ae23-0410-ae9c-e8d60b6d4f22
This commit is contained in:
Luigi Ballabio 2004-06-11 07:37:41 +00:00
commit 2ee999ed53

View file

@ -139,8 +139,9 @@ namespace std {
int len = $1.size();
SV **svs = new SV*[len];
for (unsigned int i=0; i<len; i++) {
T* ptr = new T($1[i]);
svs[i] = sv_newmortal();
SWIG_MakePtr(svs[i], (void*)&($1[i]),
SWIG_MakePtr(svs[i], (void*) ptr,
$descriptor(T *), $shadow|$owner);
}
AV *myav = av_make(len, svs);