Boost logo

Boost :

From: Peter.Bienstman_at_[hidden]
Date: 2001-07-16 10:05:59


Hi,

I naively assumed that if I write something like

  class_builder<BaseMaterial> BaseMaterial_(camfr, "BaseMaterial");
  BaseMaterial_.def(&BaseMaterial::operator(), "__call__");
   
  class_builder<Material> Material_(camfr, "Material");
  Material_.declare_base(BaseMaterial_);

, I would automatically get the __call__ operator available in
Material, as it derives from BaseMaterial.

However, this does not seem to work, I have to explicitly define
operator() in Material as well, in order to get it to work.

Am I missing something here? It would be really useful if one did not
have to manually reregister functions in derived classes.

Peter


Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk