This is a discussion on Delete and vector pointer within the C++ Programming forums, part of the General Programming Boards category; Originally Posted by Elysia If it's too slow when looking at a profiler, then I will consider changing it. Funny ...
Pointers suck when not wrapped in smart pointers
That's my experience. Most of the "access violation" I get is with complex, non-C++ish code, such as managing buffers and pointers by hand (which I do avoid).
Mostly it's old code, written many years ago or so. We improve all the time!
For information on how to enable C++11 on your compiler, look here.
This may be applicable to you, though it pertains to the 2005 version of Visual C++:No, I do believe it can do it, but I don't know how or when.
Named Return Value Optimization in Visual C++ 2005