develooper Front page | perl.perl5.porters | Postings from April 2014

Re: [perl #121501] Empty code block {} causes syntax error(misparsed as anonymous hash constructor?) before 'sub'

Thread Previous | Thread Next
From:
Ed Avis
Date:
April 14, 2014 15:11
Subject:
Re: [perl #121501] Empty code block {} causes syntax error(misparsed as anonymous hash constructor?) before 'sub'
Message ID:
7E039918541B4C4183BFDB8F015C74306B8358@WCL-EXCH02.wcl.local
Yes it's the if (foo) {} case I was thinking of. Since usually, if the block is nonempty, you can strip off the 'if', you should be able to do that with an empty block too - at least in the cases that currently give a syntax error. 

______________________________________________________________________
This email has been scanned by the Symantec Email Security.cloud service.
For more information please visit http://www.symanteccloud.com
______________________________________________________________________

Thread Previous | Thread Next


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About