summaryrefslogtreecommitdiff
path: root/sv.h
diff options
context:
space:
mode:
authorNicholas Clark <nick@ccl4.org>2006-12-11 22:52:46 +0000
committerNicholas Clark <nick@ccl4.org>2006-12-11 22:52:46 +0000
commit39efed7fb68a394db844e6c312aadb72695b0ad8 (patch)
tree51f168a220b69826b73c62d0e0afcac285491ab1 /sv.h
parent373b357f184d67d2c589b8aca81c803276397db5 (diff)
downloadperl-39efed7fb68a394db844e6c312aadb72695b0ad8.tar.gz
Add BmPREVIOUS_set(), and use it in the one place that BmPREVIOUS is
modified. p4raw-id: //depot/perl@29525
Diffstat (limited to 'sv.h')
-rw-r--r--sv.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/sv.h b/sv.h
index 8c98c892cc..a80a0ac083 100644
--- a/sv.h
+++ b/sv.h
@@ -1347,6 +1347,9 @@ the scalar's value cannot change unless written to.
# define BmUSEFUL(sv) ((XPVBM*) SvANY(sv))->xiv_u.xivu_i32
# define BmPREVIOUS(sv) ((XPVBM*) SvANY(sv))->xbm_previous
#endif
+#define BmPREVIOUS_set(sv, val) \
+ STMT_START { assert(SvTYPE(sv) == SVt_PVBM); \
+ (((XPVBM*)SvANY(sv))->xbm_previous = (U16)(val)); } STMT_END
#define FmLINES(sv) ((XPVFM*) SvANY(sv))->xfm_lines