From 17566106e5d722e82369f08f555fa589c62d8cd3 Mon Sep 17 00:00:00 2001 From: "Gustavo J. A. M. Carneiro" Date: Fri, 28 Dec 2007 01:08:00 +0000 Subject: [PATCH] Get function-as-method working again (had been recently broken). --- pybindgen/cppclass.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/pybindgen/cppclass.py b/pybindgen/cppclass.py index 6fec06f..162e5de 100644 --- a/pybindgen/cppclass.py +++ b/pybindgen/cppclass.py @@ -587,7 +587,7 @@ public: assert name is None or isinstance(name, str) if isinstance(method, CppMethod): if name is None: - name = method.method_name + name = method.mangled_name elif isinstance(method, function.Function): assert name is not None assert isinstance(method.parameters[0], CppClassParameterBase) @@ -601,11 +601,11 @@ public: raise TypeError try: - overload = self.methods[method.mangled_name] + overload = self.methods[name] except KeyError: - overload = CppOverloadedMethod(method.mangled_name) + overload = CppOverloadedMethod(name) overload.pystruct = self.pystruct - self.methods[method.mangled_name] = overload + self.methods[name] = overload method.class_ = self overload.add(method)