Ruby Newbie homepage Ruby Newbie homepage

How to use

Quick guide

Official content
Returns self if self is not frozen.
Otherwise. returns self.dup, which is not frozen.
 
               static VALUE
str_uplus(VALUE str)
{
    if (OBJ_FROZEN(str)) {
        return rb_str_dup(str);
    }
    else {
        return str;
    }
}
            

Was this page useful?