Showing the changes to src/core/chuck_emit.cpp (1 of 2 files). Show all
Unified · Split
| @@ -74,7 +74,7 @@ t_CKBOOL emit_engine_emit_exp_postfix( Chuck_Emitter * emit, a_Exp_Postfix postf · 73 unmodified lines | |||
| 74 | t_CKBOOL emit_engine_emit_exp_dur( Chuck_Emitter * emit, a_Exp_Dur dur ); | 74 | t_CKBOOL emit_engine_emit_exp_dur( Chuck_Emitter * emit, a_Exp_Dur dur ); |
| 75 | t_CKBOOL emit_engine_emit_exp_array( Chuck_Emitter * emit, a_Exp_Array array ); | 75 | t_CKBOOL emit_engine_emit_exp_array( Chuck_Emitter * emit, a_Exp_Array array ); |
| 76 | t_CKBOOL emit_engine_emit_exp_func_call( Chuck_Emitter * emit, Chuck_Func * func, | 76 | t_CKBOOL emit_engine_emit_exp_func_call( Chuck_Emitter * emit, Chuck_Func * func, |
| 77 | a_Exp args, Chuck_Type * type, int linepos, t_CKBOOL spork = FALSE ); | 77 | Chuck_Type * type, int linepos, t_CKBOOL spork = FALSE ); |
| 78 | t_CKBOOL emit_engine_emit_exp_func_call( Chuck_Emitter * emit, a_Exp_Func_Call func_call, | 78 | t_CKBOOL emit_engine_emit_exp_func_call( Chuck_Emitter * emit, a_Exp_Func_Call func_call, |
| 79 | t_CKBOOL spork = FALSE ); | 79 | t_CKBOOL spork = FALSE ); |
| 80 | t_CKBOOL emit_engine_emit_func_args( Chuck_Emitter * emit, a_Exp_Func_Call func_call ); | 80 | t_CKBOOL emit_engine_emit_func_args( Chuck_Emitter * emit, a_Exp_Func_Call func_call ); |
| @@ -2565,7 +2565,7 @@ t_CKBOOL emit_engine_emit_op_chuck( Chuck_Emitter * emit, a_Exp lhs, a_Exp rhs, · 2484 unmodified lines | |||
| 2565 | assert( binary->ck_func != NULL ); | 2565 | assert( binary->ck_func != NULL ); |
| 2566 | 2566 | ||
| 2567 | // emit | 2567 | // emit |
| 2568 | return emit_engine_emit_exp_func_call( emit, binary->ck_func, binary->lhs, binary->self->type, binary->linepos ); | 2568 | return emit_engine_emit_exp_func_call( emit, binary->ck_func, binary->self->type, binary->linepos ); |
| 2569 | } | 2569 | } |
| 2570 | 2570 | ||
| 2571 | // assignment or something else | 2571 | // assignment or something else |
| @@ -3429,7 +3429,6 @@ t_CKBOOL emit_engine_emit_exp_array( Chuck_Emitter * emit, a_Exp_Array array ) · 857 unmodified lines | |||
| 3429 | //----------------------------------------------------------------------------- | 3429 | //----------------------------------------------------------------------------- |
| 3430 | t_CKBOOL emit_engine_emit_exp_func_call( Chuck_Emitter * emit, | 3430 | t_CKBOOL emit_engine_emit_exp_func_call( Chuck_Emitter * emit, |
| 3431 | Chuck_Func * func, | 3431 | Chuck_Func * func, |
| 3432 | a_Exp args, | ||
| 3433 | Chuck_Type * type, | 3432 | Chuck_Type * type, |
| 3434 | int linepos, | 3433 | int linepos, |
| 3435 | t_CKBOOL spork ) | 3434 | t_CKBOOL spork ) |
| @@ -3531,7 +3530,7 @@ t_CKBOOL emit_engine_emit_exp_func_call( Chuck_Emitter * emit, · 95 unmodified lines | |||
| 3531 | } | 3530 | } |
| 3532 | 3531 | ||
| 3533 | // the rest | 3532 | // the rest |
| 3534 | return emit_engine_emit_exp_func_call( emit, func_call->ck_func, func_call->args, | 3533 | return emit_engine_emit_exp_func_call( emit, func_call->ck_func, |
| 3535 | func_call->ret_type, func_call->linepos, spork ); | 3534 | func_call->ret_type, func_call->linepos, spork ); |
| 3536 | } | 3535 | } |
| 3537 | 3536 | ||
| @@ -4819,7 +4818,6 @@ t_CKBOOL emit_engine_emit_spork( Chuck_Emitter * emit, a_Exp_Func_Call exp ) · 1281 unmodified lines | |||
| 4819 | // call the func on sporkee shred | 4818 | // call the func on sporkee shred |
| 4820 | if( !emit_engine_emit_exp_func_call( emit, | 4819 | if( !emit_engine_emit_exp_func_call( emit, |
| 4821 | exp->ck_func, | 4820 | exp->ck_func, |
| 4822 | exp->args, | ||
| 4823 | exp->ret_type, | 4821 | exp->ret_type, |
| 4824 | exp->linepos, | 4822 | exp->linepos, |
| 4825 | TRUE ) ) return FALSE; | 4823 | TRUE ) ) return FALSE; |
| @@ -5142,16 +5140,12 @@ void Chuck_Emitter::traverse_scope_on_jump( ) · 316 unmodified lines | |||
| 5142 | // skip scope boundary (denoted by NULL) | 5140 | // skip scope boundary (denoted by NULL) |
| 5143 | if( !local ) continue; | 5141 | if( !local ) continue; |
| 5144 | 5142 | ||
| 5145 | // CK_STDCERR << "local: " << local->offset << " " << local->is_obj << CK_STDENDL; | 5143 | // check to see if it's an object (but not global) |
| 5146 | // check to see if it's an object | 5144 | // (REFACTOR-2017: don't release global objects) |
| 5147 | if( local->is_obj ) | 5145 | if( local->is_obj && !local->is_global ) |
| 5148 | { | 5146 | { |
| 5149 | // (REFACTOR-2017: don't release global objects) | 5147 | // emit instruction to release the object |
| 5150 | if( !local->is_global ) | 5148 | this->append( new Chuck_Instr_Release_Object2( local->offset ) ); |
| 5151 | { | ||
| 5152 | // emit instruction to release the object | ||
| 5153 | this->append( new Chuck_Instr_Release_Object2( local->offset ) ); | ||
| 5154 | } | ||
| 5155 | } | 5149 | } |
| 5156 | } | 5150 | } |
| 5157 | 5151 | ||