Boost logo

Boost :

From: Brad King (brad.king_at_[hidden])
Date: 2002-08-13 13:43:33


> What I'd like is to be able to generate a compiler warning or error if
> the user fails to call the def_init() member function somewhere in the
> chain. Any ideas?

What if the class really doesn't have any public constructors?

A* get_A();

class A
  A() {}
  friend A* get_A();
  void method();


  .add(class_<A>("A").def("method", &A::method))
  .def("get_A", get_A, return_value_policy<manage_new_object>());


Boost list run by bdawes at, gregod at, cpdaniel at, john at