summaryrefslogtreecommitdiff
path: root/gv.c
diff options
context:
space:
mode:
authorSteve Hay <steve.m.hay@googlemail.com>2014-02-25 08:59:07 +0000
committerSteve Hay <steve.m.hay@googlemail.com>2014-02-25 08:59:07 +0000
commitc161da64987b034d3b410518a0c174d74958b938 (patch)
treea3d3cb5768be9f7907cea721b79ad03b51b81e0b /gv.c
parentb057411ddb1a3d8b6ab062d667c8e39f80cd7343 (diff)
downloadperl-c161da64987b034d3b410518a0c174d74958b938.tar.gz
Silence some VC++ compiler warnings
gv.c(1455) : warning C4146: unary minus operator applied to unsigned type, result still unsigned gv.c(1586) : warning C4146: unary minus operator applied to unsigned type, result still unsigned gv.c(2122) : warning C4146: unary minus operator applied to unsigned type, result still unsigned toke.c(12423) : warning C4244: '=' : conversion from 'I32' to 'char', possible loss of data win32.c(3017) : warning C4022: 'SetHandleInformation' : pointer mismatch for actual parameter 1 win32.c(2971) : warning C4101: 'old_h' : unreferenced local variable win32.c(2967) : warning C4101: 'oldfd' : unreferenced local variable
Diffstat (limited to 'gv.c')
-rw-r--r--gv.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/gv.c b/gv.c
index bda30b1a54..42cd69cb16 100644
--- a/gv.c
+++ b/gv.c
@@ -1452,7 +1452,7 @@ S_parse_gv_stash_name(pTHX_ HV **stash, GV **gv, const char **name,
tmpbuf[(*len)++] = ':';
key = tmpbuf;
}
- gvp = (GV**)hv_fetch(*stash, key, is_utf8 ? -(*len) : *len, add);
+ gvp = (GV**)hv_fetch(*stash, key, is_utf8 ? -((I32)*len) : (I32)*len, add);
*gv = gvp ? *gvp : NULL;
if (*gv && *gv != (const GV *)&PL_sv_undef) {
if (SvTYPE(*gv) != SVt_PVGV)
@@ -1583,7 +1583,7 @@ S_find_default_stash(pTHX_ HV **stash, const char *name, STRLEN len,
!(len == 1 && sv_type == SVt_PV &&
(*name == 'a' || *name == 'b')) )
{
- GV**gvp = (GV**)hv_fetch(*stash,name,is_utf8 ? -len : len,0);
+ GV**gvp = (GV**)hv_fetch(*stash,name,is_utf8 ? -(I32)len : (I32)len,0);
if (!gvp || *gvp == (const GV *)&PL_sv_undef ||
SvTYPE(*gvp) != SVt_PVGV)
{
@@ -2119,7 +2119,7 @@ Perl_gv_fetchpvn_flags(pTHX_ const char *nambeg, STRLEN full_len, I32 flags,
}
/* By this point we should have a stash and a name */
- gvp = (GV**)hv_fetch(stash,name,is_utf8 ? -len : len,add);
+ gvp = (GV**)hv_fetch(stash,name,is_utf8 ? -(I32)len : (I32)len,add);
if (!gvp || *gvp == (const GV *)&PL_sv_undef) {
if (addmg) gv = (GV *)newSV(0);
else return NULL;