The short answer is that I think @BenVoigt is basically correct.
In the description of reserve
(§23.3.6.3/2), it says:
If an exception is thrown other than by the move constructor of a non-CopyInsertable type, there are no effects.
[And the description of resize
in §23.3.6.3/12 requires the same.]
This means that if T is CopyInsertable, you get strong exception safety. To assure that, it can only use move construction if it deduces (by unspecified means) that move construction will never throw. There’s no guarantee that either throw()
or noexcept
will be necessary or sufficient for that though. If T is CopyInsertable, it can simply choose to always use copy construction. Basically, what’s happening is that the standard requires copy construction-like semantics; the compiler can only use move construction under the as-if rule, and it’s free to define when or if it’ll exercise that option.
If T is not CopyInsertable, reallocation will use move construction, but exception safety depends on whether T’s move constructor can throw. If it doesn’t throw, you get strong exception safety, but if it throws, you don’t (I think you probably get the basic guarantee, but maybe not even that and definitely no more).