[TYPO3-core] '=&' can be found all over the code basis

Philipp Gampe philipp.gampe at typo3.org
Mon Oct 1 02:55:03 CEST 2012


Hi Roland,

Roland wrote:

> does '=&' mean soething special or should this be '= &$' in all these
> cases?

AFAIK there is no such operator and PHP even always creates objects by 
reference. Plus PHP does copy-on-write, thus I do not think that using 
references does any good to performance unless you explicitly have a 
noticeable memory leak or you really need this references.

Taking the linked example, you can just remove the "&" without changing 
anything in the execution of the code.

Please correct me if I am wrong.

Best regards
-- 
Philipp Gampe – PGP-Key 0AD96065 – TYPO3 UG Bonn/Köln
Documentation – linkvalidator
TYPO3 .... inspiring people to share!



More information about the TYPO3-team-core mailing list