Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > C++ > std::vector <mytype> allocation strategy

Reply
Thread Tools

std::vector <mytype> allocation strategy

 
 
msalters
Guest
Posts: n/a
 
      12-15-2004

Victor Bazarov wrote:

> Tough to use references when you need an array or a container of your
> polymorphic objects...


std::vector<boost::ref<T> > sounds like the solution to that.
Regards,
Michiel Salters

 
Reply With Quote
 
 
 
 
Default User
Guest
Posts: n/a
 
      12-15-2004
msalters wrote:

>
> Victor Bazarov wrote:
>
> > Tough to use references when you need an array or a container of
> > your polymorphic objects...

>
> std::vector<boost::ref<T> > sounds like the solution to that.



Not part of standard C++, therefore unavailable to those of us using
certified tool sets.




Brian
 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
An idea for heap allocation at near stack allocation speed Bjarke Hammersholt Roune C++ 14 03-06-2011 08:07 AM
static memory allocation versus dynamic memory allocation Ken C Programming 24 11-30-2006 12:37 AM
What is the difference between dynamic memory allocation,and stack allocation ? chris C++ 6 10-28-2005 05:27 AM
what's your 70-300 study strategy Peng Te MCSD 3 02-05-2004 07:30 PM
MCAD .net job hunting strategy Frank MCSD 1 07-09-2003 01:28 PM



Advertisments