fix %template + private SF#1099976

git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk/SWIG@6991 626c5289-ae23-0410-ae9c-e8d60b6d4f22
This commit is contained in:
Marcelo Matus 2005-02-23 02:10:14 +00:00
commit 7a3689ce5c
2 changed files with 13 additions and 0 deletions

View file

@ -2982,6 +2982,16 @@ cpp_class_decl :
}
appendChild($$,dump_nested(Char(name)));
}
if (cplus_mode != CPLUS_PUBLIC) {
/* we 'open' the class at the end, to allow %template
to add new members */
Node *pa = new_node("access");
Setattr(pa,"kind","public");
cplus_mode = CPLUS_PUBLIC;
appendChild($$,pa);
}
Setattr($$,"symtab",Swig_symbol_popscope());
Classprefix = 0;