Boost logo

Boost Users :

From: Robert Ramey (ramey_at_[hidden])
Date: 2005-05-11 11:16:54

Registering isn't a very long operation, so if registering every time you call works for you, it would be a good solution. I believe the normal registration function would work fine here. The problem arises with the attempt to EXPORT via a unique identifier.

Another way would be to use the text string which is part of typeinfo where RTTI is supported. Problem is that that creates archive portability problems.

Robert Ramey.
  "Olivier Vanden Bos" <olivier.vanden-bos_at_[hidden]> wrote in message
  I am not sure of my fact, but can we do it dynamically , as the macro call extended_type_info::self_register() and void extended_type_info::key_register(const char *key_).


  I ve read in the list some stuff about registering templates like this.


   template<class> struct pack;


   template<class T> struct pack<void (T)> {

       typedef T type;



   BOOST_CLASS_EXPORT( pack<void (DerivedStatus< Algo<int, double > >)>::type );


  Can we mix that together to achieve this goal ?

  In fact, I don't care if we register the type each time we call, I know it s not optimal , but at this point I can live with it.


  void Add()


        B<int>* objectToAdd= new B<int>(0)






  - VDB -
   "LNK1210: exceeded internal ILK size limit"


  From: boost-users-bounces_at_[hidden] [mailto:boost-users-bounces_at_[hidden]] On Behalf Of Robert Ramey
  Sent: 11 mai 2005 02:22
  To: boost-users_at_[hidden]
  Subject: [Boost-users] Re: Serialize templates classes > automatique exportdeclaration


  I don't know how to avoid this either. If you figure out how to do this let me know


  Robert Ramey

    And when i archive the array in another .cpp the exception is raised, because

    the class B<int> as not been exported.


    I would like to avoid explicitly declare


    For each instanciation of B<> somewhere in the glo bal space.


  Boost-users mailing list

Boost-users list run by williamkempf at, kalb at, bjorn.karlsson at, gregod at, wekempf at