[PHP] Hungarian Notation interest with PHP

2012-06-04 Thread Mihamina Rakotomandimby

Hi all,

I have a colleague stuck with this thing named Hungarian Notation
http://goo.gl/xYv8O

We try to define our internal coding standards, which is very close to 
the Symfony ones http://goo.gl/f2rcO


But we're in conflict because the colleague really argue about his 
Hungarian Notation.


Have you got some ressources arguing against this? I ran out of mine to 
convince him...


--
RMA.

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Hungarian Notation interest with PHP

2012-06-04 Thread Ashley Sheridan


Mihamina Rakotomandimby miham...@rktmb.org wrote:

Hi all,

I have a colleague stuck with this thing named Hungarian Notation
http://goo.gl/xYv8O

We try to define our internal coding standards, which is very close to
the Symfony ones http://goo.gl/f2rcO

But we're in conflict because the colleague really argue about his
Hungarian Notation.

Have you got some ressources arguing against this? I ran out of mine to

convince him...

--
RMA.

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

The two don't look to be mutually exclusive, but Hungarian notation doesn't 
make much sense to me for php. Php is a loose typed language, and variables can 
(and do) change their types often. Consider even the internal php functions 
which can return booleans, or arrays or strings, all from the same function. 
Using Hungarian notation to give the dev a hint about the various types doesn't 
make much sense, and may give the dev a false sense of security.

Thanks,
Ash
http://ashleysheridan.co.uk

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Hungarian Notation interest with PHP

2012-06-04 Thread Mihamina Rakotomandimby

On 06/04/2012 05:58 PM, Ashley Sheridan wrote:

The two don't look to be mutually exclusive,


Sure, they're not.
It's not forbiden to prefix variables.


but Hungarian notation
doesn't make much sense to me for php. Php is a loose typed language,


That's the first point I told him. No way: for him it's syntaxically 
compliant.


:-)

--
RMA.

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Hungarian Notation interest with PHP

2012-06-04 Thread Matijn Woudt
On Mon, Jun 4, 2012 at 4:43 PM, Mihamina Rakotomandimby
miham...@rktmb.org wrote:
 Hi all,

 I have a colleague stuck with this thing named Hungarian Notation
 http://goo.gl/xYv8O

 We try to define our internal coding standards, which is very close to the
 Symfony ones http://goo.gl/f2rcO

 But we're in conflict because the colleague really argue about his
 Hungarian Notation.

 Have you got some ressources arguing against this? I ran out of mine to
 convince him...


Hungarion notation just doesn't make sense in PHP. You should not even
try to convince him, if he doesn't understand this, then you might be
better off finding another colleague ;)

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Hungarian Notation interest with PHP

2012-06-04 Thread Tim Streater
On 04 Jun 2012 at 15:43, Mihamina Rakotomandimby miham...@rktmb.org wrote: 

 I have a colleague stuck with this thing named Hungarian Notation
 http://goo.gl/xYv8O

 We try to define our internal coding standards, which is very close to
 the Symfony ones http://goo.gl/f2rcO

 But we're in conflict because the colleague really argue about his
 Hungarian Notation.

This simply adds far too much noise to code. If I need to know what type a 
variable has, I'll look at its declaration, if any.

--
Cheers  --  Tim

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php