1--TEST--
2Constructor promotion of by-ref parameter
3--FILE--
4<?php
5
6class Ary {
7 public function __construct(public array &$array) {}
8}
9
10$array = [];
11$ary = new Ary($array);
12$array[] = 42;
13var_dump($ary->array);
14
15?>
16--EXPECT--
17array(1) {
18 [0]=>
19 int(42)
20}
21