diff --git a/src/c/interpreter.d b/src/c/interpreter.d index 0a0aaad8d..07985494b 100644 --- a/src/c/interpreter.d +++ b/src/c/interpreter.d @@ -124,8 +124,8 @@ ecl_stack_frame_push(cl_object f, cl_object o) if (top >= env->stack_limit) { top = ecl_stack_grow(env); } - *top = o; env->stack_top = ++top; + *(top-1) = o; f->frame.base = top - (++(f->frame.size)); f->frame.stack = env->stack; } diff --git a/src/h/stacks.h b/src/h/stacks.h index 15b068b78..815f7f563 100755 --- a/src/h/stacks.h +++ b/src/h/stacks.h @@ -334,8 +334,8 @@ extern ECL_API ecl_frame_ptr _ecl_frs_push(register cl_env_ptr, register cl_obje if (ecl_unlikely(__new_top >= __env->stack_limit)) { \ __new_top = ecl_stack_grow(__env); \ } \ - *__new_top = (o); \ - __env->stack_top = __new_top+1; } while (0) + __env->stack_top = __new_top+1; \ + *__new_top = (o); } while (0) #define ECL_STACK_POP_UNSAFE(env) *(--((env)->stack_top))