[Jifty-commit] r5348 - B

Jifty commits jifty-commit at lists.jifty.org
Wed Apr 30 17:34:06 EDT 2008


Author: clkao
Date: Wed Apr 30 17:34:05 2008
New Revision: 5348

Modified:
   B/B.xs

Log:
CV->NEW_with_start.


Modified: B/B.xs
==============================================================================
--- B/B.xs	(original)
+++ B/B.xs	Wed Apr 30 17:34:05 2008
@@ -1742,6 +1742,30 @@
 CvOUTSIDE(cv)
 	B::CV	cv
 
+#define PERL_CORE
+#include "embed.h"
+
+#define newSV_type(a)           Perl_newSV_type(aTHX_ a)
+
+B::CV
+CvNEW_with_start(cv, root, start)
+	B::CV	cv
+        B::OP   root
+        B::OP   start
+    PREINIT:
+       CV *new;
+    CODE:
+       new = (CV *)newSV(0);
+       sv_upgrade((SV *)new, SvTYPE(cv));
+       *new = *cv;
+       CvROOT(new) = root;
+       CvSTART(new) = start;
+       RETVAL = new;
+    OUTPUT:
+       RETVAL
+
+#undef PERL_CORE
+
 U32
 CvOUTSIDE_SEQ(cv)
 	B::CV	cv


More information about the Jifty-commit mailing list