What do the "=&" and "&=" operators in PHP mean?

heyheyhey picture heyheyhey · Sep 2, 2009 · Viewed 15.1k times · Source

What do "=&" / "&=" operators in PHP mean? Where can I read information about them?

Searching Google doesn't help.

Answer

moo picture moo · Sep 2, 2009

$a &= $b is short for $a = $a & $b which is the bitwise-and operator.

$a =& $b assigns $a as a reference to $b.