[原创]bind绑定成员函数容易犯的错误
IntArray arrTest;
arrTest.append(1);
arrTest.append(1);
arrTest.append(1);
arrTest.append(1);
arrTest.append(1);
arrTest.append(1);
IntArray other;
arrayForeachT(arrTest, BD<int>(&IntArray::append, BST::ref(other), _1)); // OK
arrayForeachT(arrTest, BD<int>(&IntArray::append, &other, _1)); // OK
arrayForeachT(arrTest, BD<int>(&IntArray::append, other, _1)); // 错,插入的东西跑拷贝里了
CYDBGCMD_VAL(other.length());