postPut in new array API

Call when appropriate (putFrom(), copyIn(), and replace()).
Not called by swap(), take(), reuse(), or shareData().
Users of the second set of methods are expected to call
one of the methods in the first set, or call postPut() directly.

Document when postPut is (not) called.
This commit is contained in:
Michael Davidsaver
2013-05-23 17:50:12 -04:00
parent 1bf2ff430a
commit 629c8346d2
4 changed files with 21 additions and 4 deletions

View File

@@ -108,6 +108,7 @@ static void testBasic()
testOk1(!arr1->viewUnsafe().unique());
arr2->swap(data);
arr2->postPut();
testOk1(arr2->getLength()==0);
testOk1(data.size()==arr1->getLength());