Re: Fw: [php-gtk-cvs] cvs: php-gtk / CODING_STANDARDS

From: Date: Wed, 26 Oct 2005 16:46:54 +0000
Subject: Re: Fw: [php-gtk-cvs] cvs: php-gtk / CODING_STANDARDS
References: 1 2  Groups: php.gtk.dev 
Request: Send a blank email to php-gtk-dev+get-1962@lists.php.net to get a copy of this message
That's consistent with PHP-GTK 2's approach to GTK+, but not to PHP... Anyone else have any strong feelings about this (hands up - I don't). - Steph ----- Original Message ----- From: "Scott Mattocks" <scott@crisscott.com> To: "PHP-GTK dev" <php-gtk-dev@lists.php.net> Sent: Wednesday, October 26, 2005 4:59 PM Subject: Re: [PHP-GTK-DEV] Fw: [php-gtk-cvs] cvs: php-gtk / CODING_STANDARDS > The only thing that I would change is the part about user defined global > constants: > > For other constants in the global namespace (that is, constants in > your PHP code), stay with the PEAR format: MYCLASS_CONSTANT_NAME. > > The PEAR CS has to be backward compatible for PHP 4. That is why they > require MYCLASS_*. Since we don't have to worry about PHP 4 any more, I > think we should divert from PEAR a little here. Consistency would be > better in my opinion. How about this: > > User defined classes should not declare constants in the global > namespace. All user defined classes should declare constants in the > class namespace. For example: MyClass::SOME_CONSTANT instead of > MYCLASS_SOME_CONSTANT. > > Scott > > Steph Fox wrote: > > OK guys, tear it apart :) > > > > ----- Original Message ----- > > From: "Steph Fox" <sfox@php.net> > > To: <php-gtk-cvs@lists.php.net> > > Sent: Wednesday, October 26, 2005 2:14 PM > > Subject: [php-gtk-cvs] cvs: php-gtk / CODING_STANDARDS > > > > > >> sfox Wed Oct 26 09:14:32 2005 EDT > >> > >> Added files: > >> /php-gtk CODING_STANDARDS > >> Log: > >> Initial commit of coding standards file. > >> > >> > >> -- > >> PHP-GTK CVS Mailing List (http://gtk.php.net/) > >> To unsubscribe, visit: http://www.php.net/unsub.php > >> > > > > -- > Scott Mattocks > scott@crisscott.com > http://www.crisscott.com > http://pear.php.net/user/scottmattocks > > -- > PHP-GTK Development Mailing List (http://gtk.php.net/) > To unsubscribe, visit: http://www.php.net/unsub.php >

« previous php.gtk.dev (#1962) next »