Keep It Simple, Stupid | |
PerlMonks |
Re: No av_splice function?by Util (Priest) |
on May 02, 2008 at 21:11 UTC ( [id://684258]=note: print w/replies, xml ) | Need Help?? |
My XS is rusty, but given that "splice" is not mentioned in perlapi or Extending and Embedding Perl, and that Perl's implementation of the splice opcode is about 130 SLOC (vs 7 SLOC for the push opcode and 36 SLOC for the delete opcode, due to their use of av_push and av_delete), I would say that no equivalent of splice() is accessible via XS.
Perhaps you can adapt the code that Perl itself uses; it is in file pp.c, in function pp_splice.
In Section
Seekers of Perl Wisdom
|
|