2
0
mirror of https://github.com/boostorg/python.git synced 2026-01-22 05:22:45 +00:00

Fixed a bug in add(), which allows non-method class attributes

[SVN r8178]
This commit is contained in:
Dave Abrahams
2000-11-12 19:47:39 +00:00
parent 124a99882b
commit 2dc27af335

View File

@@ -114,9 +114,9 @@ class ClassWrapper
// set an arbitrary attribute. Useful for non-function class data members,
// e.g. enums
void add(PyObject* x, const char* name)
{ return m_class->set_attribute(name, x); }
{ m_class->set_attribute(name, x); }
void add(Ptr x, const char* name)
{ return m_class->set_attribute(name, x); }
{ m_class->set_attribute(name, x); }
private:
PyPtr<ExtensionClass<T, U> > m_class;
};