From: Nicholas Clark Date: Wed, 15 Jun 2005 22:30:53 +0000 (+0000) Subject: assert that you aren't assigning to the NVX of an AV or HV X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=7ffec4a46145e860f68ade44063dbf377d1f5edc;p=p5sagit%2Fp5-mst-13.2.git assert that you aren't assigning to the NVX of an AV or HV p4raw-id: //depot/perl@24857 --- diff --git a/sv.h b/sv.h index e6aea8d..0835ccd 100644 --- a/sv.h +++ b/sv.h @@ -941,6 +941,7 @@ in gv.h: */ (((XPVIV*) SvANY(sv))->xiv_iv = (val)); } STMT_END #define SvNV_set(sv, val) \ STMT_START { assert(SvTYPE(sv) == SVt_NV || SvTYPE(sv) >= SVt_PVNV); \ + assert(SvTYPE(sv) != SVt_PVAV); assert(SvTYPE(sv) != SVt_PVHV); \ (((XPVNV*)SvANY(sv))->xnv_nv = (val)); } STMT_END #define SvPV_set(sv, val) \ STMT_START { assert(SvTYPE(sv) >= SVt_PV); \