1#include "ruby.h" 2 3VALUE 4bug_str_modify(VALUE str) 5{ 6 rb_str_modify(str); 7 return str; 8} 9 10VALUE 11bug_str_modify_expand(VALUE str, VALUE expand) 12{ 13 rb_str_modify_expand(str, NUM2LONG(expand)); 14 return str; 15} 16 17void 18Init_modify(VALUE klass) 19{ 20 rb_define_method(klass, "modify!", bug_str_modify, 0); 21 rb_define_method(klass, "modify_expand!", bug_str_modify_expand, 1); 22} 23