ruby-changes:59251
From: Nobuyoshi <ko1@a...>
Date: Sun, 15 Dec 2019 01:42:00 +0900 (JST)
Subject: [ruby-changes:59251] db2ea9b0c5 (master): [DOC] Fixed the class name in FrozenError#receiver
https://git.ruby-lang.org/ruby.git/commit/?id=db2ea9b0c5 From db2ea9b0c5fb49a04af1b299a37e92f81d7cccd2 Mon Sep 17 00:00:00 2001 From: Nobuyoshi Nakada <nobu@r...> Date: Sun, 15 Dec 2019 00:21:19 +0900 Subject: [DOC] Fixed the class name in FrozenError#receiver diff --git a/error.c b/error.c index 7ef252f..9da36ae 100644 --- a/error.c +++ b/error.c @@ -1435,6 +1435,15 @@ frozen_err_initialize(int argc, VALUE *argv, VALUE self) https://github.com/ruby/ruby/blob/trunk/error.c#L1435 return self; } +/* + * call-seq: + * frozen_error.receiver -> object + * + * Return the receiver associated with this FrozenError exception. + */ + +#define frozen_err_receiver name_err_receiver + void rb_name_error(ID id, const char *fmt, ...) { @@ -2529,7 +2538,7 @@ Init_Exception(void) https://github.com/ruby/ruby/blob/trunk/error.c#L2538 rb_eRuntimeError = rb_define_class("RuntimeError", rb_eStandardError); rb_eFrozenError = rb_define_class("FrozenError", rb_eRuntimeError); rb_define_method(rb_eFrozenError, "initialize", frozen_err_initialize, -1); - rb_define_method(rb_eFrozenError, "receiver", name_err_receiver, 0); + rb_define_method(rb_eFrozenError, "receiver", frozen_err_receiver, 0); rb_eSecurityError = rb_define_class("SecurityError", rb_eException); rb_eNoMemError = rb_define_class("NoMemoryError", rb_eException); rb_eEncodingError = rb_define_class("EncodingError", rb_eStandardError); -- cgit v0.10.2 -- ML: ruby-changes@q... Info: http://www.atdot.net/~ko1/quickml/