Avoid using `mrb_str_to_cstr` if possible
Because it always allocate new string. Replace with the followings: - Use `RSRING_PTR` if string is guaranteed to be null-terminated. - Use `mrb_string_value_cstr` or `mrb_get_args("z")` if return value isn't modified.
Showing
Please register or sign in to comment