Added support for by-reference PHP 'foreach' statement value variables

- Adds ArrayElementReference class and support to Variable class for using them
- Changes semantics of foreach (...) { ... } statement to more closely match PHP's

See http://stackoverflow.com/questions/10057671/how-foreach-actually-works for some insight