summaryrefslogtreecommitdiff
path: root/scope.h
diff options
context:
space:
mode:
authorGurusamy Sarathy <gsar@cpan.org>1998-02-14 01:00:15 +0000
committerGurusamy Sarathy <gsar@cpan.org>1998-02-14 01:00:15 +0000
commit9e67d94e6e4396a78a2012441f9359240f5b4bdd (patch)
treefc1c6466e151f0e066a87df256b70d1b8cc35a91 /scope.h
parent9d8a25dc64d23dcd5730db9be0dbe94a107e1f8b (diff)
parentb17fe6e572cf341e620c89fc18fb670ef7f916a6 (diff)
downloadperl-9e67d94e6e4396a78a2012441f9359240f5b4bdd.tar.gz
[asperl] bring ASPerl uptodate with mainline changes
p4raw-id: //depot/asperl@524
Diffstat (limited to 'scope.h')
-rw-r--r--scope.h15
1 files changed, 15 insertions, 0 deletions
diff --git a/scope.h b/scope.h
index 318f69ebbf..757161e89a 100644
--- a/scope.h
+++ b/scope.h
@@ -39,8 +39,23 @@
#define SAVETMPS save_int((int*)&tmps_floor), tmps_floor = tmps_ix
#define FREETMPS if (tmps_ix > tmps_floor) free_tmps()
+#ifdef DEBUGGING
+#define ENTER \
+ STMT_START { \
+ push_scope(); \
+ DEBUG_l(WITH_THR(deb("ENTER scope %ld at %s:%d\n", \
+ scopestack_ix, __FILE__, __LINE__))); \
+ } STMT_END
+#define LEAVE \
+ STMT_START { \
+ DEBUG_l(WITH_THR(deb("LEAVE scope %ld at %s:%d\n", \
+ scopestack_ix, __FILE__, __LINE__))); \
+ pop_scope(); \
+ } STMT_END
+#else
#define ENTER push_scope()
#define LEAVE pop_scope()
+#endif
#define LEAVE_SCOPE(old) if (savestack_ix > old) leave_scope(old)
/*