summaryrefslogtreecommitdiff
path: root/pad.h
diff options
context:
space:
mode:
Diffstat (limited to 'pad.h')
-rw-r--r--pad.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/pad.h b/pad.h
index acfb58e47d..022a7de582 100644
--- a/pad.h
+++ b/pad.h
@@ -50,14 +50,20 @@ typedef enum {
* whether PL_comppad and PL_curpad are consistent and whether they have
* active values */
+#ifndef PERL_MAD
+# define pad_peg(label)
+#endif
+
#ifdef DEBUGGING
# define ASSERT_CURPAD_LEGAL(label) \
+ pad_peg(label); \
if (PL_comppad ? (AvARRAY(PL_comppad) != PL_curpad) : (PL_curpad != 0)) \
Perl_croak(aTHX_ "panic: illegal pad in %s: 0x%"UVxf"[0x%"UVxf"]",\
label, PTR2UV(PL_comppad), PTR2UV(PL_curpad));
# define ASSERT_CURPAD_ACTIVE(label) \
+ pad_peg(label); \
if (!PL_comppad || (AvARRAY(PL_comppad) != PL_curpad)) \
Perl_croak(aTHX_ "panic: invalid pad in %s: 0x%"UVxf"[0x%"UVxf"]",\
label, PTR2UV(PL_comppad), PTR2UV(PL_curpad));