diff options
| author | Paul Buetow <paul@buetow.org> | 2008-10-14 20:38:27 +0000 |
|---|---|---|
| committer | Paul Buetow <paul@buetow.org> | 2008-10-14 20:38:27 +0000 |
| commit | d527f50159f056dc165fa7eaf7bf80425a1e758d (patch) | |
| tree | 03e8aa97c25fbc014876e5113dd66d4a44adac4d /src/core/interpret.c | |
| parent | 71185ab0ab0b08b4d5bb2e750ff85e11f105a453 (diff) | |
GC removed, temporaly
Diffstat (limited to 'src/core/interpret.c')
| -rw-r--r-- | src/core/interpret.c | 13 |
1 files changed, 9 insertions, 4 deletions
diff --git a/src/core/interpret.c b/src/core/interpret.c index c3f781c..a53f193 100644 --- a/src/core/interpret.c +++ b/src/core/interpret.c @@ -165,8 +165,13 @@ int _program(Interpret *p_interpret) { _CHECK TRACK - while (_statement(p_interpret) == 1) - garbage_collect(); + int i_count = 0; + while (_statement(p_interpret) == 1) { + if (++i_count == 50) { + garbage_collect(); + i_count = 0; + } + } return (1); } @@ -299,7 +304,7 @@ _block_get(Interpret *p_interpret, List *p_list_block) { int __expression_get(Interpret *p_interpret, List *p_list_expression) { for (;;) { - if (p_interpret->tt == TT_PARANT_CL) + if (p_interpret->tt == TT_PARANT_CL) break; /* for */ list_add_back(p_list_expression, p_interpret->p_token); @@ -950,7 +955,7 @@ _term(Interpret *p_interpret) { if (__array_get(p_interpret, p_token_arr) != 0) _INTERPRET_ERROR("Array syntax error", p_token); - return (1); + return (1); } break; |
