1--TEST--
2Enum cannot have properties, even via traits
3--FILE--
4<?php
5
6trait Rectangle {
7    protected string $shape = "Rectangle";
8
9    public function shape(): string {
10        return $this->shape;
11    }
12}
13
14enum Suit {
15    use Rectangle;
16
17    case Hearts;
18    case Diamonds;
19    case Clubs;
20    case Spades;
21}
22
23?>
24--EXPECTF--
25Fatal error: Enum "Suit" may not include properties in %s on line %d
26