Anonymous array with foreach loop in PHP
<p>I was wondering how PHP handles an anonymous array, if I make use of it like this:</p>

<pre><code>foreach(array('a', 'b') as $foo) {
    // ...
}
</code></pre>

<p>This wouldn't work if the array gets recreated on every step - but it works, so it looks like PHP creates a variable for that array (or something similar, doesn't really matter) - meaning this wouldn't actually have a bad perfomance. But is there any point why not to use anonymous arrays with foreach loops? (it kinda "looks wrong/bad" to me)</p>
