diff --git a/HISTORY b/HISTORY index a118bfb..67d2b1e 100755 --- a/HISTORY +++ b/HISTORY @@ -1,3 +1,6 @@ +Jan. 12 2016 +Fixed a routine evaluation bug when it's stored in a variable + Jan. 11 2016 Fixed a crash bug when a DO-UNTIL statement is the end of a program Fixed a memory leak with string manipulation diff --git a/core/my_basic.c b/core/my_basic.c index 188e3eb..30ad221 100755 --- a/core/my_basic.c +++ b/core/my_basic.c @@ -2969,8 +2969,13 @@ _routine: ); if(cs) { c = (_object_t*)cs->data; - if(c && c->type == _DT_ROUTINE) + if(c && c->type == _DT_ROUTINE) { goto _routine; + } else if(c && c->type == _DT_VAR && c->data.variable->data->type == _DT_ROUTINE) { + c = c->data.variable->data; + + goto _routine; + } } if(ast) { _object_t* _err_or_bracket = (_object_t*)ast->data;