On Mon, Mar 26, 2012 at 06:10:08PM +0200, Manfred Lotz wrote: > On 25 Mar 2012 13:11:16 -0000 > Peter Scott <pe...@psdt.com> wrote: > > > On Thu, 22 Mar 2012 20:06:35 -0400, Uri Guttman wrote: > > > no one uses braces for single scalar handles in general. > > > > I do. Ever since Damian recommended it (Perl Best Practices, page > > 217). One of those numerous times I didn't agree with him until I > > tried it, then found he was right. > > > > Peter, thanks for this. As it is a goal for me as a Perl beginner to > learn a good Perl coding style I will stick to this also.
It's a good goal to have, but remember the Perl motto: There's more than one way to do it. You're unlikely to go wrong following the advice in perstyle: http://perldoc.perl.org/perlstyle.html. But outside of that opinions, are likely to diverge. In this case I suspect there'll be at least at many people telling you to drop the braces as there are to add them. Indeed, it could be argued that adding them goes against the perlstyle advice: Omit redundant punctuation as long as clarity doesn't suffer. So, to a certain extent, you'll need to devise your own style. -- Paul Johnson - p...@pjcj.net http://www.pjcj.net -- To unsubscribe, e-mail: beginners-unsubscr...@perl.org For additional commands, e-mail: beginners-h...@perl.org http://learn.perl.org/