Skip to content

Commit

Permalink
Use setter macro instead of directly setting values
Browse files Browse the repository at this point in the history
  • Loading branch information
xxuejie committed Jan 26, 2015
1 parent 23e69ed commit d63e45a
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/vm.c
Expand Up @@ -1920,7 +1920,7 @@ mrb_context_run(mrb_state *mrb, struct RProc *proc, mrb_value self, unsigned int
SET_FLOAT_VALUE(mrb, regs[a], (mrb_float)x + (mrb_float)y);
break;
}
mrb_fixnum(regs[a]) = z;
SET_INT_VALUE(regs[a], z);
}
break;
case MRB_TT_FLOAT:
Expand Down Expand Up @@ -1958,7 +1958,7 @@ mrb_context_run(mrb_state *mrb, struct RProc *proc, mrb_value self, unsigned int
SET_FLOAT_VALUE(mrb, regs_a[0], (mrb_float)x - (mrb_float)y);
}
else {
mrb_fixnum(regs_a[0]) = z;
SET_INT_VALUE(regs_a[0], z);
}
}
break;
Expand Down

0 comments on commit d63e45a

Please sign in to comment.