summaryrefslogtreecommitdiff
path: root/scope.h
diff options
context:
space:
mode:
authorNicholas Clark <nick@ccl4.org>2006-04-14 20:44:27 +0000
committerNicholas Clark <nick@ccl4.org>2006-04-14 20:44:27 +0000
commit68da3b2f7c7c528e65bc6efc19ca01bacb8f7f98 (patch)
tree69e75b823ed74c9fcf43ef268af644b5559ec913 /scope.h
parent92c6daad83acab71abd7df8769e308064578da8e (diff)
downloadperl-68da3b2f7c7c528e65bc6efc19ca01bacb8f7f98.tar.gz
Change SAVECOPWARNINGS(c) to SAVECOMPILEWARNINGS() - it's only used to
save the warnings on PL_compiling, so constraining its use to what we can test seems to make sense. Particularly as testing Perl_ss_dup is tricky. p4raw-id: //depot/perl@27805
Diffstat (limited to 'scope.h')
-rw-r--r--scope.h11
1 files changed, 5 insertions, 6 deletions
diff --git a/scope.h b/scope.h
index 580d10946b..1506e5e1e1 100644
--- a/scope.h
+++ b/scope.h
@@ -51,7 +51,7 @@
#define SAVEt_SAVESWITCHSTACK 40
#define SAVEt_COP_ARYBASE 41
#define SAVEt_RE_STATE 42
-#define SAVEt_COP_WARNINGS 43
+#define SAVEt_COMPILE_WARNINGS 43
#ifndef SCOPE_SAVES_SIGNAL_MASK
#define SCOPE_SAVES_SIGNAL_MASK 0
@@ -198,12 +198,11 @@ Closing bracket on a callback. See C<ENTER> and L<perlcall>.
could have done savefreesharedpvREF, but this way actually seems cleaner,
as it simplifies the code that does the saves, and reduces the load on the
save stack. */
-#define SAVECOPWARNINGS(c) \
+#define SAVECOMPILEWARNINGS() \
STMT_START { \
- SSCHECK(3); \
- SSPUSHPTR((c)->cop_warnings); \
- SSPUSHPTR(c); \
- SSPUSHINT(SAVEt_COP_WARNINGS); \
+ SSCHECK(2); \
+ SSPUSHPTR(PL_compiling.cop_warnings); \
+ SSPUSHINT(SAVEt_COMPILE_WARNINGS); \
} STMT_END
#ifdef USE_ITHREADS