1--TEST--
2Bug GH-9285: PHP 8.2 readonly classes allow inheriting mutable properties from traits - success
3--FILE--
4<?php
5
6trait T {
7    public readonly int $prop;
8}
9
10readonly class C {
11    use T;
12
13    public function __construct()
14    {
15        $this->prop = 1;
16    }
17}
18
19$c = new C();
20var_dump($c->prop);
21
22?>
23--EXPECT--
24int(1)
25