/* pp_hot.c
*
- * Copyright (c) 1991-1994, Larry Wall
+ * Copyright (c) 1991-1997, Larry Wall
*
* You may distribute under the terms of either the GNU General Public
* License or the Artistic License, as specified in the README file.
PP(pp_rv2av)
{
dSP; dPOPss;
-
AV *av;
if (SvROK(sv)) {
if (op->op_flags & OPf_REF ||
op->op_private & HINT_STRICT_REFS)
DIE(no_usym, "an ARRAY");
+ if (dowarn)
+ warn(warn_uninit);
if (GIMME == G_ARRAY)
RETURN;
RETPUSHUNDEF;
PP(pp_rv2hv)
{
-
dSP; dTOPss;
-
HV *hv;
if (SvROK(sv)) {
if (op->op_flags & OPf_REF ||
op->op_private & HINT_STRICT_REFS)
DIE(no_usym, "a HASH");
+ if (dowarn)
+ warn(warn_uninit);
if (GIMME == G_ARRAY) {
SP--;
RETURN;
else {
dTARGET;
if (HvFILL(hv)) {
- sprintf(buf, "%d/%d", HvFILL(hv), HvMAX(hv)+1);
+ sprintf(buf, "%ld/%ld", (long)HvFILL(hv), (long)HvMAX(hv)+1);
sv_setpv(TARG, buf);
}
else
}
else {
sv = TARG;
+ if (SvROK(sv))
+ sv_unref(sv);
(void)SvUPGRADE(sv, SVt_PV);
tmplen = SvLEN(sv); /* remember if already alloced */
if (!tmplen)