use warnings; use Inline C => Config => CLEAN_AFTER_BUILD => 0, BUILD_NOISY => 1; use Inline C => <<'EOC'; SV * foo1(SV * a) { SV * c = newSVsv(a); return c; } SV * foo2(SV * a) { return SvREFCNT_inc(a); } EOC $x = 'hello'; print foo1($x); print foo1(" world\n"); print foo2($x); print foo2(" world\n"); __END__ D:\pscrpt\inline>perl try.pl hello world hello world
In reply to Re: XS/Inline::C concat *any* two SVs.
by syphilis
in thread XS/Inline::C concat *any* two SVs.
by BrowserUk
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |