Corrected bug where array<T> would fail to free reserved memory if it was empty, i.e. when an array was reserved but never inserted into. Added test code to exercise the case. Note that in implementing this, a new algorithm destroy_all_backward was created