diff --git a/HISTORY b/HISTORY index 3973608..5b15a07 100755 --- a/HISTORY +++ b/HISTORY @@ -1,6 +1,7 @@ Jan. 2 2016 Added support to apply GET statement to a class instance Added support to access a collection by brackets +Fixed a mistake in VAR statement Polished document Jan. 1 2016 Version 1.2 diff --git a/core/my_basic.c b/core/my_basic.c index 2568065..085df0b 100755 --- a/core/my_basic.c +++ b/core/my_basic.c @@ -11042,6 +11042,7 @@ int _core_class(mb_interpreter_t* s, void** l) { _object_t* obj = 0; _class_t* instance = 0; _class_t* inherit = 0; + _class_t* last_inst = 0; mb_assert(s && l); @@ -11061,6 +11062,9 @@ int _core_class(mb_interpreter_t* s, void** l) { ast = ast->next; obj = (_object_t*)ast->data; + last_inst = s->last_instance; + s->last_instance = instance; + if(_IS_FUNC(obj, _core_open_bracket)) { /* Process meta_list */ do { @@ -11120,6 +11124,8 @@ _pop_exit: _exit: *l = ast; + s->last_instance = last_inst; + return result; } diff --git a/output/my_basic.exe b/output/my_basic.exe index 28edbf4..c59f540 100755 Binary files a/output/my_basic.exe and b/output/my_basic.exe differ