summaryrefslogtreecommitdiff
path: root/pp_hot.c
diff options
context:
space:
mode:
authorNicholas Clark <nick@ccl4.org>2009-11-15 15:41:02 +0000
committerNicholas Clark <nick@ccl4.org>2009-11-15 16:31:58 +0000
commit973a76153032581ad3a0224d9cb13b7191f46ee5 (patch)
treee30469d82e516bf06c22a0182d47672c25861214 /pp_hot.c
parentf0e67a1d29102aa9905aecf2b0f98449697d5af3 (diff)
downloadperl-973a76153032581ad3a0224d9cb13b7191f46ee5.tar.gz
Inline PL_no_symref into pp_entersub. Deprecate the visible global variable.
As the core no longer needs this fixed string in more than one place, it seems daft to go to the overhead (and cost) of making it public in case any module wants to use it. Modules that do want to use it should provide their own inline copy in future. Also restore the visible global PL_no_symref back to the original format specification (of 5.10.0 and earlier), as an extra %s has the potential to cause SEGVs or worse if not spotted at compile time.
Diffstat (limited to 'pp_hot.c')
-rw-r--r--pp_hot.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/pp_hot.c b/pp_hot.c
index a74be213fa..48b57d6f7d 100644
--- a/pp_hot.c
+++ b/pp_hot.c
@@ -2700,7 +2700,7 @@ PP(pp_entersub)
if (!sym)
DIE(aTHX_ PL_no_usym, "a subroutine");
if (PL_op->op_private & HINT_STRICT_REFS)
- DIE(aTHX_ PL_no_symref, sym, len>32 ? "..." : "", "a subroutine");
+ DIE(aTHX_ "Can't use string (\"%.32s\"%s) as a subroutine ref while \"strict refs\" in use", sym, len>32 ? "..." : "");
cv = get_cvn_flags(sym, len, GV_ADD|SvUTF8(sv));
break;
}