Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- function set(&$x, &$y)
- {
- $x =& $y[2];
- }
- $y = array(
- 0,
- 1,
- array('something')
- );
- $x = array('old_val');
- print "1. inited, x is:n";
- print_r($x);
- set($x, $y);
- print "n2. now, x is: ";
- print_r($x);
- 1. inited, x is:
- Array
- (
- [0] => old_val
- )
- 2. now, x is: Array
- (
- [0] => old_val
- )
- function &set(&$x, &$y) {}
- $x =& set($x,$y);
- $x =& $y[2];
Add Comment
Please, Sign In to add comment