Removing __swig_getmethods__ for static methods

Static methods will always be found by normal attribute lookup, so there's no
need to check for them during __getattr__ (aka _swig_getattr_nondynamic)
This commit is contained in:
Alec Cooper 2016-01-25 11:45:07 -05:00
commit 866429d0f7

View file

@ -4727,16 +4727,7 @@ public:
Printv(f_shadow, tab8, "return ", funcCall(Swig_name_member(NSPACE_TODO, class_name, symname), callParms), "\n\n", NIL);
}
Printv(f_shadow, tab4, symname, " = staticmethod(", symname, ")\n", NIL);
if (!modern) {
Printv(f_shadow, tab4, "__swig_getmethods__[\"", symname, "\"] = lambda x: ", symname, "\n", NIL);
}
} else {
if (!modern) {
Printv(f_shadow, tab4, "__swig_getmethods__[\"", symname, "\"] = lambda x: ", module, ".", Swig_name_member(NSPACE_TODO, class_name, symname), "\n",
NIL);
}
if (!classic) {
if (!modern)
Printv(f_shadow, tab4, "if _newclass:\n", tab4, NIL);