Fix #3024875 - shared_ptr of classes with non-public destructors. This also fixes the 'unref' feature when used on classes with non-public destructors.

git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@12155 626c5289-ae23-0410-ae9c-e8d60b6d4f22
This commit is contained in:
William S Fulton 2010-07-07 18:19:01 +00:00
commit cca92f4188
6 changed files with 92 additions and 1 deletions

View file

@ -2697,7 +2697,7 @@ int Language::destructorDeclaration(Node *n) {
if (!CurrentClass)
return SWIG_NOWRAP;
if (cplus_mode != PUBLIC)
if (cplus_mode != PUBLIC && !Getattr(CurrentClass, "feature:unref"))
return SWIG_NOWRAP;
if (ImportMode)
return SWIG_NOWRAP;