2
0
mirror of https://github.com/boostorg/python.git synced 2026-02-01 20:52:13 +00:00

obtain correct class name via cl.attr("__name__")

[SVN r23359]
This commit is contained in:
Ralf W. Grosse-Kunstleve
2004-07-06 04:36:50 +00:00
parent 858e5e9720
commit 112c999818
2 changed files with 6 additions and 1 deletions

View File

@@ -73,7 +73,9 @@ namespace boost { namespace python {
{
// Wrap the map's element (value_type)
std::string elem_name = "map_indexing_suite_";
elem_name += cl.ptr()->ob_type->tp_name; // the class name
object class_name(cl.attr("__name__"));
extract<std::string> class_name_extractor(class_name);
elem_name += class_name_extractor();
elem_name += "_entry";
typedef typename mpl::if_<