On Tue, Jun 1, 2010 at 1:19 PM, vishal bayskar <vishal.bays...@nechclst.in> wrote: >>how do I search for the constructor >>parent::child::A::A(parent::child::B const & arg0) [constructor] > >>What arg_types should I provide ? > >>I have tried with and without namespaces like >>cons = mb.constructors('A', arg_types=['parent::child::B const &']) >>cons = mb.constructors('A', arg_types=['child::B const &']) >>cons = mb.constructors('A', arg_types=['B const &']) > >>But every time it is giving an error >>raise RuntimeError( "Multi declaration query returned 0 declarations." ) > >>I don't know what bits I am missing please suggest. > > Now I have used > cons = mb.constructors('A', arg_types=['::parent::child::B const &']) > and it is working fine. > > Thanks can someone, please let me know the reason why :: (scope operator) is > required in the start of the argument.
I tried really hard to make this functionality more "user friendly", but failed. Take a look on http://pygccxml.svn.sourceforge.net/viewvc/pygccxml/pygccxml_dev/pygccxml/declarations/matchers.py?revision=1713&view=markup file, declaration_matcher_t class. I'll be glad, if you will improve the functionality. Thanks -- Roman Yakovenko C++ Python language binding http://www.language-binding.net/ _______________________________________________ Cplusplus-sig mailing list Cplusplus-sig@python.org http://mail.python.org/mailman/listinfo/cplusplus-sig