summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNicholas Clark <nick@ccl4.org>2005-04-12 11:24:49 +0000
committerNicholas Clark <nick@ccl4.org>2005-04-12 11:24:49 +0000
commit4946a0facf2ed3326dca260a8311b490867691c5 (patch)
tree97e99ea3dd112aea026a59bc3d71747280ea21ca
parent607fa7f26ce8e3518faf053c2dbf72e6a35ee9b9 (diff)
downloadperl-4946a0facf2ed3326dca260a8311b490867691c5.tar.gz
Don't PERL_HASH(SvUVX(...)...) as it's actually a set.
Plus add an editor block p4raw-id: //depot/perl@24230
-rw-r--r--op.c28
1 files changed, 25 insertions, 3 deletions
diff --git a/op.c b/op.c
index 8f8de12d4f..3bd664862b 100644
--- a/op.c
+++ b/op.c
@@ -1587,7 +1587,11 @@ S_apply_attrs_my(pTHX_ HV *stash, OP *target, OP *attrs, OP **imopsp)
meth = newSVpvn("import", 6);
(void)SvUPGRADE(meth, SVt_PVIV);
(void)SvIOK_on(meth);
- PERL_HASH(SvUVX(meth), SvPVX(meth), SvCUR(meth));
+ {
+ U32 hash;
+ PERL_HASH(hash, SvPVX(meth), SvCUR(meth));
+ SvUV_set(meth, hash);
+ }
imop = convert(OP_ENTERSUB, OPf_STACKED|OPf_SPECIAL|OPf_WANT_VOID,
append_elem(OP_LIST,
prepend_elem(OP_LIST, pack, list(arg)),
@@ -3003,7 +3007,11 @@ Perl_utilize(pTHX_ int aver, I32 floor, OP *version, OP *idop, OP *arg)
meth = newSVpvn("VERSION",7);
sv_upgrade(meth, SVt_PVIV);
(void)SvIOK_on(meth);
- PERL_HASH(SvUVX(meth), SvPVX(meth), SvCUR(meth));
+ {
+ U32 hash;
+ PERL_HASH(hash, SvPVX(meth), SvCUR(meth));
+ SvUV_set(meth, hash);
+ }
veop = convert(OP_ENTERSUB, OPf_STACKED|OPf_SPECIAL,
append_elem(OP_LIST,
prepend_elem(OP_LIST, pack, list(version)),
@@ -3027,7 +3035,11 @@ Perl_utilize(pTHX_ int aver, I32 floor, OP *version, OP *idop, OP *arg)
meth = aver ? newSVpvn("import",6) : newSVpvn("unimport", 8);
(void)SvUPGRADE(meth, SVt_PVIV);
(void)SvIOK_on(meth);
- PERL_HASH(SvUVX(meth), SvPVX(meth), SvCUR(meth));
+ {
+ U32 hash;
+ PERL_HASH(hash, SvPVX(meth), SvCUR(meth));
+ SvUV_set(meth, hash);
+ }
imop = convert(OP_ENTERSUB, OPf_STACKED|OPf_SPECIAL,
append_elem(OP_LIST,
prepend_elem(OP_LIST, pack, list(arg)),
@@ -7070,3 +7082,13 @@ const_sv_xsub(pTHX_ CV* cv)
ST(0) = (SV*)XSANY.any_ptr;
XSRETURN(1);
}
+
+/*
+ * Local variables:
+ * c-indentation-style: bsd
+ * c-basic-offset: 4
+ * indent-tabs-mode: t
+ * End:
+ *
+ * vim: shiftwidth=4:
+*/