Add private coreargs flags for vivifying GVs
authorFather Chrysostomos <sprout@cpan.org>
Sat, 20 Aug 2011 06:04:04 +0000 (23:04 -0700)
committerFather Chrysostomos <sprout@cpan.org>
Thu, 25 Aug 2011 16:42:18 +0000 (09:42 -0700)
ext/B/B/Concise.pm
op.h

index 0df5e42..cc0e052 100644 (file)
@@ -14,7 +14,7 @@ use warnings; # uses #3 and #4, since warnings uses Carp
 
 use Exporter (); # use #5
 
-our $VERSION   = "0.85";
+our $VERSION   = "0.86";
 our @ISA       = qw(Exporter);
 our @EXPORT_OK = qw( set_style set_style_standard add_callback
                     concise_subref concise_cv concise_main
@@ -661,6 +661,7 @@ if ($] >= 5.009) {
     for ("mapwhile", "mapstart", "grepwhile", "grepstart");
 }
 $priv{$_}{128} = '+1' for qw "caller wantarray";
+@{$priv{coreargs}}{1,2} = ('DREF1','DREF2');
 
 our %hints; # used to display each COP's op_hints values
 
diff --git a/op.h b/op.h
index e0fdc81..6dcbbf0 100644 (file)
--- a/op.h
+++ b/op.h
@@ -297,6 +297,11 @@ Deprecated.  Use C<GIMME_V> instead.
 /* Private for OP_CALLER and OP_WANTARRAY */
 #define OPpOFFBYONE            128     /* Treat caller(1) as caller(2) */
 
+/* Private for OP_COREARGS */
+/* These must not conflict with OPpDONT_INIT_GV.  See pp.c:S_rv2gv. */
+#define OPpCOREARGS_DEREF1     1       /* Arg 1 is a handle constructor */
+#define OPpCOREARGS_DEREF2     2       /* Arg 2 is a handle constructor */
+
 struct op {
     BASEOP
 };