Extended maintenance of Ruby versions 1.8.7 and 1.9.2 ended on July 31, 2014. Read more
Construct a new NameError exception. If given
the name parameter may subsequently be examined using the
NameError.name method.
static VALUE
name_err_initialize(argc, argv, self)
int argc;
VALUE *argv;
VALUE self;
{
VALUE name;
name = (argc > 1) ? argv[--argc] : Qnil;
rb_call_super(argc, argv);
rb_iv_set(self, "name", name);
return self;
}
Return the name associated with this NameError exception.
static VALUE
name_err_name(self)
VALUE self;
{
return rb_attr_get(self, rb_intern("name"));
}