[differences between cumulative patch application and perl-5.003_97a]
[p5sagit/p5-mst-13.2.git] / dump.c
diff --git a/dump.c b/dump.c
index c0749b8..e74c8c4 100644 (file)
--- a/dump.c
+++ b/dump.c
@@ -1,6 +1,6 @@
 /*    dump.c
  *
- *    Copyright (c) 1991-1994, Larry Wall
+ *    Copyright (c) 1991-1997, Larry Wall
  *
  *    You may distribute under the terms of either the GNU General Public
  *    License or the Artistic License, as specified in the README file.
@@ -50,7 +50,7 @@ HV* stash;
        for (entry = HvARRAY(stash)[i]; entry; entry = HeNEXT(entry)) {
            GV *gv = (GV*)HeVAL(entry);
            HV *hv;
-           if (GvCV(gv))
+           if (GvCVu(gv))
                dump_sub(gv);
            if (GvFORM(gv))
                dump_form(gv);
@@ -131,14 +131,20 @@ register OP *op;
 #endif
     if (op->op_flags) {
        *buf = '\0';
-       if (op->op_flags & OPf_KNOW) {
-           if (op->op_flags & OPf_LIST)
-               (void)strcat(buf,"LIST,");
-           else
-               (void)strcat(buf,"SCALAR,");
-       }
-       else
+       switch (op->op_flags & OPf_WANT) {
+       case OPf_WANT_VOID:
+           (void)strcat(buf,"VOID,");
+           break;
+       case OPf_WANT_SCALAR:
+           (void)strcat(buf,"SCALAR,");
+           break;
+       case OPf_WANT_LIST:
+           (void)strcat(buf,"LIST,");
+           break;
+       default:
            (void)strcat(buf,"UNKNOWN,");
+           break;
+       }
        if (op->op_flags & OPf_KIDS)
            (void)strcat(buf,"KIDS,");
        if (op->op_flags & OPf_PARENS)
@@ -185,10 +191,12 @@ register OP *op;
                 op->op_type == OP_AELEM ||
                 op->op_type == OP_HELEM )
        {
-           if (op->op_private & OPpENTERSUB_AMPER)
-               (void)strcat(buf,"AMPER,");
-           if (op->op_private & OPpENTERSUB_DB)
-               (void)strcat(buf,"DB,");
+           if (op->op_type == OP_ENTERSUB) {
+               if (op->op_private & OPpENTERSUB_AMPER)
+                   (void)strcat(buf,"AMPER,");
+               if (op->op_private & OPpENTERSUB_DB)
+                   (void)strcat(buf,"DB,");
+           }
            switch (op->op_private & OPpDEREF) {
            case OPpDEREF_SV:
                (void)strcat(buf, "SV,");
@@ -200,8 +208,14 @@ register OP *op;
                (void)strcat(buf, "HV,");
                break;
            }
-           if (op->op_private & HINT_STRICT_REFS)
-               (void)strcat(buf,"STRICT_REFS,");
+           if (op->op_type == OP_AELEM || op->op_type == OP_HELEM) {
+               if (op->op_private & OPpLVAL_DEFER)
+                   (void)strcat(buf,"LVAL_DEFER,");
+           }
+           else {
+               if (op->op_private & HINT_STRICT_REFS)
+                   (void)strcat(buf,"STRICT_REFS,");
+           }
        }
        else if (op->op_type == OP_CONST) {
            if (op->op_private & OPpCONST_BARE)