xref: /PHP-8.1/ext/standard/tests/array/bug71603.phpt (revision 7aacc705)
1--TEST--
2Bug #71603 (compact() maintains references in php7)
3--FILE--
4<?php
5$foo = "okey";
6$foo_reference =& $foo;
7
8$array = compact('foo_reference');
9
10$foo = 'changed!';
11
12var_dump($array['foo_reference']);
13?>
14--EXPECT--
15string(4) "okey"
16