From e2ae18322e820d209c08ca6740d8938b0267c7d7 Mon Sep 17 00:00:00 2001 From: Rafael Garcia-Suarez Date: Fri, 9 May 2003 21:23:57 +0000 Subject: [PATCH] Remove the error messages "Final @ should be \@ or @name" and "Final % should be \% or %name", that appear to be only produced in addition to another syntax error, and therefore misleading, if I understand correctly that kind of black magic. p4raw-id: //depot/perl@19468 --- pod/perldiag.pod | 7 ------- toke.c | 4 ---- 2 files changed, 11 deletions(-) diff --git a/pod/perldiag.pod b/pod/perldiag.pod index f40b7a0..8a744b9 100644 --- a/pod/perldiag.pod +++ b/pod/perldiag.pod @@ -1520,13 +1520,6 @@ a literal dollar sign, or was meant to introduce a variable name that happens to be missing. So you have to put either the backslash or the name. -=item Final @ should be \@ or @name - -(F) You must now decide whether the final @ in a string was meant to be -a literal "at" sign, or was meant to introduce a variable name that -happens to be missing. So you have to put either the backslash or the -name. - =item flock() on closed filehandle %s (W closed) The filehandle you're attempting to flock() got itself closed diff --git a/toke.c b/toke.c index 850480c..4d694cd 100644 --- a/toke.c +++ b/toke.c @@ -2940,8 +2940,6 @@ Perl_yylex(pTHX) PL_tokenbuf[0] = '%'; s = scan_ident(s, PL_bufend, PL_tokenbuf + 1, sizeof PL_tokenbuf - 1, TRUE); if (!PL_tokenbuf[1]) { - if (s == PL_bufend) - yyerror("Final % should be \\% or %name"); PREREF('%'); } PL_pending_ident = '%'; @@ -3575,8 +3573,6 @@ Perl_yylex(pTHX) PL_tokenbuf[0] = '@'; s = scan_ident(s, PL_bufend, PL_tokenbuf + 1, sizeof PL_tokenbuf - 1, FALSE); if (!PL_tokenbuf[1]) { - if (s == PL_bufend) - yyerror("Final @ should be \\@ or @name"); PREREF('@'); } if (PL_lex_state == LEX_NORMAL) -- 2.7.4