mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
* eval.c (Init_eval), gc.c (Init_GC), proc.c (Init_Proc): freeze
messages of preallocated special exceptions also. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@17833 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
7f637ab96f
commit
bb350b04e5
4 changed files with 11 additions and 3 deletions
|
@ -1,3 +1,8 @@
|
|||
Thu Jul 3 07:02:55 2008 Nobuyoshi Nakada <nobu@ruby-lang.org>
|
||||
|
||||
* eval.c (Init_eval), gc.c (Init_GC), proc.c (Init_Proc): freeze
|
||||
messages of preallocated special exceptions also.
|
||||
|
||||
Thu Jul 3 04:39:30 2008 Nobuyoshi Nakada <nobu@ruby-lang.org>
|
||||
|
||||
* gc.c (rb_during_gc): VALUE cache is irrelevant.
|
||||
|
|
3
eval.c
3
eval.c
|
@ -1201,7 +1201,8 @@ Init_eval(void)
|
|||
|
||||
rb_define_virtual_variable("$SAFE", safe_getter, safe_setter);
|
||||
|
||||
exception_error = rb_exc_new2(rb_eFatal, "exception reentered");
|
||||
exception_error = rb_exc_new2(rb_eFatal,
|
||||
rb_obj_freeze(rb_str_new2("exception reentered")));
|
||||
rb_ivar_set(exception_error, idThrowState, INT2FIX(TAG_FATAL));
|
||||
OBJ_TAINT(exception_error);
|
||||
OBJ_FREEZE(exception_error);
|
||||
|
|
3
gc.c
3
gc.c
|
@ -2531,7 +2531,8 @@ Init_GC(void)
|
|||
|
||||
rb_define_module_function(rb_mObSpace, "_id2ref", id2ref, 1);
|
||||
|
||||
nomem_error = rb_exc_new2(rb_eNoMemError, "failed to allocate memory");
|
||||
nomem_error = rb_exc_new3(rb_eNoMemError,
|
||||
rb_obj_freeze(rb_str_new2("failed to allocate memory")));
|
||||
OBJ_TAINT(nomem_error);
|
||||
OBJ_FREEZE(nomem_error);
|
||||
|
||||
|
|
3
proc.c
3
proc.c
|
@ -1760,7 +1760,8 @@ Init_Proc(void)
|
|||
rb_define_method(rb_eLocalJumpError, "reason", localjump_reason, 0);
|
||||
|
||||
rb_eSysStackError = rb_define_class("SystemStackError", rb_eException);
|
||||
sysstack_error = rb_exc_new2(rb_eSysStackError, "stack level too deep");
|
||||
sysstack_error = rb_exc_new3(rb_eSysStackError,
|
||||
rb_obj_freeze(rb_str_new2("stack level too deep")));
|
||||
OBJ_TAINT(sysstack_error);
|
||||
OBJ_FREEZE(sysstack_error);
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue