*fixed compile issues.

This commit is contained in:
Wang Renxin 2017-01-09 20:00:42 +08:00
parent 456c507bb4
commit 4271dc609c
2 changed files with 4 additions and 3 deletions

View File

@ -7870,10 +7870,11 @@ _exit:
/* Call the TOSTRING function of a class instance to format it */ /* Call the TOSTRING function of a class instance to format it */
static int _format_class_to_string(mb_interpreter_t* s, void** l, _class_t* instance, _object_t* out, bool_t* got_tostr) { static int _format_class_to_string(mb_interpreter_t* s, void** l, _class_t* instance, _object_t* out, bool_t* got_tostr) {
int result = MB_FUNC_OK; int result = MB_FUNC_OK;
_ls_node_t* tsn = 0;
mb_assert(s && l && instance && out); mb_assert(s && l && instance && out);
_ls_node_t* tsn = _search_identifier_in_class(s, instance, _CLASS_TOSTRING_FUNC, 0, 0); tsn = _search_identifier_in_class(s, instance, _CLASS_TOSTRING_FUNC, 0, 0);
if(got_tostr) *got_tostr = false; if(got_tostr) *got_tostr = false;
if(tsn) { if(tsn) {
_object_t* tso = (_object_t*)tsn->data; _object_t* tso = (_object_t*)tsn->data;

View File

@ -219,7 +219,7 @@ static void _tidy_mem_pool(bool_t force) {
return; return;
for(i = 0; i < pool_count; i++) { for(i = 0; i < pool_count; i++) {
while((s = pool[i].stack)) { while((s = pool[i].stack) != 0) {
pool[i].stack = (char*)_POOL_NODE_NEXT(s); pool[i].stack = (char*)_POOL_NODE_NEXT(s);
_POOL_NODE_FREE(s); _POOL_NODE_FREE(s);
} }
@ -299,7 +299,7 @@ static void _close_mem_pool(void) {
return; return;
for(i = 0; i < pool_count; i++) { for(i = 0; i < pool_count; i++) {
while((s = pool[i].stack)) { while((s = pool[i].stack) != 0) {
pool[i].stack = (char*)_POOL_NODE_NEXT(s); pool[i].stack = (char*)_POOL_NODE_NEXT(s);
_POOL_NODE_FREE(s); _POOL_NODE_FREE(s);
} }