-- Miggl <[email protected]> wrote (on Saturday, 27 December 2008, 10:09 AM -0800): > I have been reviewing the ZF Coding Standards and support most all standards > implemented with the exception of Control Statements not using the Allman > style > braces, which seems to support the 1TB style. What is the thought behind this, > why deviate from how braces are handled throughout all other areas? I am > hesitant to adopt it, as I personally use the Allman style throughout all my > code. I'll spare going through the advantages and disadvantages of each, as it > is not the intent of this post. However, I would like to better understand the > reasoning behing using the K&R style for control statements, while using > Allman > style for everything else, before completely adopting the ZF coding standards. > Best Regards and Happy Holidays! Mike Bronner References: WikiPedia: http:// > en.wikipedia.org/wiki/Indent_style ZF Coding Standards: http:// > framework.zend.com/manual/en/coding-standard.html
In large part, our standards are adopted from PEAR coding standards (which in turn were adopted from Horde CS); our goal is to have standards that are interchangeable with other projects, to ensure code consistency and readability. PEAR standards are widely adopted (ADODb, Solar, Phing, and others all use PEAR CS), and are a logical choice. If you want to know why 1TB is used as it is, I suggest looking at the list archives for the PEAR and Horde projects. -- Matthew Weier O'Phinney Software Architect | [email protected] Zend Framework | http://framework.zend.com/
