From: Gurusamy Sarathy Date: Sun, 22 Jun 1997 02:47:36 +0000 (+1200) Subject: Fix intolerance of a space between "print" and opening paren X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=d1f3fb15f579862f85c82ed69eba4baa20281b3c;p=p5sagit%2Fp5-mst-13.2.git Fix intolerance of a space between "print" and opening paren On Tue, 01 Jul 1997 09:44:49 BST, "M.J.T. Guy" wrote: >Gurusamy Sarathy wrote >> (BTW, Perl's intolerance of a space between "print" and the >> opening paren under -w is quite annoying.) > >It may be annoying, but whenever I encounter it, it's _always_ telling me >about an error. At least not in these cases: perl -we "print (1)" perl -we "print (1) if 1" perl -we "print (1) unless 0" perl -we "print (1) while 0" The attached patch carries the kludge a little farther to avoid warnings in the last three cases. p5p-msgid: 199707011421.KAA15836@aatma.engin.umich.edu --- diff --git a/toke.c b/toke.c index 02b54e0..c5c32bf 100644 --- a/toke.c +++ b/toke.c @@ -4347,7 +4347,7 @@ char *what; } if (*w) for (; *w && isSPACE(*w); w++) ; - if (!*w || !strchr(";|})]oa!=", *w)) /* an advisory hack only... */ + if (!*w || !strchr(";|})]oaiuw!=", *w)) /* an advisory hack only... */ warn("%s (...) interpreted as function",name); } while (s < bufend && isSPACE(*s))