[Phpmyadmin-devel] about spacing around operators

Hi, I was looking at [0] to find the requirement about spacing around operators, to no avail. No more luck in [1]. I prefer this requirement but we should mention it somewhere. [0] http://wiki.phpmyadmin.net/pma/Developer_guidelines [1] http://pear.php.net/manual/en/standards.php -- Marc Delisle http://infomarc.info

Hi Dne Mon, 01 Apr 2013 08:06:06 -0400 Marc Delisle <marc@infomarc.info> napsal(a):
I was looking at [0] to find the requirement about spacing around operators, to no avail. No more luck in [1].
I prefer this requirement but we should mention it somewhere.
Indeed it seems not to be covered, so we should include in our wiki. Maybe this would be useful: http://drupal.org/coding-standards#operators -- Michal Čihař | http://cihar.com | http://blog.cihar.com

On Apr 2, 2013, at 6:10 AM, Michal Čihař <michal@cihar.com> wrote:
Hi
Dne Mon, 01 Apr 2013 08:06:06 -0400 Marc Delisle <marc@infomarc.info> napsal(a):
I was looking at [0] to find the requirement about spacing around operators, to no avail. No more luck in [1].
I prefer this requirement but we should mention it somewhere.
Indeed it seems not to be covered, so we should include in our wiki. Maybe this would be useful:
Looks good by me. If no one gets to it before me, I'll make the change later today.
-- Michal Čihař | http://cihar.com | http://blog.cihar.com ------------------------------------------------------------------------------ Own the Future-Intel(R) Level Up Game Demo Contest 2013 Rise to greatness in Intel's independent game demo contest. Compete for recognition, cash, and the chance to get your game on Steam. $5K grand prize plus 10 genre and skill prizes. Submit your demo by 6/6/13. http://altfarm.mediaplex.com/ad/ck/12124-176961-30367-2 _______________________________________________ Phpmyadmin-devel mailing list Phpmyadmin-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/phpmyadmin-devel

Isaac Bennetch a écrit :
On Apr 2, 2013, at 6:10 AM, Michal Čihař <michal@cihar.com> wrote:
Hi
Dne Mon, 01 Apr 2013 08:06:06 -0400 Marc Delisle <marc@infomarc.info> napsal(a):
I was looking at [0] to find the requirement about spacing around operators, to no avail. No more luck in [1].
I prefer this requirement but we should mention it somewhere. Indeed it seems not to be covered, so we should include in our wiki. Maybe this would be useful:
What triggered my questionning is the exclamation mark, for example if ($foo && ! $blah) but the Drupal's coding standard mentions that unary operators (like ++) should not have a space between the operator. So, where does our "space after exclamation mark" practice come from? Just for readability?
Looks good by me. If no one gets to it before me, I'll make the change later today.
-- Marc Delisle http://infomarc.info

2013/4/2 Marc Delisle <marc@infomarc.info>:
Isaac Bennetch a écrit :
On Apr 2, 2013, at 6:10 AM, Michal Čihař <michal@cihar.com> wrote:
Hi
Dne Mon, 01 Apr 2013 08:06:06 -0400 Marc Delisle <marc@infomarc.info> napsal(a):
I was looking at [0] to find the requirement about spacing around operators, to no avail. No more luck in [1].
I prefer this requirement but we should mention it somewhere. Indeed it seems not to be covered, so we should include in our wiki. Maybe this would be useful:
What triggered my questionning is the exclamation mark, for example
if ($foo && ! $blah)
but the Drupal's coding standard mentions that unary operators (like ++) should not have a space between the operator. So, where does our "space after exclamation mark" practice come from? Just for readability?
When looking around a bit, I find mostly examples with no space after !, but on the php.net documentation page, there is a space between ! and the variable [0]. [0] http://www.php.net/manual/en/language.operators.logical.php -- Kind regards, Dieter Adriaenssens

2013/4/2 Michal Čihař <michal@cihar.com>:
Hi
Dne Mon, 01 Apr 2013 08:06:06 -0400 Marc Delisle <marc@infomarc.info> napsal(a):
I was looking at [0] to find the requirement about spacing around operators, to no avail. No more luck in [1].
I prefer this requirement but we should mention it somewhere.
Indeed it seems not to be covered, so we should include in our wiki. Maybe this would be useful:
Looks good! -- Kind regards, Dieter Adriaenssens
participants (4)
-
Dieter Adriaenssens
-
Isaac Bennetch
-
Marc Delisle
-
Michal Čihař