replace assert with CC_ASSERT (#10913)

* replace assert with CC_ASSERT
This commit is contained in:
minggo
2022-04-29 10:18:41 +08:00
committed by GitHub
parent fa25709788
commit 8e7669bf92
65 changed files with 303 additions and 627 deletions
@@ -25,7 +25,7 @@
****************************************************************************/
#include "ValueArrayPool.h"
#include <cassert>
#include "base/Macros.h"
#include "config.h"
namespace se {
@@ -45,13 +45,13 @@ ValueArray &ValueArrayPool::get(uint32_t argc) {
if (SE_UNLIKELY(_depth >= _pools.size())) {
auto *ptr = _pools.data();
_pools.resize(_depth + 1);
assert(_pools.data() == ptr);
CC_ASSERT(_pools.data() == ptr);
initPool(_depth);
}
assert(argc <= MAX_ARGS);
CC_ASSERT(argc <= MAX_ARGS);
auto &ret = _pools[_depth][argc];
assert(ret.size() == argc);
CC_ASSERT(ret.size() == argc);
return ret;
}