File tree Expand file tree Collapse file tree 2 files changed +50
-0
lines changed
Expand file tree Collapse file tree 2 files changed +50
-0
lines changed Original file line number Diff line number Diff line change 1+ --TEST--
2+ Pass short ctor parameters
3+ --FILE--
4+ <?php
5+
6+ try {
7+ assert (false && function () {
8+ class Empty0 ();
9+ });
10+ } catch (Throwable $ e ) {
11+ echo $ e ->getMessage (), PHP_EOL ;
12+ }
13+
14+ ?>
15+ --EXPECTF--
16+ assert(false && function () {
17+ class Empty0 {
18+ public function __construct() {
19+ }
20+
21+ }
22+
23+ })
Original file line number Diff line number Diff line change 1+ --TEST--
2+ Pass short ctor parameters
3+ --FILE--
4+ <?php
5+
6+ try {
7+ assert (false && function () {
8+
9+ class DTO (
10+ public int $ number ,
11+ );
12+
13+ });
14+ } catch (Throwable $ e ) {
15+ echo $ e ->getMessage (), PHP_EOL ;
16+ }
17+
18+ ?>
19+ --EXPECTF--
20+ assert(false && function () {
21+ class DTO {
22+ public function __construct(public int $number) {
23+ }
24+
25+ }
26+
27+ })
You can’t perform that action at this time.
0 commit comments