From 9134ea20ecf6c7a898519ea43ac463bc4da08840 Mon Sep 17 00:00:00 2001 From: Yves Orton Date: Mon, 26 Oct 2009 21:52:05 +0100 Subject: add an elipses to string/ref warnings when str longer than 32 chars Wasted a few minutes more than necessary trying to work out why the string was truncated when in fact it was the error message that was truncating the string. --- pp_hot.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'pp_hot.c') diff --git a/pp_hot.c b/pp_hot.c index 16992d47b7..0730aff1a7 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, "a subroutine"); + DIE(aTHX_ PL_no_symref, sym, len>32 ? "..." : "", "a subroutine"); cv = get_cvn_flags(sym, len, GV_ADD|SvUTF8(sv)); break; } -- cgit v1.2.1