summaryrefslogtreecommitdiff
path: root/gv.c
diff options
context:
space:
mode:
authorNicholas Clark <nick@ccl4.org>2008-04-17 13:36:21 +0000
committerNicholas Clark <nick@ccl4.org>2008-04-17 13:36:21 +0000
commitc9bf4021f2ca0ea941eae398f2988ab7096694c9 (patch)
treee971429307122c11804ff31dcd0e868c68347bc4 /gv.c
parenteff494dd14cc5afe1a584bb7e0000a62b81acc19 (diff)
downloadperl-c9bf4021f2ca0ea941eae398f2988ab7096694c9.tar.gz
Remove a dead case from the error reporting in
Perl_gv_fetchmethod_flags() p4raw-id: //depot/perl@33707
Diffstat (limited to 'gv.c')
-rw-r--r--gv.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/gv.c b/gv.c
index 0b17aec144..20eb17ebe7 100644
--- a/gv.c
+++ b/gv.c
@@ -624,6 +624,11 @@ Perl_gv_fetchmethod_flags(pTHX_ HV *stash, const char *name, U32 flags)
if (SvTYPE(stash) < SVt_PVHV)
stash = NULL;
+ else {
+ /* The only way stash can become NULL later on is if nsplit is set,
+ which in turn means that there is no need for a SVt_PVHV case
+ the error reporting code. */
+ }
for (nend = name; *nend; nend++) {
if (*nend == '\'') {
@@ -677,14 +682,9 @@ Perl_gv_fetchmethod_flags(pTHX_ HV *stash, const char *name, U32 flags)
STRLEN packlen;
const char *packname;
- assert(error_report);
-
if (nsplit) {
packlen = nsplit - origname;
packname = origname;
- } else if (SvTYPE(error_report) == SVt_PVHV) {
- packlen = HvNAMELEN_get(error_report);
- packname = HvNAME_get(error_report);
} else {
packname = SvPV_const(error_report, packlen);
}