RE: [PEAR-DEV] CS question: do private function namechanges count as API changes?
| From: | Jorrit Schippers - nCode | Date: | Fri, 16 Nov 2007 18:55:39 +0000 |
| Subject: | RE: [PEAR-DEV] CS question: do private function namechanges count as API changes? | ||
| References: | 1 2 | Groups: | php.pear.dev |
| Request: | Send a blank email to pear-dev+get-48474@lists.php.net to get a copy of this message | ||
> > I've read that API changes are not recommended, but do
> private method
> > changes count as API methods? And should I change it to
> determineOSMatch(),
> > _determineOSMatch() or perhaps (_)determineOsMatch()?
> >
>
> My gut reaction would be private *anything* is fair game, as
> by definition
> anything *private* is not part of a library's "API".
> However, others that
> have been in PEAR longer than me should definitely confirm
> this, as I'd bet
> the question has come up and been discussed before.
>
I already thought so, but as it is my first PEAR code, I thought I'd better
discuss this first
>
> > Besides that, what would be the correct way of keeping line
> 572 [1] within
> > the required 85 character / line limit? It's a variable
> defined in the
> > class, so tricks like splitting the string do not help.
> >
>
> Wow, what a string :P
>
> I'd split it into pieces that are all dot-concatenated together, at a
> minimum like this;
>
> 'pattern' =>
> '/(?:(d)|.)([rwxt-]+)\s+(\w+)\s+([\w\d-]+)\s+([\w\d-]+)*'*
> *. '*\s+(\w+)\s+(\S+\s+\S+\s+\S+)\s+(.+)/',
>
This was my first idea, but constructs like those are only allowed in method
bodies, not when declaring the content of a variable directly inside a class
{}
Jorrit