Fix wrapping of overloaded protected methods when using allprotected mode
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@10423 626c5289-ae23-0410-ae9c-e8d60b6d4f22
This commit is contained in:
parent
90179b787f
commit
b0ecf14e31
6 changed files with 51 additions and 4 deletions
|
|
@ -2111,7 +2111,10 @@ int Language::classDirector(Node *n) {
|
|||
bool cdecl = (Cmp(nodeType, "cdecl") == 0);
|
||||
if (cdecl && !GetFlag(ni, "feature:ignore")) {
|
||||
if (is_non_virtual_protected_access(ni)) {
|
||||
Printf(using_protected_members_code, " using %s::%s;\n", SwigType_namestr(ClassName), Getattr(ni, "name"));
|
||||
Node *overloaded = Getattr(ni, "sym:overloaded");
|
||||
// emit the using base::member statement (but only once if the method is overloaded)
|
||||
if (!overloaded || (overloaded && (overloaded == ni)))
|
||||
Printf(using_protected_members_code, " using %s::%s;\n", SwigType_namestr(ClassName), Getattr(ni, "name"));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue