Re: PEAR Coding Standards question
| From: | Lukas Kahwe Smith | Date: | Tue, 19 Aug 2008 21:24:08 +0000 |
| Subject: | Re: PEAR Coding Standards question | ||
| References: | 1 2 3 4 | Groups: | php.pear.dev |
| Request: | Send a blank email to pear-dev+get-50570@lists.php.net to get a copy of this message | ||
On 19.08.2008, at 19:08, till wrote:
On Tue, Aug 19, 2008 at 12:58 PM, Chuck Burgess <demon.gene@gmail.com> wrote:It doesnt for me. While I am working inside the "guts" of a class (aka extending it), I am much more aware of the internal design, than when I am "using" it from the outside. As such the prefixing to me is mainly about informing how the properties/methods are accessible (or not) from the outside. As for as outdated or not, of course you can/should define it explicitly with the relevant keywords as well, but with the underscore you do not look things up, its right their in your face with casual inspection of the code/API docs. regards, Lukas Kahwe Smith mls@pooteeweet.orgOn Tue, Aug 19, 2008 at 11:49 AM, Chuck Burgess <demon.gene@gmail.com>wrote:Wow, a true moment of clarity. Makes perfect sense to me. :)On Tue, Aug 19, 2008 at 11:39 AM, Kevin van Zonneveld < kevin@vanzonneveld.net> wrote:The most helpful comment on that RFC that helps me understand the overall decision against underscores was from Justin -- "As protected members may be declared public in extending classes, it makes sense to me to not force protected members to be prefixed."Why are the coding conventions so that I'm not allowed to prefix protected methods with an underscore?The decision on that was made on this old RFC [1]. Perhaps we should revisit it with a fresh discussion? -- CRB [1] - http://pear.php.net/pepr/pepr-proposal-show.php?id=99