diff --git a/include/boost/python/value_from_python.hpp b/include/boost/python/value_from_python.hpp index 0ff80323..c835de45 100644 --- a/include/boost/python/value_from_python.hpp +++ b/include/boost/python/value_from_python.hpp @@ -16,6 +16,7 @@ namespace boost { namespace python { template struct value_from_python { + typedef value_from_python self; typedef converter::from_python_check from_python_check; value_from_python(from_python_check convertible) @@ -50,13 +51,13 @@ struct value_from_python // Mark successful construction static void constructed(converter::from_python_data& data) { - data.stage1 = get_storage(data); + data.stage1 = self::get_storage(data); } inline static void destroy(converter::from_python_data& data) { // Get the location of the storage for - void* storage = get_storage(data); + void* storage = self::get_storage(data); // Check for successful construction if (data.stage1 == storage) diff --git a/src/converter/builtin_converters.cpp b/src/converter/builtin_converters.cpp index fcd7a2cd..33e1cb50 100644 --- a/src/converter/builtin_converters.cpp +++ b/src/converter/builtin_converters.cpp @@ -91,7 +91,8 @@ namespace : value_from_python > { private: - typedef value_from_python > base; + typedef tp_cref_from_python self; + typedef value_from_python > base; public: tp_cref_from_python() @@ -102,7 +103,7 @@ namespace { unaryfunc converter = *(unaryfunc*)data.stage1; - void* storage = get_storage(data); + void* storage = self::get_storage(data); ref converted(converter(obj));