Hacker Newsnew | past | comments | ask | show | jobs | submit | cliff_r's commentslogin

The bit about special 'fast' handling of relocatable types should be obviated by r-value references and move constructors in C++11/14, right?

I.e. if we want fast push_back() behavior, we can use a compiler that knows to construct the element directly inside the vector's backing store rather that creating a temporary object and copying it into the vector.


emplace_back was added in C++11 which does just that: http://en.cppreference.com/w/cpp/container/vector/emplace_ba...


Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: