diff options
| author | yui-knk <[email protected]> | 2014-05-11 19:28:34 +0900 |
|---|---|---|
| committer | yui-knk <[email protected]> | 2014-05-11 19:28:34 +0900 |
| commit | e07099d81bde3add1249b645ae307b6edbf11efd (patch) | |
| tree | f433c5199066328b0ffd7076bb4fa04f43850831 | |
| parent | b1eb337a34f4b304f08a5bc59f03b6fc1ac02027 (diff) | |
| download | mruby-e07099d81bde3add1249b645ae307b6edbf11efd.tar.gz mruby-e07099d81bde3add1249b645ae307b6edbf11efd.zip | |
Add scr_e, to not reassign to e.
| -rw-r--r-- | src/error.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/error.c b/src/error.c index 6f7641cf1..bf764b6cd 100644 --- a/src/error.c +++ b/src/error.c @@ -445,7 +445,7 @@ mrb_sys_fail(mrb_state *mrb, const char *mesg) void mrb_init_exception(mrb_state *mrb) { - struct RClass *e; + struct RClass *e, *scr_e; mrb->eException_class = e = mrb_define_class(mrb, "Exception", mrb->object_class); /* 15.2.22 */ mrb_define_class_method(mrb, e, "exception", mrb_instance_new, MRB_ARGS_ANY()); @@ -459,6 +459,6 @@ mrb_init_exception(mrb_state *mrb) mrb->eStandardError_class = mrb_define_class(mrb, "StandardError", mrb->eException_class); /* 15.2.23 */ mrb_define_class(mrb, "RuntimeError", mrb->eStandardError_class); /* 15.2.28 */ - e = mrb_define_class(mrb, "ScriptError", mrb->eException_class); /* 15.2.37 */ - mrb_define_class(mrb, "SyntaxError", e); /* 15.2.38 */ + scr_e = mrb_define_class(mrb, "ScriptError", mrb->eException_class); /* 15.2.37 */ + mrb_define_class(mrb, "SyntaxError", scr_e); /* 15.2.38 */ } |
