Quote Originally Posted by ~Kyo~
It is standard to put any calls to new in a try block in case it does throw an exception.
It is standard to use RAII. Having an exception be thrown in the face of a single call to new in such a case is safe: the exception will just be propagated. You need the try block because you need to delete if an exception is thrown later on, but with RAII that worry is eliminated.

Quote Originally Posted by ~Kyo~
All I did was choose a name for an example. To my knowledge you could change that to anything and have the code still work.
Sure, but for all your talk about avoiding overhead, you described a solution that has a great deal more overhead than what I proposed in terms of the invocations of new[] in the loop, compared to say, two invocations of new[].

Quote Originally Posted by ~Kyo~
Also to my knowledge vector is fine unless you expand alot on it in which case it does end up calling new and copying itself.
That may well be fine. The complexity of push_back is amortized O(1) because of how the vector's capacity grows (i.e., by a factor, not a constant).

Quote Originally Posted by ~Kyo~
In theory you COULD define larger bounds on a <datatype here> ** and have the same flexibility.
You could define a larger bounds on a vector<datatype here> and have the same flexibility, as well as the same possible space wastage.

Quote Originally Posted by ~Kyo~
Vector uses new I am very much sure of that being dynamic and all. Just because you don't see the code when you implement it does not mean it is never called.
The vector uses the provided allocator, which may or may not use the new[] that you have in mind.

Quote Originally Posted by ~Kyo~
Your still saving overhead if you are not resizing that is my point
If saving the space that would have been used to store the capacity really was your point, then it is a non-issue: you could use the up and coming std::unique_ptr with a custom deleter, or implement your own non-expandable vector class template (extremely easy since it is err... not expandable).