On Nov 8, 2011, at 12:10 PM, Martin Hansen wrote: > I was in doubt whether to use: > > char* s = StringValuePtr(rb_iv_get(self, "@seq")); > > or > > char* s = RSTRING_PTR(rb_iv_get(self, "@seq")) > > I see now that the first is plain wrong, but what about the latter? When > is that used? > > I tried to apply the suggested changes, but the C code still have "VALUE > self" as first argument in the functions. How did you get rid of that? Did you change line 38 in http://pastie.org/2825882 from "builder.c %{" to "builder.prefix %{" ? If you don't define backtrack as an instance method, self will not be expected to be passed as first argument.