summaryrefslogtreecommitdiff
path: root/gv.c
diff options
context:
space:
mode:
authorGurusamy Sarathy <gsar@cpan.org>1999-12-24 04:02:35 +0000
committerGurusamy Sarathy <gsar@cpan.org>1999-12-24 04:02:35 +0000
commita7cb1f9979dd83ab32266dc555f72f0939829c3f (patch)
tree30e708b7b59c1b8455a51a5b82a59ea9312de117 /gv.c
parentc63481edeb5a500b5e56c74ce83175790d2adf8a (diff)
downloadperl-a7cb1f9979dd83ab32266dc555f72f0939829c3f.tar.gz
support for v5.5.640 style version numbers
p4raw-id: //depot/utfperl@4705
Diffstat (limited to 'gv.c')
-rw-r--r--gv.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/gv.c b/gv.c
index e1e4ae081c..e2c63497ce 100644
--- a/gv.c
+++ b/gv.c
@@ -812,10 +812,8 @@ Perl_gv_fetchpv(pTHX_ const char *nambeg, I32 add, I32 sv_type)
case ']':
if (len == 1) {
SV *sv = GvSV(gv);
- (void)SvUPGRADE(sv, SVt_PVNV);
- sv_setpv(sv, PL_patchlevel);
- (void)sv_2nv(sv);
- SvREADONLY_on(sv);
+ GvSV(gv) = SvREFCNT_inc(PL_patchlevel);
+ SvREFCNT_dec(sv);
}
break;
}